ACwing FC firmware
STM32WB55: attitude IEKF, altitude Kalman filter, flight core, protocol v2
Loading...
Searching...
No Matches
telemetry.c File Reference
#include "telemetry.h"
#include <string.h>
Include dependency graph for telemetry.c:

Go to the source code of this file.

Functions

uint16_t tlm_crc16 (const uint8_t *data, size_t len)
 
size_t tlm_encode (uint8_t type, const void *payload, uint8_t len, uint8_t *out, size_t cap)
 Writes the complete frame into out; returns its length, 0 if cap is too small.
 

Function Documentation

◆ tlm_crc16()

uint16_t tlm_crc16 ( const uint8_t *  data,
size_t  len 
)

Definition at line 7 of file telemetry.c.

Referenced by frame_ready(), and tlm_encode().

Here is the caller graph for this function:

◆ tlm_encode()

size_t tlm_encode ( uint8_t  type,
const void *  payload,
uint8_t  len,
uint8_t *  out,
size_t  cap 
)

Writes the complete frame into out; returns its length, 0 if cap is too small.

Definition at line 18 of file telemetry.c.

References cap, tlm_crc16(), TLM_OVERHEAD, TLM_SYNC0, and TLM_SYNC1.

Referenced by pv2_frame(), send_status(), tlm_build_init(), tlm_build_replay(), and tlm_build_state().

Here is the call graph for this function:
Here is the caller graph for this function: