20 #ifdef BOARD_SPEKTRUM_RX_PIN 23 #ifdef BOARD_SBUS_UART 91 memset((
void *)&
_override[0], 0,
sizeof(_override));
119 #ifdef BOARD_SPEKTRUM_RX_PIN 123 #ifdef BOARD_NRF_CS_PIN 125 parsers[pp++] =
new(ptr) NRF_parser;
127 #ifdef BOARD_SBUS_UART 155 uint8_t inp=hal_param_helper->_rc_input;
179 #define LOST_TIME 500 180 #define FRAME_TIME 50 // time between packets 202 uint32_t dead_time = hal_param_helper->_rc_fs * 1000UL;
204 uint8_t inp=hal_param_helper->_rc_input;
216 uint32_t best_t=(uint32_t) -1;
224 uint32_t dt = now-pt;
256 if( ch == 2) data = 899;
263 if(over)
return over;
278 printf(
"\n failsafe! now=%lld last pulse=%lld last change=%lld\n",now, pulse, last);
285 if(hal_param_helper->_aibao_fs) {
290 if(last_4 < 990 && data >1300 && data < 1700){
294 printf(
"\nAibao failsafe! ch4=%d ch2=%d\n",
last_4, data);
310 for (uint8_t i = 0; i < len; i++){
311 periods[i] =
read(i);
320 if (
override < 0)
return false;
339 #ifdef BOARD_SPEKTRUM_RX_PIN
int printf(const char *fmt,...)
virtual uint64_t get_last_signal() const
virtual void late_init(uint8_t b)
Simple circular buffer for PEM input.
void pwmInit(bool ppmsum)
static uint64_t systick_uptime(void)
Returns the system uptime, in milliseconds.
virtual uint64_t get_last_change() const
caddr_t sbrk_ccm(int nbytes)
-*- tab-width: 4; Mode: C++; c-basic-offset: 4; indent-tabs-mode: nil -*-
virtual uint16_t get_val(uint8_t ch) const
virtual void init(uint8_t ch)=0
virtual bool bind(int dsmMode) const
virtual uint8_t get_valid_channels() const
#define F4Light_RC_INPUT_NUM_CHANNELS