Component: Magnetometer (SM324) (Movement Orientation)
From Flowcode Help
Jump to navigationJump to search
Author | Matrix TSL |
Version | 1.0 |
Category | Movement Orientation |
Contents
Magnetometer (SM324) component
SM324 ultraprecise 24-bit smart magnetometer capable of distance measurement using a magnet. Controlled via I2C bus communications.
Component Source Code
Please click here for the component source code: FC_Comp_Source_Magnetometer_SM324.fcfx
Detailed description
No detailed description exists yet for this component
Examples
No additional examples
Downloadable macro reference
![]() |
ReadStatus |
Reads the status byte from the sensor IC. Bit 6 = Voltage OK Bit 5 = Busy Bit 2 = Memory Error Bit 0 = Saturation | |
![]() |
Return |
![]() |
WriteMemory |
Writes a 16-bit value to the specified memory location | |
![]() |
Address |
Internal memory address | |
![]() |
Value |
![]() |
Return |
![]() |
RequestData |
Requests temperature and magnetic data from the device, returns status. Bit 6 = Voltage OK Bit 5 = Busy Bit 2 = Memory Error Bit 0 = Saturation | |
![]() |
Return |
![]() |
ReadTemperatureRaw |
Reads the temperature from the last succesful data read. | |
![]() |
Return |
![]() |
ReadMagneticFieldRaw |
Reads the magnetic field from the last succesful data read. | |
![]() |
Return |
![]() |
ReadMagneticFieldReal |
Reads the magnetic field from the last succesful data read as a float in Oersted Oe. | |
![]() |
Return |
![]() |
WriteCommand |
Sends a command to the sensor IC. | |
![]() |
Command |
![]() |
Return |
![]() |
ReadTemperatureReal |
Reads the temperature from the last succesful data read as an float in degrees C. | |
![]() |
Return |
![]() |
Initialise |
Sets up the I2C bus ready to communicate with the sensor IC. Sets the address variable back to the Address property value. | |
![]() |
Return |