Hall effect sensor#

Hall effect sensor driver abstraction designed for Thunderboard.

Functions#

sl_status_t
sl_status_t
sl_sensor_hall_get(float *field_strength, bool *alert, bool *tamper)

Function Documentation#

sl_sensor_hall_init#

sl_status_t sl_sensor_hall_init (void)
Parameters
N/A

Initialize hall sensor.

Note

  • With certain boards (e.g. 4184A, 4184B), using this initialization function enables other sensors, because they're on the same enable pin. Please take that into account when using this function.

Returns

  • Status of the operation.


Definition at line 51 of file common/sensor_hall/sl_sensor_hall.h

sl_sensor_hall_deinit#

void sl_sensor_hall_deinit (void)
Parameters
N/A

Deinitialize hall sensor.

Warnings

  • With certain boards (e.g. 4184A, 4184B), using this deinitialization function disables other sensors, because they're on the same enable pin. Please use with caution.


Definition at line 60 of file common/sensor_hall/sl_sensor_hall.h

sl_sensor_hall_get#

sl_status_t sl_sensor_hall_get (float *field_strength, bool *alert, bool *tamper)
Parameters
[out]field_strength

Field strength level (in mT).

[out]alert

Field strength has reached the alert level.

[out]tamper

Field strength has reached the tamper level.

Getter for hall sensor measurement data. Returns

  • Status of the operation.


Definition at line 69 of file common/sensor_hall/sl_sensor_hall.h