flux sdk  v01.02.02-3-g292b3a7
Embedded C++ SDK
Loading...
Searching...
No Matches
flxDevISM330Base Class Reference

#include <flxDevISM330.h>

Inheritance diagram for flxDevISM330Base:
flxDevice flxOperation flxObject _flxParameterContainer flxPersist _flxPropertyContainer flxDescriptor flxDeviceI2CType< flxDevISM330, flxDevISM330Base > flxDeviceSPIType< flxDevISM330_SPI, flxDevISM330Base > flxDevISM330 flxDevISM330_SPI

Public Member Functions

 flxDevISM330Base ()
 
- Public Member Functions inherited from flxDevice
 flxDevice ()
 
virtual ~flxDevice ()
 
virtual bool execute (void)
 Virtual method called to run the operation - called before data is retrieved. More...
 
bool initialize ()
 
virtual bool initialize (flxBusI2C &)
 
virtual bool initialize (flxBusSPI &)
 
bool autoload (void)
 
void setAutoload ()
 
void setAddress (uint8_t address)
 
uint8_t address (void)
 
void addAddressToName ()
 
void setIsInitialized (bool isInit)
 
bool isInitialized (void)
 
virtual flxDeviceKind_t getKind (void)
 
- Public Member Functions inherited from flxOperation
virtual flxTypeID getType (void)
 
virtual bool execute (void)
 Virtual method called to run the operation - called before data is retrieved. More...
 
virtual bool onSave (flxStorageBlock *stBlk)
 
virtual bool onRestore (flxStorageBlock *stBlk)
 
- Public Member Functions inherited from flxObject
 flxObject ()
 
virtual ~flxObject ()
 
void setParent (flxObject *parent)
 
void setParent (flxObject &parent)
 
flxObjectparent ()
 
void setHidden (bool bHide=true)
 
bool hidden ()
 
void setIsDirty (bool bDirty=true)
 
bool isDirty (void)
 
virtual bool onSave (flxStorageBlock *stBlk)
 
virtual bool save (flxStorage *pStorage)
 
virtual bool onRestore (flxStorageBlock *stBlk)
 
virtual bool restore (flxStorage *pStorage)
 
virtual flxTypeID getType (void)
 
virtual bool save (flxStorage *)=0
 
virtual bool restore (flxStorage *)=0
 
- Public Member Functions inherited from _flxPropertyContainer
 _flxPropertyContainer ()
 
void addProperty (flxProperty *newProperty)
 
void addProperty (flxProperty &newProperty)
 
void removeProperty (flxProperty *rmProp)
 
void removeProperty (flxProperty &rmProp)
 
flxPropertyListgetProperties (void)
 
uint nProperties (void)
 
bool saveProperties (flxStorageBlock *stBlk)
 
bool restoreProperties (flxStorageBlock *stBlk)
 
size_t propertySaveSize ()
 
void hideProperty (flxProperty &theProp)
 
- Public Member Functions inherited from flxDescriptor
 flxDescriptor ()
 
void setName (const char *new_name)
 Set the Name object - storing the pointer to the provided string No allocation is performed. If the previous name was allocated, it is freed. More...
 
void setName (const char *new_name, const char *new_desc)
 Set the Name object and the Description for the object. Both strings are constants. More...
 
void setName (char *new_name)
 Set the Name object, but makes a copy of the input string since the input is not const. If the previous name was allocated, it is freed. More...
 
const char * name ()
 Return a const char pointer to the name of the object. More...
 
std::string name_ (void)
 Returns a std::string of the name of the object. More...
 
void setDescription (const char *new_desc)
 Set the Description object - the input value is constant and not copied. If the previous description was allocated, it is freed. More...
 
void setDescription (char *new_desc)
 Set the Description object - the input value is not constant and is copied. If the previous description was allocated, it is freed. More...
 
const char * description ()
 Return the constant C string pointer to the description of the object. More...
 
std::string description_ (void)
 Return the description of the object as a std::string. More...
 
void setTitle (const char *title)
 Set the Title object - the title is optional and is used mostly for UX or organizational purposes. The input value is constant and not copied. If the previous title was allocated, it is freed. More...
 
void setTitleAlloc (char *new_title)
 Set the Title of the object , but make an explict copy of the provided string. More...
 
const char * title (void)
 Return the C constant string pointer to the title of the object. More...
 
- Public Member Functions inherited from _flxParameterContainer
void addParameter (flxParameterIn *newParam, bool head=false)
 
void addParameter (flxParameterIn &newParam, bool head=false)
 
void removeParameter (flxParameterIn *rmParam)
 
void removeParameter (flxParameterIn &rmParam)
 
size_t nInputParameters ()
 
void addParameter (flxParameterOut *newParam, bool head=false)
 
void addParameter (flxParameterOut &newParam, bool head=false)
 
void removeParameter (flxParameterOut *rmParam)
 
void removeParameter (flxParameterOut &rmParam)
 
size_t nOutputParameters ()
 
flxParameterOutListgetOutputParameters (void)
 
