Component: Current Sensor (ILA260) (Electrical)
From Flowcode Help
Jump to navigationJump to search| Author | Matrix TSL |
| Version | 1.0 |
| Category | Electrical |
Contents
Current Sensor (ILA260) component
The INA260 provides voltage current and power monitoring via a digital I2C interface.
Detailed description
No detailed description exists yet for this component
Examples
No additional examples
Macro reference
CheckAlert
| CheckAlert | |
| Checks to see if a conversion is ready or if a limit has been hit. Returns 1 for a conversion ready. | |
| Return | |
Initialise
| Initialise | |
| Sets up the I2C ready for operation and initialises the sensor with the default settings. Returns 1 if the device is correctly identified. | |
| Return | |
ReadCurrent
| ReadCurrent | |
| Reads the current as a floating point value in mA. | |
| Return | |
ReadPower
| ReadPower | |
| Reads the power as a floating point value in mW. | |
| Return | |
ReadVoltage
| ReadVoltage | |
| Reads the voltage as a floating point value in mV. | |
| Return | |
SetAlertLimit
| SetAlertLimit | |
| Sets the Alert limit in the format required. | |
| Limit | |
| Limit in mA, mV or mW | |
| Units | |
| 0=mA, 1=mV, 2=mW | |
| Return | |
SetAveragingCount
| SetAveragingCount | |
| Sets the number of samples for each averaged sample. | |
| Count | |
| Range: 0-7 - 0=1, 1=4, 2=16, 3=64, 4=128, 5=256, 6=512, 7=1024 | |
| Return | |
SetConversionTime
| SetConversionTime | |
| Sets the amount of time required for each conversion. | |
| Time | |
| Range: 0-7 - 0=140uS, 1=204uS, 2=332uS, 3=588uS, 4=1.1mS, 5=2.116ms, 6=4.156mS, 7=8.244mS | |
| Return | |
SetMaskedAlerts
| SetMaskedAlerts | |
| Sets the alert conditions that will be shown on the alert pin | |
| AlertMask | |
| 0=None, bit0=ConversionReady, bit1=OverP, bit2=UnderV, bit3=OverV, bit4=UnderI, bit5=OverI | |
| Return | |
SetMode
| SetMode | |
| Sets the mode of the sensor and therefore the amount of power consumed by the sensor. | |
| Mode | |
| 0=Shutdown, 3=Triggered, 7=Continuous | |
| Return | |
Property reference
Component Source Code
Please click here to download the component source project: FC_Comp_Source_Current_and_Power_Sensor_INA260.fcfx
Please click here to view the component source code (Beta): FC_Comp_Source_Current_and_Power_Sensor_INA260.fcfx