Subversion Repositories FlightCtrl

Rev

Rev 2099 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1910 - 1
// Or does this simply belong in uart0.h??
2
#ifndef _EXTERNALCONTROL_H
3
#define _EXTERNALCONTROL_H
4
 
5
#include<inttypes.h>
6
 
7
typedef struct {
8
        uint8_t digital[2];
9
        uint8_t remoteButtons;
10
        int8_t pitch;
11
        int8_t roll;
12
        int8_t yaw;
13
        uint8_t throttle;
14
        int8_t height;
15
        uint8_t free; // Let's use that for commands now.
16
        uint8_t frame;
17
        uint8_t config; // Let's use that for arguemnts.
18
}__attribute__((packed)) ExternalControl_t;
19
 
20
extern ExternalControl_t externalControl;
21
extern uint8_t externalControlActive;
22
 
2103 - 23
void EC_periodicTaskAndPRYT(int16_t* PRYT);
1910 - 24
uint8_t EC_getArgument(void);
25
uint8_t EC_getCommand(void);
26
int16_t EC_getVariable(uint8_t varNum);
27
void EC_calibrate(void);
28
uint8_t EC_getSignalQuality(void);
29
void EC_setNeutral(void);
30
 
31
#endif