![]() |
ACwing FC firmware
STM32WB55: attitude IEKF, altitude Kalman filter, flight core, protocol v2
|
#include "flow_bridge.h"Go to the source code of this file.
Functions | |
| static int16_t | le16 (const uint8_t *p) |
| int32_t | flow_init (flow_t *f, const sensor_bus_t *bus) |
| 0 = bridge found | |
| void | flow_decode (const uint8_t r[FLOW_FRAME_LEN], flow_frame_t *fr) |
| pure decoder (host tests) | |
| int32_t | flow_read (flow_t *f, flow_frame_t *fr) |
| 1 = new data, 0 = none, <0 error | |
|
static |
Definition at line 6 of file flow_bridge.c.
Referenced by flow_decode().
| int32_t flow_init | ( | flow_t * | f, |
| const sensor_bus_t * | bus | ||
| ) |
0 = bridge found
Definition at line 8 of file flow_bridge.c.
References flow_t::bus, FLOW_BRIDGE_WHO_AM_I, FLOW_REG_WHO_AM_I, sensor_bus_t::handle, flow_t::ok, sensor_bus_t::read, and flow_t::version.
Referenced by ext_step().
| void flow_decode | ( | const uint8_t | r[FLOW_FRAME_LEN], |
| flow_frame_t * | fr | ||
| ) |
pure decoder (host tests)
Definition at line 20 of file flow_bridge.c.
References flow_frame_t::count, flow_frame_t::dt_s, flow_frame_t::dx, flow_frame_t::dy, le16(), flow_frame_t::shutter, flow_frame_t::squal, and flow_frame_t::status.
Referenced by flow_read().
| int32_t flow_read | ( | flow_t * | f, |
| flow_frame_t * | fr | ||
| ) |
1 = new data, 0 = none, <0 error
Definition at line 31 of file flow_bridge.c.
References flow_t::bus, flow_decode(), FLOW_FRAME_LEN, FLOW_REG_FRAME, FLOW_ST_NEW, sensor_bus_t::handle, flow_t::ok, sensor_bus_t::read, and flow_frame_t::status.
Referenced by ext_step().