Paparazzi UAS  v5.14.0_stable-0-g3f680d1
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
superbitrf.h File Reference

DSM2 and DSMX datalink implementation for the cyrf6936 2.4GHz radio chip trough SPI. More...

Go to the source code of this file.

Data Structures

struct  SuperbitRF
 

Enumerations

enum  dsm_protocol {
  DSM_DSM2_1 = 0x01, DSM_DSM2_2 = 0x02, DSM_DSM2P = 0x10, DSM_DSMXP = 0x11,
  DSM_DSMX_1 = 0xA2, DSM_DSMX_2 = 0xB2, DSM_DSM2_1 = 0x01, DSM_DSM2_2 = 0x02,
  DSM_DSM2P = 0x10, DSM_DSMXP = 0x11, DSM_DSMX_1 = 0xA2, DSM_DSMX_2 = 0xB2
}
 

Functions

void superbitrf_set_mfg_id (uint32_t id)
 
void superbitrf_set_protocol (uint8_t protocol)
 

Variables

struct SuperbitRF superbitrf
 

Detailed Description

DSM2 and DSMX datalink implementation for the cyrf6936 2.4GHz radio chip trough SPI.

Dummy for sim so you don't have to remove the superbitrf.xml settings file.

Definition in file superbitrf.h.


Data Structure Documentation

struct SuperbitRF

Definition at line 43 of file superbitrf.h.

+ Collaboration diagram for SuperbitRF:
Data Fields
uint8_t bind_mfg_id[4] The MFG id where the receiver is bound to.
uint32_t bind_mfg_id32 The MFG id where the receiver is bound to in uint32.
uint8_t channel The current channel number.
uint8_t channel_idx The current channel index.
uint8_t channels[23] The channels used for DSM2/DSMX.
uint16_t crc_seed The CRC seed that is calculated with the bind MFG id.
struct Cyrf6936 cyrf6936 The cyrf chip used.
uint8_t data_col The data code column number calculated with the bind MFG id.
struct link_device device Generic device interface.
uint32_t irq_count How many interrupts are made.
uint8_t num_channels The number of channels the transmitter has.
bool packet_loss When we have packet loss last packet.
uint8_t packet_loss_bit The packet loss indicating bit.
enum dsm_protocol protocol The protocol the transmitter uses.
uint32_t rc_count How many valid RC packages are received.
bool rc_frame_available When a RC frame is available.
int16_t rc_values[14] The rc values from the packet.
enum dsm_resolution resolution The resolution that the transmitter has.
uint32_t resync_count The amount of resyncs needed during transfer.
uint32_t rx_packet_count How many packets are received(also the invalid)
struct pprz_transport rx_transport The receive transport.
uint8_t sop_col The sop code column number calculated with the bind MFG id.
uint8_t state The states each status can be in.
enum SuperbitRFStatus status The status of the superbitRF.
uint8_t timeouts The amount of timeouts.
uint32_t timer The timer in microseconds.
bool timer_overflow When the timer overflows.
uint32_t timing1 Time between last receive in microseconds.
uint32_t timing2 Time between second last receive in microseconds.
uint32_t transfer_timeouts The amount of timeouts during transfer.
uint8_t tx_buffer[SUPERBITRF_TX_BUFFER_SIZE] The transmit buffer.
uint8_t tx_extract_idx The transmit buffer extract index.
uint8_t tx_insert_idx The transmit buffer insert index.
uint32_t tx_packet_count How many packets are send(also the invalid)
uint32_t uplink_count How many valid uplink packages are received.

Enumeration Type Documentation

Enumerator
DSM_DSM2_1 

The original DSM2 protocol with 1 packet of data.

DSM_DSM2_2 

The original DSM2 protocol with 2 packets of data.

DSM_DSM2P 

Our own DSM2 Paparazzi protocol.

DSM_DSMXP 

Our own DSMX Paparazzi protocol.

DSM_DSMX_1 

The original DSMX protocol with 1 packet of data.

DSM_DSMX_2 

The original DSMX protocol with 2 packets of data.

DSM_DSM2_1 

The original DSM2 protocol with 1 packet of data.

DSM_DSM2_2 

The original DSM2 protocol with 2 packets of data.

DSM_DSM2P 

Our own DSM2 Paparazzi protocol.

DSM_DSMXP 

Our own DSMX Paparazzi protocol.

DSM_DSMX_1 

The original DSMX protocol with 1 packet of data.

DSM_DSMX_2 

The original DSMX protocol with 2 packets of data.

Definition at line 33 of file superbitrf.h.

Function Documentation

void superbitrf_set_mfg_id ( uint32_t  id)

Definition at line 34 of file superbitrf.c.

void superbitrf_set_protocol ( uint8_t  protocol)

Definition at line 39 of file superbitrf.c.

Variable Documentation

struct SuperbitRF superbitrf

Definition at line 32 of file superbitrf.c.