36 #include <caml/mlvalues.h>
46 #define PPM_OF_NPS(_nps, _neutral, _min, _max) \
47 ((_nps) >= 0 ? (_neutral) + (_nps) * ((_max)-(_neutral)) : (_neutral) + (_nps) * ((_neutral)- (_min)))
49 void radio_control_feed(
void)
56 RADIO_PITCH_NEUTRAL, \
64 RADIO_THROTTLE_NEUTRAL, \
74 void radio_control_feed(
void) {}
75 #endif //RADIO_CONTROL
77 #elif !USE_JSBSIM // not NPS and not JSBSIM -> simple ocaml sim
90 #else // RADIO_CONTROL
91 value
update_rc_channel(value c __attribute__((unused)), value v __attribute__((unused)))
96 #endif // RADIO_CONTROL
uint16_t ppm_pulses[RADIO_CTL_NB]
value send_ppm(value unit)
struct NpsRadioControl nps_radio_control
void ppm_arch_init(void)
Architecture dependant code.
value update_rc_channel(value c, value v)
volatile bool ppm_frame_available