flxParameterInListgetInputParameters (void)
 

Public Attributes

flxParameterOutFloat< flxDevISM330Base, &flxDevISM330Base::read_accel_x > accelX
 
flxParameterOutFloat< flxDevISM330Base, &flxDevISM330Base::read_accel_y > accelY
 
flxParameterOutFloat< flxDevISM330Base, &flxDevISM330Base::read_accel_z > accelZ
 
flxParameterOutFloat< flxDevISM330Base, &flxDevISM330Base::read_gyro_x > gyroX
 
flxParameterOutFloat< flxDevISM330Base, &flxDevISM330Base::read_gyro_y > gyroY
 
flxParameterOutFloat< flxDevISM330Base, &flxDevISM330Base::read_gyro_z > gyroZ
 
flxParameterOutFloat< flxDevISM330Base, &flxDevISM330Base::read_temperature > temperature
 
flxPropertyRWUInt8< flxDevISM330Base, &flxDevISM330Base::get_accel_data_rate, &flxDevISM330Base::set_accel_data_rate > accelDataRate
 
flxPropertyRWUInt8< flxDevISM330Base, &flxDevISM330Base::get_accel_full_scale, &flxDevISM330Base::set_accel_full_scale > accelFullScale = {ISM_4g, {{"2 g", ISM_2g}, {"16 g", ISM_16g}, {"4 g", ISM_4g}, {"8 g", ISM_8g}}}
 
flxPropertyRWUInt8< flxDevISM330Base, &flxDevISM330Base::get_gyro_data_rate, &flxDevISM330Base::set_gyro_data_rate > gyroDataRate
 
flxPropertyRWUInt8< flxDevISM330Base, &flxDevISM330Base::get_gyro_full_scale, &flxDevISM330Base::set_gyro_full_scale > gyroFullScale
 
flxPropertyRWUInt8< flxDevISM330Base, &flxDevISM330Base::get_accel_filter_lp2, &flxDevISM330Base::set_accel_filter_lp2 > accelFilterLP2 = {1, {{"Enabled", 1}, {"Disabled", 0}}}
 
flxPropertyRWUInt8< flxDevISM330Base, &flxDevISM330Base::get_gyro_filter_lp1, &flxDevISM330Base::set_gyro_filter_lp1 > gyroFilterLP1 = {1, {{"Enabled", 1}, {"Disabled", 0}}}
 
flxPropertyRWUInt8< flxDevISM330Base, &flxDevISM330Base::get_accel_slope_filter, &flxDevISM330Base::set_accel_slope_filter > accelSlopeFilter
 
flxPropertyRWUInt8< flxDevISM330Base, &flxDevISM330Base::get_gyro_lp1_bandwidth, &flxDevISM330Base::set_gyro_lp1_bandwidth > gyroLP1Bandwidth
 
- Public Attributes inherited from flxDevice
flxParameterInVoid< flxDevice, &flxDevice::disable_all_parameters > disableAllParameters
 
flxParameterInVoid< flxDevice, &flxDevice::enable_all_parameters > enableAllParameters
 

Protected Member Functions

bool onInitialize (void)
 

Additional Inherited Members

- Static Public Member Functions inherited from flxObject
static flxTypeID type (void)
 
- Protected Attributes inherited from flxDescriptor
const char * _name
 
bool _nameAlloc
 
const char * _desc
 
bool _descAlloc
 
const char * _title
 
bool _titleAlloc
 

Constructor & Destructor Documentation

◆ flxDevISM330Base()

flxDevISM330Base::flxDevISM330Base ( )

Member Function Documentation

◆ onInitialize()

bool flxDevISM330Base::onInitialize ( void  )
protected

Member Data Documentation

◆ accelDataRate

flxPropertyRWUInt8<flxDevISM330Base, &flxDevISM330Base::get_accel_data_rate, &flxDevISM330Base::set_accel_data_rate> flxDevISM330Base::accelDataRate
Initial value:
= {ISM_XL_ODR_104Hz,
{{"Off", ISM_XL_ODR_OFF},
{"12.5 Hz", ISM_XL_ODR_12Hz5},
{"26 Hz", ISM_XL_ODR_26Hz},
{"52 Hz", ISM_XL_ODR_52Hz},
{"104 Hz", ISM_XL_ODR_104Hz},
{"208 Hz", ISM_XL_ODR_208Hz},
{"416 Hz", ISM_XL_ODR_416Hz},
{"833 Hz", ISM_XL_ODR_833Hz},
{"1666 Hz", ISM_XL_ODR_1666Hz},
{"3332 Hz", ISM_XL_ODR_3332Hz},
{"6667 Hz", ISM_XL_ODR_6667Hz},
{"1.6 Hz", ISM_XL_ODR_1Hz6}}}

◆ accelFilterLP2

flxPropertyRWUInt8<flxDevISM330Base, &flxDevISM330Base::get_accel_filter_lp2, &flxDevISM330Base::set_accel_filter_lp2> flxDevISM330Base::accelFilterLP2 = {1, {{"Enabled", 1}, {"Disabled", 0}}}

