mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2024-12-01 09:24:10 +01:00
Get PIOS_GCSRCVR working on revo
This commit is contained in:
parent
dc7fe1bdd8
commit
9f93c9cbec
@ -189,6 +189,7 @@ extern uint32_t pios_com_vcp_id;
|
||||
//------------------------
|
||||
#define PIOS_RCVR_MAX_DEVS 3
|
||||
#define PIOS_RCVR_MAX_CHANNELS 12
|
||||
#define PIOS_GCSRCVR_TIMEOUT_MS 100
|
||||
|
||||
//-------------------------
|
||||
// Receiver PPM input
|
||||
|
@ -73,7 +73,7 @@ static struct pios_gcsrcvr_dev *PIOS_gcsrcvr_alloc(void)
|
||||
if (!gcsrcvr_dev) return(NULL);
|
||||
|
||||
gcsrcvr_dev->magic = PIOS_GCSRCVR_DEV_MAGIC;
|
||||
gcsrcvr_dev->Fresh = FALSE;
|
||||
gcsrcvr_dev->Fresh = false;
|
||||
gcsrcvr_dev->supv_timer = 0;
|
||||
|
||||
/* The update callback cannot receive the device pointer, so set it in a global */
|
||||
@ -94,7 +94,7 @@ static struct pios_gcsrcvr_dev *PIOS_gcsrcvr_alloc(void)
|
||||
|
||||
gcsrcvr_dev = &pios_gcsrcvr_devs[pios_gcsrcvr_num_devs++];
|
||||
gcsrcvr_dev->magic = PIOS_GCSRCVR_DEV_MAGIC;
|
||||
gcsrcvr_dev->Fresh = FALSE;
|
||||
gcsrcvr_dev->Fresh = false;
|
||||
gcsrcvr_dev->supv_timer = 0;
|
||||
|
||||
global_gcsrcvr_dev = gcsrcvr_dev;
|
||||
@ -108,7 +108,7 @@ static void gcsreceiver_updated(UAVObjEvent * ev)
|
||||
struct pios_gcsrcvr_dev *gcsrcvr_dev = global_gcsrcvr_dev;
|
||||
if (ev->obj == GCSReceiverHandle()) {
|
||||
GCSReceiverGet(&gcsreceiverdata);
|
||||
gcsrcvr_dev->Fresh = TRUE;
|
||||
gcsrcvr_dev->Fresh = true;
|
||||
}
|
||||
}
|
||||
|
||||
@ -163,7 +163,7 @@ static void PIOS_gcsrcvr_Supervisor(uint32_t gcsrcvr_id) {
|
||||
for (int32_t i = 0; i < GCSRECEIVER_CHANNEL_NUMELEM; i++)
|
||||
gcsreceiverdata.Channel[i] = PIOS_RCVR_TIMEOUT;
|
||||
|
||||
gcsrcvr_dev->Fresh = FALSE;
|
||||
gcsrcvr_dev->Fresh = false;
|
||||
}
|
||||
|
||||
#endif /* PIOS_INCLUDE_GCSRCVR */
|
||||
|
@ -149,6 +149,7 @@ include $(PIOS)/STM32F4xx/library.mk
|
||||
SRC += $(PIOSCOMMON)/pios_mpu6000.c
|
||||
SRC += $(PIOSCOMMON)/pios_bma180.c
|
||||
SRC += $(PIOSCOMMON)/pios_etasv3.c
|
||||
SRC += $(PIOSCOMMON)/pios_gcsrcvr.c
|
||||
SRC += $(PIOSCOMMON)/pios_l3gd20.c
|
||||
SRC += $(PIOSCOMMON)/pios_hmc5883.c
|
||||
SRC += $(PIOSCOMMON)/pios_ms5611.c
|
||||
|
@ -82,7 +82,7 @@
|
||||
//#define PIOS_INCLUDE_SBUS
|
||||
#define PIOS_INCLUDE_PPM
|
||||
#define PIOS_INCLUDE_PWM
|
||||
//#define PIOS_INCLUDE_GCSRCVR
|
||||
#define PIOS_INCLUDE_GCSRCVR
|
||||
|
||||
#define PIOS_INCLUDE_SETTINGS
|
||||
#define PIOS_INCLUDE_FLASH
|
||||
|
Loading…
Reference in New Issue
Block a user