Paparazzi UAS  v5.15_devel-230-gc96ce27
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
link_mcu_spi.c File Reference
#include "link_mcu_spi.h"
+ Include dependency graph for link_mcu_spi.c:

Go to the source code of this file.

Macros

#define LINK_MCU_SPI_DEV   spi1
 
#define PAYLOAD_LENGTH   sizeof(link_mcu_from_fbw_msg.payload)
 
#define LINK_MCU_FRAME_LENGTH   sizeof(struct link_mcu_msg)
 
#define ComputeChecksum(_buf)
 

Variables

struct link_mcu_msg link_mcu_from_ap_msg
 
struct link_mcu_msg link_mcu_from_fbw_msg
 
struct spi_transaction link_mcu_trans
 
bool link_mcu_received
 
static uint16_t crc = 0
 

Macro Definition Documentation

#define ComputeChecksum (   _buf)
Value:
{ \
for(i = 0; i < PAYLOAD_LENGTH; i++) { \
uint8_t _byte = ((uint8_t*)&_buf)[i]; \
crc = CrcUpdate(crc, _byte); \
} \
}
unsigned char uint8_t
Definition: types.h:14

Definition at line 41 of file link_mcu_spi.c.

#define LINK_MCU_FRAME_LENGTH   sizeof(struct link_mcu_msg)

Definition at line 39 of file link_mcu_spi.c.

#define LINK_MCU_SPI_DEV   spi1

Definition at line 26 of file link_mcu_spi.c.

#define PAYLOAD_LENGTH   sizeof(link_mcu_from_fbw_msg.payload)

Definition at line 38 of file link_mcu_spi.c.

Variable Documentation

struct link_mcu_msg link_mcu_from_ap_msg

Definition at line 29 of file link_mcu_spi.c.

struct link_mcu_msg link_mcu_from_fbw_msg

Definition at line 30 of file link_mcu_spi.c.

bool link_mcu_received

Definition at line 34 of file link_mcu_spi.c.

struct spi_transaction link_mcu_trans

Definition at line 32 of file link_mcu_spi.c.