◆ accelFullScale

flxPropertyRWUInt8<flxDevISM330Base, &flxDevISM330Base::get_accel_full_scale, &flxDevISM330Base::set_accel_full_scale> flxDevISM330Base::accelFullScale = {ISM_4g, {{"2 g", ISM_2g}, {"16 g", ISM_16g}, {"4 g", ISM_4g}, {"8 g", ISM_8g}}}

◆ accelSlopeFilter

flxPropertyRWUInt8<flxDevISM330Base, &flxDevISM330Base::get_accel_slope_filter, &flxDevISM330Base::set_accel_slope_filter> flxDevISM330Base::accelSlopeFilter
Initial value:
= {ISM_LP_ODR_DIV_100,
{{"ODR/4", 0},
{"ODR/10", ISM_LP_ODR_DIV_10},
{"ODR/20", ISM_LP_ODR_DIV_20},
{"ODR/45", ISM_LP_ODR_DIV_45},
{"ODR/100", ISM_LP_ODR_DIV_100},
{"ODR/200", ISM_LP_ODR_DIV_200},
{"ODR/400", ISM_LP_ODR_DIV_400},
{"ODR/800", ISM_LP_ODR_DIV_800}}}

◆ accelX

flxParameterOutFloat<flxDevISM330Base, &flxDevISM330Base::read_accel_x> flxDevISM330Base::accelX

◆ accelY

flxParameterOutFloat<flxDevISM330Base, &flxDevISM330Base::read_accel_y> flxDevISM330Base::accelY

◆ accelZ

flxParameterOutFloat<flxDevISM330Base, &flxDevISM330Base::read_accel_z> flxDevISM330Base::accelZ

◆ gyroDataRate

flxPropertyRWUInt8<flxDevISM330Base, &flxDevISM330Base::get_gyro_data_rate, &flxDevISM330Base::set_gyro_data_rate> flxDevISM330Base::gyroDataRate
Initial value:
= {ISM_GY_ODR_104Hz,
{{"Off", ISM_GY_ODR_OFF},
{"12 Hz", ISM_GY_ODR_12Hz},
{"26 Hz", ISM_GY_ODR_26Hz},
{"52 Hz", ISM_GY_ODR_52Hz},
{"104 Hz", ISM_GY_ODR_104Hz},
{"208 Hz", ISM_GY_ODR_208Hz},
{"416 Hz", ISM_GY_ODR_416Hz},
{"833 Hz", ISM_GY_ODR_833Hz},
{"1666 Hz", ISM_GY_ODR_1666Hz},
{"3332 Hz", ISM_GY_ODR_3332Hz},
{"6667 Hz", ISM_GY_ODR_6667Hz}}}

◆ gyroFilterLP1

flxPropertyRWUInt8<flxDevISM330Base, &flxDevISM330Base::get_gyro_filter_lp1, &flxDevISM330Base::set_gyro_filter_lp1> flxDevISM330Base::gyroFilterLP1 = {1, {{"Enabled", 1}, {"Disabled", 0}}}

◆ gyroFullScale

flxPropertyRWUInt8<flxDevISM330Base, &flxDevISM330Base::get_gyro_full_scale, &flxDevISM330Base::set_gyro_full_scale> flxDevISM330Base::gyroFullScale
Initial value:
= {ISM_500dps,
{{"125 dps", ISM_125dps},
{"250 dps", ISM_250dps},
{"500 dps", ISM_500dps},
{"1000 dps", ISM_1000dps},
{"2000 dps", ISM_2000dps},
{"4000 dps", ISM_4000dps}}}

◆ gyroLP1Bandwidth

flxPropertyRWUInt8<flxDevISM330Base, &flxDevISM330Base::get_gyro_lp1_bandwidth, &flxDevISM330Base::set_gyro_lp1_bandwidth> flxDevISM330Base::gyroLP1Bandwidth
Initial value:
= {ISM_MEDIUM,
{{"Ultra Light", ISM_ULTRA_LIGHT},
{"Very Light", ISM_VERY_LIGHT},
{"Light", ISM_LIGHT},
{"Medium", ISM_MEDIUM},
{"Strong", ISM_STRONG},
{"Very Strong", ISM_VERY_STRONG},
{"Aggressive", ISM_AGGRESSIVE},
{"Extreme", ISM_XTREME}}}

◆ gyroX

flxParameterOutFloat<flxDevISM330Base, &flxDevISM330Base::read_gyro_x> flxDevISM330Base::gyroX

◆ gyroY

flxParameterOutFloat<flxDevISM330Base, &flxDevISM330Base::read_gyro_y> flxDevISM330Base::gyroY

◆ gyroZ

flxParameterOutFloat<flxDevISM330Base, &flxDevISM330Base::read_gyro_z> flxDevISM330Base::gyroZ

◆ temperature

flxParameterOutFloat<flxDevISM330Base, &flxDevISM330Base::read_temperature> flxDevISM330Base::temperature

The documentation for this class was generated from the following files: