40 #if PERIODIC_TELEMETRY
43 static void send_actuators_raw(
struct transport_tx *trans,
struct link_device *
dev)
47 for (
int i = 0; i < ACTUATORS_NB; i++) {
48 v[i] = actuators[i].driver_val;
50 pprz_msg_send_ACTUATORS_RAW(trans,
dev, AC_ID , ACTUATORS_NB, v);
57 for (
int i = 0; i < ACTUATORS_NB; i++) {
58 v[i] = actuators[i].pprz_val;
60 pprz_msg_send_ACTUATORS(trans,
dev, AC_ID , ACTUATORS_NB, v);
64 struct actuator_t actuators[ACTUATORS_NB];
67 int16_t actuators_pprz[ACTUATORS_NB];
70 bool actuators_delay_done;
75 #if defined ACTUATORS_START_DELAY && ! defined SITL
76 actuators_delay_done =
false;
79 actuators_delay_done =
true;
80 actuators_delay_time = 0;
84 #if (defined INTERMCU_AP)
86 #elif (defined INTERMCU_FBW)
94 #if PERIODIC_TELEMETRY
107 pprz_t trimmed_commands[COMMANDS_NB];
109 for (i = 0; i < COMMANDS_NB; i++) {trimmed_commands[i] =
commands[i];}
123 #if (defined INTERMCU_AP)
126 #elif (defined INTERMCU_FBW)
uint8_t autopilot_get_mode(void)
get autopilot mode
pprz_t command_pitch_trim
pprz_t commands[COMMANDS_NB]
Hardware independent code for commands handling.
static void send_actuators(struct transport_tx *trans, struct link_device *dev)
void intermcu_send_commands(pprz_t *command_values, uint8_t ap_mode)
send command vector over intermcu link instead of actuators
Inter-MCU on the AP side.
void actuators_periodic(void)
void actuators_init(void)
Hardware independent API for actuators (servos, motor controllers).
static const struct usb_device_descriptor dev
Architecture independent timing functions.
#define SysTimeTimerStart(_t)
int8_t register_periodic_telemetry(struct periodic_telemetry *_pt, uint8_t _id, telemetry_cb _cb)
Register a telemetry callback function.
Periodic telemetry system header (includes downlink utility and generated code).
#define DefaultPeriodic
Set default periodic telemetry.
unsigned int uint32_t
Typedef defining 32 bit unsigned int type.
short int16_t
Typedef defining 16 bit short type.