drivers/sensors/lis2mdl: Increase buffer size
The ODR of this sensor is too high to have a buffer size of 1. Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
This commit is contained in:
parent
7d9d59f069
commit
41eaa50a58
2 changed files with 8 additions and 0 deletions
|
|
@ -1659,6 +1659,13 @@ config SENSORS_LIS2MDL_THREAD_STACKSIZE
|
|||
---help---
|
||||
The stack size for the worker thread that performs measurements
|
||||
|
||||
config SENSORS_LIS2MDL_ORB_BUFSIZE
|
||||
int "LIS2MDL uORB buffer size"
|
||||
default 10
|
||||
range 0 100
|
||||
---help---
|
||||
The size of the uORB circular buffer for storing measurements.
|
||||
|
||||
config SENSORS_LIS2MDL_FETCH
|
||||
bool "Enable LIS2MDL fetch capability"
|
||||
default n
|
||||
|
|
|
|||
|
|
@ -1307,6 +1307,7 @@ int lis2mdl_register(FAR struct i2c_master_s *i2c, int devno, uint8_t addr,
|
|||
|
||||
priv->lower.ops = &g_sensor_ops;
|
||||
priv->lower.type = SENSOR_TYPE_MAGNETIC_FIELD;
|
||||
priv->lower.nbuffer = CONFIG_SENSORS_LIS2MDL_ORB_BUFSIZE;
|
||||
priv->enabled = false;
|
||||
priv->lowpower = false;
|
||||
priv->offsets = false;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue