Add sample to read from up to 10 FIFO streaming devices, using the
sensor_stream() API and the RTIO framework:
https://docs.zephyrproject.org/latest/services/rtio/index.html
The devices has to be aliased as streamN (0 <= N <= 9) in DT, and
will be instantiated using SENSOR_DT_STREAM_IODEV() macro.
Currently the sample gets/prints data on SENSOR_TRIG_FIFO_WATERMARK
trigger basis for the following sensor channels:
- SENSOR_CHAN_ACCEL_XYZ
- SENSOR_CHAN_GYRO_XYZ
- SENSOR_CHAN_DIE_TEMP
- SENSOR_CHAN_GAME_ROTATION_VECTOR
- SENSOR_CHAN_GRAVITY_VECTOR
- SENSOR_CHAN_GBIAS_XYZ
Signed-off-by: Armando Visconti <armando.visconti@st.com>
13 lines
338 B
YAML
13 lines
338 B
YAML
sample:
|
|
name: Stream FIFO sample
|
|
tests:
|
|
sample.sensor.stream_fifo:
|
|
harness: console
|
|
tags: sensors
|
|
filter: dt_alias_exists("stream0")
|
|
harness_config:
|
|
type: one_line
|
|
regex:
|
|
- "^\\s*[0-9A-Za-z_,+-.]*@[0-9A-Fa-f]* \\[m\/s\\^2\\]: \
|
|
\\(\\s*-?[0-9\\.]*,\\s*-?[0-9\\.]*,\\s*-?[0-9\\.]*\\)$"
|