Skip to content
Snippets Groups Projects

feat(bhi160): Provide magnetometer data

Merged xiretza requested to merge xiretza/firmware:bhi160-magnetometer into master
Files
8
@@ -100,3 +100,29 @@ Supports the BHI160 sensor on the card10 for accelerometer, gyroscope...
Close the connection to the sensor
.. class:: bhi160.BHI160Magnetometer
Magnetometer of the BHI160
Parameters:
sample_rate: int, optional
Sample rate (default is 4)
dynamic_range: int, optional
Dynamic range (default is 1)
callback: callable, optional
Call this callback when enough data is collected (default is None)
.. todo:: The callback functionality is untested, so do not be confused if it does not work.
sample_buffer_len: int, optional
Length of sample buffer (default is 200)
.. py:method:: read():
Read sensor values
:returns: Collected sensor values as list
.. py:method:: close():
Close the connection to the sensor
Loading