|
|
| UnitMiniScales (const uint8_t addr=DEFAULT_ADDRESS) |
| |
| virtual void | update (const bool force=false) override |
| |
|
|
config_t | config () |
| | Gets the configration.
|
| |
|
void | config (const config_t &cfg) |
| | Set the configration.
|
| |
|
| bool | readLEDColor (uint32_t &rgb32) |
| | Read the LED color as RGB32 (00RRGGBB HEX)
|
| |
| bool | readLEDColor (uint8_t &r, uint8_t &g, uint8_t &b) |
| | Read the LED color as each colors.
|
| |
| bool | writeLEDColor (const uint32_t rgb32) |
| | Write the LED color as RGB32 (00RRGGBB HEX)
|
| |
| bool | writeLEDColor (const uint16_t rgb16) |
| | Write the LED color as RGB16 (RRRRRGGGGGGBBBBB BIN)
|
| |
| bool | writeLEDColor (const uint8_t r, const uint8_t g, const uint8_t b) |
| | Write the LED color as each colors.
|
| |
|
| bool | readButtonStatus (bool &press) |
| | Read the button status.
|
| |
| bool | isPressed () const |
| | Is button pressed?
|
| |
| bool | wasPressed () const |
| | Was button pressed?
|
| |
| bool | wasReleased () |
| | Is button released?
|
| |
|
| UnitWeightI2C (const uint8_t addr=DEFAULT_ADDRESS) |
| |
|
virtual bool | begin () override |
| |
| bool | resetOffset () |
| | Reset offset.
|
| |
| bool | readRawADC (int32_t &value) |
| | Read the Raw ADC.
|
| |
|
config_t | config () |
| | Gets the configration.
|
| |
|
void | config (const config_t &cfg) |
| | Set the configration.
|
| |
| float | weight () const |
| | Oldest measured weight (float)
|
| |
| int32_t | iweight () const |
| | Oldest measured weight (integer)
|
| |
| bool | startPeriodicMeasurement (const weighti2c::Mode mode, const uint32_t interval=80) |
| | Start periodic measurement.
|
| |
| bool | stopPeriodicMeasurement () |
| | Stop periodic measurement.
|
| |
| bool | measureSingleshot (weighti2c::Data &data, const weighti2c::Mode mode) |
| | Measurement single shot.
|
| |
| bool | measureSingleshot (char *buf) |
| | Measurement single shot return as string.
|
| |
| bool | readGap (float &gap) |
| | Read the gap value.
|
| |
| bool | writeGap (const float gap, const uint32_t duration=100) |
| | Write the gap value.
|
| |
| bool | isEnabledLPFilter (bool &enabled) |
| | Is enabled the Low-Pass Filter?
|
| |
| bool | enableLPFilter (const bool enable) |
| | Enable the Low-Pass Filter.
|
| |
| bool | readAvgFilterLevel (uint8_t &level) |
| | Read the Averaging Filter level.
|
| |
| bool | writeAvgFilterLevel (const uint8_t level) |
| | Write the Averaging Filter level.
|
| |
| bool | readEmaFilterAlpha (uint8_t &alpha) |
| | Read the Exponential Moving Average Filter alpha.
|
| |
| bool | writeEmaFilterAlpha (const uint8_t alpha) |
| | Write the Exponential Moving Average Filter alpha.
|
| |
| bool | readI2CAddress (uint8_t &i2c_address) |
| | Read the I2C address.
|
| |
| bool | changeI2CAddress (const uint8_t i2c_address) |
| | Change unit I2C address.
|
| |
|
|
bool | read_register (const uint8_t reg, uint8_t *buf, const size_t len) |
| |
|
bool | read_register8 (const uint8_t reg, uint8_t &val) |
| |
|
bool | start_periodic_measurement (const weighti2c::Mode mode, const uint32_t interval) |
| |
|
bool | stop_periodic_measurement () |
| |
|
bool | read_measurement (weighti2c::Data &d, const weighti2c::Mode m) |
| |
|
bool | read_filter (uint8_t *buf3) |
| |
|
bool | write_filter (const uint8_t *buf3) |
| |
|
| M5_UNIT_COMPONENT_PERIODIC_MEASUREMENT_ADAPTER_HPP_BUILDER (UnitWeightI2C, weighti2c::Data) |
| |
|
weighti2c::Mode | _mode {} |
| |
|
std::unique_ptr< m5::container::CircularBuffer< weighti2c::Data > > | _data {} |
| |
|
config_t | _cfg {} |
| |