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

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

#include "subsystems/datalink/superbitrf.h"
+ Include dependency graph for superbitrf_rc.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define RADIO_CONTROL_NB_CHANNEL   14
 
#define RADIO_THROTTLE   0
 
#define RADIO_ROLL   1
 
#define RADIO_PITCH   2
 
#define RADIO_YAW   3
 
#define RADIO_GEAR   4
 
#define RADIO_FLAP   5
 
#define RADIO_AUX1   5
 
#define RADIO_AUX2   6
 
#define RADIO_AUX3   7
 
#define RADIO_AUX4   8
 
#define RADIO_AUX5   9
 
#define RADIO_AUX6   10
 
#define RADIO_AUX7   11
 
#define RADIO_AUX8   12
 
#define RADIO_AUX9   13
 
#define RADIO_MODE   RADIO_GEAR
 
#define NormalizeRcDl(_in, _out, _count)
 
#define RadioControlEvent(_received_frame_handler)
 

Detailed Description

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

Definition in file superbitrf_rc.h.

Macro Definition Documentation

#define NormalizeRcDl (   _in,
  _out,
  _count 
)
Value:
{ \
for(i = 0; i < _count; i++) { \
_out[i] = (_in[i] + MAX_PPRZ) / 2; \
Bound(_out[i], 0, MAX_PPRZ); \
} else { \
_out[i] = -_in[i]; \
Bound(_out[i], MIN_PPRZ, MAX_PPRZ); \
} \
} \
}
#define RADIO_THROTTLE
Definition: superbitrf_rc.h:38
#define MIN_PPRZ
Definition: paparazzi.h:9
if(PrimarySpektrumState.SpektrumTimer)--PrimarySpektrumState.SpektrumTimer
unsigned char uint8_t
Definition: types.h:14
#define MAX_PPRZ
Definition: paparazzi.h:8

Definition at line 60 of file superbitrf_rc.h.

#define RADIO_AUX1   5

Definition at line 44 of file superbitrf_rc.h.

#define RADIO_AUX2   6

Definition at line 45 of file superbitrf_rc.h.

#define RADIO_AUX3   7

Definition at line 46 of file superbitrf_rc.h.

#define RADIO_AUX4   8

Definition at line 47 of file superbitrf_rc.h.

#define RADIO_AUX5   9

Definition at line 48 of file superbitrf_rc.h.

#define RADIO_AUX6   10

Definition at line 49 of file superbitrf_rc.h.

#define RADIO_AUX7   11

Definition at line 50 of file superbitrf_rc.h.

#define RADIO_AUX8   12

Definition at line 51 of file superbitrf_rc.h.

#define RADIO_AUX9   13

Definition at line 52 of file superbitrf_rc.h.

#define RADIO_CONTROL_NB_CHANNEL   14

Definition at line 34 of file superbitrf_rc.h.

#define RADIO_FLAP   5

Definition at line 43 of file superbitrf_rc.h.

#define RADIO_GEAR   4

Definition at line 42 of file superbitrf_rc.h.

#define RADIO_MODE   RADIO_GEAR

Definition at line 56 of file superbitrf_rc.h.

#define RADIO_PITCH   2

Definition at line 40 of file superbitrf_rc.h.

#define RADIO_ROLL   1

Definition at line 39 of file superbitrf_rc.h.

#define RADIO_THROTTLE   0

Definition at line 38 of file superbitrf_rc.h.

#define RADIO_YAW   3

Definition at line 41 of file superbitrf_rc.h.

#define RadioControlEvent (   _received_frame_handler)
Value:
{ \
_received_frame_handler(); \
} \
}
uint8_t frame_cpt
Definition: radio_control.h:54
uint8_t time_since_last_frame
Definition: radio_control.h:51
if(PrimarySpektrumState.SpektrumTimer)--PrimarySpektrumState.SpektrumTimer
void cyrf6936_event(struct Cyrf6936 *cyrf)
The on event call for the CYRF6936 chip.
Definition: cyrf6936.c:83
struct Cyrf6936 cyrf6936
The cyrf chip used.
Definition: superbitrf.h:74
#define FALSE
Definition: imu_chimu.h:141
pprz_t values[RADIO_CONTROL_NB_CHANNEL]
Definition: radio_control.h:55
int16_t rc_values[14]
The rc values from the packet.
Definition: superbitrf.h:106
bool_t rc_frame_available
When a RC frame is available.
Definition: superbitrf.h:103
uint8_t radio_ok_cpt
Definition: radio_control.h:52
struct RadioControl radio_control
Definition: radio_control.c:25
#define RC_OK
Definition: radio_control.h:45
uint8_t status
Definition: radio_control.h:50
#define NormalizeRcDl(_in, _out, _count)
Definition: superbitrf_rc.h:60
uint8_t num_channels
The number of channels the transmitter has.
Definition: superbitrf.h:46

Definition at line 74 of file superbitrf_rc.h.