|
SFM_FLOW_METER Driver 0.1.0
API reference
|
Everything EnsureInitialized() applies.
More...
#include <sfm_flow_meter_types.hpp>
Public Attributes | |
| Variant | variant {Variant::Auto} |
The part; Auto identifies it inside family. | |
| Family | family {Family::Sf06} |
Used with Auto only; never crosses families. | |
| uint8_t | address {0} |
| 7-bit address; 0 is the part's default. | |
| uint16_t | averaging {kAveragingDefault} |
| N (0 average-until-read, 1..128) or the default. | |
| bool | filter_enabled {false} |
Send the filter argument with the start command. | |
| uint16_t | filter {kFilterDefault} |
| The 16-bit signal-filter argument. | |
| ScalingCheck | scaling_check {ScalingCheck::Strict} |
See ScalingCheck. | |
| RangePolicy | range_policy {RangePolicy::Reject} |
See RangePolicy. | |
| uint16_t | range_margin_permille {20} |
Of the span, added at both ends before OutOfRange. | |
| bool | require_settled {false} |
A sample before the warm-up time is Stale (needs a clock). | |
| bool | reject_smoothed {false} |
A smoothed sample is Stale. | |
| uint32_t | max_age_us {0} |
| bool | accept_prototype {false} |
| A prototype product identifier is accepted. | |
| bool | allow_general_call_reset {false} |
| TimingPolicy | timing {TimingPolicy::Conservative} |
See TimingPolicy. | |
| uint8_t | consecutive_error_limit |
SF05: errors in a row before a hard reset or StateUnknown. | |
| bool | restart_before_read {true} |
| SF05: send the start command again after each read. | |
| bool | poll_with_identifier {false} |
| bool | sf05_serial_low_word {true} |
Everything EnsureInitialized() applies.
Config{} is valid: automatic identification in the SF06 family, the datasheet reset behaviour, strict scaling checks and conservative timing. It has no operator==: nothing here is compared as a whole.
| bool sfm::Config::allow_general_call_reset {false} |
Permit the general-call reset (it resets every device that listens).
| uint8_t sfm::Config::consecutive_error_limit |
SF05: errors in a row before a hard reset or StateUnknown.
| uint32_t sfm::Config::max_age_us {0} |
0 off; else a read later than this after the previous good one is Stale.
| bool sfm::Config::poll_with_identifier {false} |
SF06: idle polls send the identifier command, not stop (ambiguity K-STOPIDLE).
| bool sfm::Config::sf05_serial_low_word {true} |
SF05: also read the low serial word through 0x31AF (ambiguity K-SF05-SERIAL).