Paparazzi UAS v7.1_unstable
Paparazzi is a free software Unmanned Aircraft System.
Loading...
Searching...
No Matches
actuators_dshot_arch.c
Go to the documentation of this file.
1/*
2 * Copyright (C) 2018 Gautier Hattenberger <gautier.hattenberger@enac.fr>
3 *
4 * This file is part of paparazzi
5 *
6 * paparazzi is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2, or (at your option)
9 * any later version.
10 *
11 * paparazzi is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with paparazzi; see the file COPYING. If not, see
18 * <http://www.gnu.org/licenses/>.
19 */
20
27
30#include "modules/core/abi.h"
31#include "mcu_periph/ram_arch.h"
32#include "mcu_periph/gpio.h"
33#include BOARD_CONFIG
34
35#if PERIODIC_TELEMETRY
38#endif
39
40// Default number of poles in a motor
41// Used to convert electrical RPM to physical RPM
42// by dividing eRPM by (MOTOR_POLES/2)
43#ifndef DSHOT_MOTOR_POLES
44#define DSHOT_MOTOR_POLES 14
45#endif
46
51
53
54#if DSHOT_CONF_TIM1
55static DSHOTDriver DSHOTD1;
56static IN_DMA_SECTION_NOINIT(DshotDmaBuffer dshot1DmaBuffer);
57#if DSHOT_BIDIR
58static IN_DMA_SECTION_NOINIT(DshotRpmCaptureDmaBuffer dshot1DmaCaptureBuffer);
59#endif
60static DSHOTConfig dshotcfg1 = DSHOT_CONF1_DEF;
61#endif
62#if DSHOT_CONF_TIM2
63static DSHOTDriver DSHOTD2;
64static IN_DMA_SECTION_NOINIT(DshotDmaBuffer dshot2DmaBuffer);
65#if DSHOT_BIDIR
66static IN_DMA_SECTION_NOINIT(DshotRpmCaptureDmaBuffer dshot2DmaCaptureBuffer);
67#endif
68static DSHOTConfig dshotcfg2 = DSHOT_CONF2_DEF;
69#endif
70#if DSHOT_CONF_TIM3
71static DSHOTDriver DSHOTD3;
72static IN_DMA_SECTION_NOINIT(DshotDmaBuffer dshot3DmaBuffer);
73#if DSHOT_BIDIR
74static IN_DMA_SECTION_NOINIT(DshotRpmCaptureDmaBuffer dshot3DmaCaptureBuffer);
75#endif
76static DSHOTConfig dshotcfg3 = DSHOT_CONF3_DEF;
77#endif
78#if DSHOT_CONF_TIM4
79static DSHOTDriver DSHOTD4;
80static IN_DMA_SECTION_NOINIT(DshotDmaBuffer dshot4DmaBuffer);
81#if DSHOT_BIDIR
82static IN_DMA_SECTION_NOINIT(DshotRpmCaptureDmaBuffer dshot4DmaCaptureBuffer);
83#endif
84static DSHOTConfig dshotcfg4 = DSHOT_CONF4_DEF;
85#endif
86#if DSHOT_CONF_TIM5
87static DSHOTDriver DSHOTD5;
88static IN_DMA_SECTION_NOINIT(DshotDmaBuffer dshot5DmaBuffer);
89#if DSHOT_BIDIR
90static IN_DMA_SECTION_NOINIT(DshotRpmCaptureDmaBuffer dshot5DmaCaptureBuffer);
91#endif
92static DSHOTConfig dshotcfg5 = DSHOT_CONF5_DEF;
93#endif
94#if DSHOT_CONF_TIM8
95static DSHOTDriver DSHOTD8;
96static IN_DMA_SECTION_NOINIT(DshotDmaBuffer dshot8DmaBuffer);
97#if DSHOT_BIDIR
98static IN_DMA_SECTION_NOINIT(DshotRpmCaptureDmaBuffer dshot8DmaCaptureBuffer);
99#endif
100static DSHOTConfig dshotcfg8 = DSHOT_CONF8_DEF;
101#endif
102#if DSHOT_CONF_TIM9
103static DSHOTDriver DSHOTD9;
104static IN_DMA_SECTION_NOINIT(DshotDmaBuffer dshot9DmaBuffer);
105#if DSHOT_BIDIR
106static IN_DMA_SECTION_NOINIT(DshotRpmCaptureDmaBuffer dshot9DmaCaptureBuffer);
107#endif
108static DSHOTConfig dshotcfg9 = DSHOT_CONF9_DEF;
109#endif
110
111#if PERIODIC_TELEMETRY
112static void esc_msg_send(struct transport_tx *trans, struct link_device *dev) {
113 for (uint8_t i = 0; i < ACTUATORS_DSHOT_NB; i++) {
114 if (actuators_dshot_values[i].activated) {
115 float bat_voltage = electrical.vsupply;
116 float power = actuators_dshot_values[i].current * bat_voltage;
117 float temp_dev = 0;
118 pprz_msg_send_ESC(trans, dev, AC_ID,
119 &actuators_dshot_values[i].current,
120 &bat_voltage,
121 &power,
123 &actuators_dshot_values[i].voltage,
124 &actuators_dshot_values[i].energy,
125 &actuators_dshot_values[i].temp,
126 &temp_dev,
127 &i,
128 &i);
129 }
130 }
131}
132#endif
133
134static void dshot_init_struct(struct dshot * ds)
135{
136 ds->cmd = 0;
137 ds->rpm = 0;
138 ds->current = 0;
139 ds->voltage = 0;
140 ds->activated = false;
141}
142
143static void dshot_set_struct(struct dshot * ds, struct dshot_private * dsp, DSHOTDriver * driver, uint32_t channel)
144{
145 ds->activated = true;
146 dsp->driver = driver;
147 dsp->channel = channel;
148}
149
150#define _CONCAT_GPIO(num, name) UART ## num ## _GPIO_ ## name
151#define CONCAT_GPIO(num, name) _CONCAT_GPIO(num, name)
152
154{
155 // init dshot structure to zero
156 for (int i = 0; i < ACTUATORS_DSHOT_NB; i++) {
158 }
159
160 // configure telemetry pin if needed
161 // the serial device interface might have to be activated
162 // by hand (ChibiOS HAL), but PPRZ one disabled
163#ifdef DSHOT_TIM1_TELEMETRY_NUM
165 CONCAT_GPIO(DSHOT_TIM1_TELEMETRY_NUM, PORT_RX),
166 CONCAT_GPIO(DSHOT_TIM1_TELEMETRY_NUM, RX),
167 CONCAT_GPIO(DSHOT_TIM1_TELEMETRY_NUM, AF), FALSE);
168 PRINT_CONFIG_VAR(DSHOT_TIM1_TELEMETRY_NUM);
169#endif
170#ifdef DSHOT_TIM2_TELEMETRY_NUM
172 CONCAT_GPIO(DSHOT_TIM2_TELEMETRY_NUM, PORT_RX),
173 CONCAT_GPIO(DSHOT_TIM2_TELEMETRY_NUM, RX),
174 CONCAT_GPIO(DSHOT_TIM2_TELEMETRY_NUM, AF), FALSE);
175#endif
176#ifdef DSHOT_TIM3_TELEMETRY_NUM
178 CONCAT_GPIO(DSHOT_TIM3_TELEMETRY_NUM, PORT_RX),
179 CONCAT_GPIO(DSHOT_TIM3_TELEMETRY_NUM, RX),
180 CONCAT_GPIO(DSHOT_TIM3_TELEMETRY_NUM, AF), FALSE);
181#endif
182#ifdef DSHOT_TIM4_TELEMETRY_NUM
184 CONCAT_GPIO(DSHOT_TIM4_TELEMETRY_NUM, PORT_RX),
185 CONCAT_GPIO(DSHOT_TIM4_TELEMETRY_NUM, RX),
186 CONCAT_GPIO(DSHOT_TIM4_TELEMETRY_NUM, AF), FALSE);
187 PRINT_CONFIG_VAR(DSHOT_TIM4_TELEMETRY_NUM);
188#endif
189#ifdef DSHOT_TIM5_TELEMETRY_NUM
191 CONCAT_GPIO(DSHOT_TIM5_TELEMETRY_NUM, PORT_RX),
192 CONCAT_GPIO(DSHOT_TIM5_TELEMETRY_NUM, RX),
193 CONCAT_GPIO(DSHOT_TIM5_TELEMETRY_NUM, AF), FALSE);
194#endif
195#ifdef DSHOT_TIM8_TELEMETRY_NUM
197 CONCAT_GPIO(DSHOT_TIM8_TELEMETRY_NUM, PORT_RX),
198 CONCAT_GPIO(DSHOT_TIM8_TELEMETRY_NUM, RX),
199 CONCAT_GPIO(DSHOT_TIM8_TELEMETRY_NUM, AF), FALSE);
200#endif
201#ifdef DSHOT_TIM9_TELEMETRY_NUM
203 CONCAT_GPIO(DSHOT_TIM9_TELEMETRY_NUM, PORT_RX),
204 CONCAT_GPIO(DSHOT_TIM9_TELEMETRY_NUM, RX),
205 CONCAT_GPIO(DSHOT_TIM9_TELEMETRY_NUM, AF), FALSE);
206#endif
207
208 /*----------------
209 * Configure GPIO
210 *----------------*/
211#ifdef DSHOT_SERVO_0
212 gpio_setup_pin_af_pullup(DSHOT_SERVO_0_GPIO, DSHOT_SERVO_0_PIN, DSHOT_SERVO_0_AF);
213 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_0], &actuators_dshot_private[DSHOT_SERVO_0], &DSHOT_SERVO_0_DRIVER, DSHOT_SERVO_0_CHANNEL);
214#endif
215#ifdef DSHOT_SERVO_1
216 gpio_setup_pin_af_pullup(DSHOT_SERVO_1_GPIO, DSHOT_SERVO_1_PIN, DSHOT_SERVO_1_AF);
217 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_1], &actuators_dshot_private[DSHOT_SERVO_1], &DSHOT_SERVO_1_DRIVER, DSHOT_SERVO_1_CHANNEL);
218#endif
219#ifdef DSHOT_SERVO_2
220 gpio_setup_pin_af_pullup(DSHOT_SERVO_2_GPIO, DSHOT_SERVO_2_PIN, DSHOT_SERVO_2_AF);
221 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_2], &actuators_dshot_private[DSHOT_SERVO_2], &DSHOT_SERVO_2_DRIVER, DSHOT_SERVO_2_CHANNEL);
222#endif
223#ifdef DSHOT_SERVO_3
224 gpio_setup_pin_af_pullup(DSHOT_SERVO_3_GPIO, DSHOT_SERVO_3_PIN, DSHOT_SERVO_3_AF);
225 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_3], &actuators_dshot_private[DSHOT_SERVO_3], &DSHOT_SERVO_3_DRIVER, DSHOT_SERVO_3_CHANNEL);
226#endif
227#ifdef DSHOT_SERVO_4
228 gpio_setup_pin_af_pullup(DSHOT_SERVO_4_GPIO, DSHOT_SERVO_4_PIN, DSHOT_SERVO_4_AF);
229 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_4], &actuators_dshot_private[DSHOT_SERVO_4], &DSHOT_SERVO_4_DRIVER, DSHOT_SERVO_4_CHANNEL);
230#endif
231#ifdef DSHOT_SERVO_5
232 gpio_setup_pin_af_pullup(DSHOT_SERVO_5_GPIO, DSHOT_SERVO_5_PIN, DSHOT_SERVO_5_AF);
233 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_5], &actuators_dshot_private[DSHOT_SERVO_5], &DSHOT_SERVO_5_DRIVER, DSHOT_SERVO_5_CHANNEL);
234#endif
235#ifdef DSHOT_SERVO_6
236 gpio_setup_pin_af_pullup(DSHOT_SERVO_6_GPIO, DSHOT_SERVO_6_PIN, DSHOT_SERVO_6_AF);
237 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_6], &actuators_dshot_private[DSHOT_SERVO_6], &DSHOT_SERVO_6_DRIVER, DSHOT_SERVO_6_CHANNEL);
238#endif
239#ifdef DSHOT_SERVO_7
240 gpio_setup_pin_af_pullup(DSHOT_SERVO_7_GPIO, DSHOT_SERVO_7_PIN, DSHOT_SERVO_7_AF);
241 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_7], &actuators_dshot_private[DSHOT_SERVO_7], &DSHOT_SERVO_7_DRIVER, DSHOT_SERVO_7_CHANNEL);
242#endif
243#ifdef DSHOT_SERVO_8
244 gpio_setup_pin_af_pullup(DSHOT_SERVO_8_GPIO, DSHOT_SERVO_8_PIN, DSHOT_SERVO_8_AF);
245 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_8], &actuators_dshot_private[DSHOT_SERVO_8], &DSHOT_SERVO_8_DRIVER, DSHOT_SERVO_8_CHANNEL);
246#endif
247#ifdef DSHOT_SERVO_9
248 gpio_setup_pin_af_pullup(DSHOT_SERVO_9_GPIO, DSHOT_SERVO_9_PIN, DSHOT_SERVO_9_AF);
249 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_9], &actuators_dshot_private[DSHOT_SERVO_9], &DSHOT_SERVO_9_DRIVER, DSHOT_SERVO_9_CHANNEL);
250#endif
251#ifdef DSHOT_SERVO_10
252 gpio_setup_pin_af_pullup(DSHOT_SERVO_10_GPIO, DSHOT_SERVO_10_PIN, DSHOT_SERVO_10_AF);
253 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_10], &actuators_dshot_private[DSHOT_SERVO_10], &DSHOT_SERVO_10_DRIVER, DSHOT_SERVO_10_CHANNEL);
254#endif
255#ifdef DSHOT_SERVO_11
256 gpio_setup_pin_af_pullup(DSHOT_SERVO_11_GPIO, DSHOT_SERVO_11_PIN, DSHOT_SERVO_11_AF);
257 dshot_set_struct(&actuators_dshot_values[DSHOT_SERVO_11], &actuators_dshot_private[DSHOT_SERVO_11], &DSHOT_SERVO_11_DRIVER, DSHOT_SERVO_11_CHANNEL);
258#endif
259
260 /*---------------
261 * Configure DSHOT
262 *---------------*/
263#if DSHOT_CONF_TIM1
264 dshotStart(&DSHOTD1, &dshotcfg1);
265#endif
266#if DSHOT_CONF_TIM2
267 dshotStart(&DSHOTD2, &dshotcfg2);
268#endif
269#if DSHOT_CONF_TIM3
270 dshotStart(&DSHOTD3, &dshotcfg3);
271#endif
272#if DSHOT_CONF_TIM4
273 dshotStart(&DSHOTD4, &dshotcfg4);
274#endif
275#if DSHOT_CONF_TIM5
276 dshotStart(&DSHOTD5, &dshotcfg5);
277#endif
278#if DSHOT_CONF_TIM8
279 dshotStart(&DSHOTD8, &dshotcfg8);
280#endif
281#if DSHOT_CONF_TIM9
282 dshotStart(&DSHOTD9, &dshotcfg9);
283#endif
284
285#if PERIODIC_TELEMETRY
287#endif
288}
289
290
292{
293#ifdef DSHOT_SERVO_0
294 dshotSetThrottle(&DSHOT_SERVO_0_DRIVER, DSHOT_SERVO_0_CHANNEL, actuators_dshot_values[DSHOT_SERVO_0].cmd);
295#endif
296#ifdef DSHOT_SERVO_1
297 dshotSetThrottle(&DSHOT_SERVO_1_DRIVER, DSHOT_SERVO_1_CHANNEL, actuators_dshot_values[DSHOT_SERVO_1].cmd);
298#endif
299#ifdef DSHOT_SERVO_2
300 dshotSetThrottle(&DSHOT_SERVO_2_DRIVER, DSHOT_SERVO_2_CHANNEL, actuators_dshot_values[DSHOT_SERVO_2].cmd);
301#endif
302#ifdef DSHOT_SERVO_3
303 dshotSetThrottle(&DSHOT_SERVO_3_DRIVER, DSHOT_SERVO_3_CHANNEL, actuators_dshot_values[DSHOT_SERVO_3].cmd);
304#endif
305#ifdef DSHOT_SERVO_4
306 dshotSetThrottle(&DSHOT_SERVO_4_DRIVER, DSHOT_SERVO_4_CHANNEL, actuators_dshot_values[DSHOT_SERVO_4].cmd);
307#endif
308#ifdef DSHOT_SERVO_5
309 dshotSetThrottle(&DSHOT_SERVO_5_DRIVER, DSHOT_SERVO_5_CHANNEL, actuators_dshot_values[DSHOT_SERVO_5].cmd);
310#endif
311#ifdef DSHOT_SERVO_6
312 dshotSetThrottle(&DSHOT_SERVO_6_DRIVER, DSHOT_SERVO_6_CHANNEL, actuators_dshot_values[DSHOT_SERVO_6].cmd);
313#endif
314#ifdef DSHOT_SERVO_7
315 dshotSetThrottle(&DSHOT_SERVO_7_DRIVER, DSHOT_SERVO_7_CHANNEL, actuators_dshot_values[DSHOT_SERVO_7].cmd);
316#endif
317#ifdef DSHOT_SERVO_8
318 dshotSetThrottle(&DSHOT_SERVO_8_DRIVER, DSHOT_SERVO_8_CHANNEL, actuators_dshot_values[DSHOT_SERVO_8].cmd);
319#endif
320#ifdef DSHOT_SERVO_9
321 dshotSetThrottle(&DSHOT_SERVO_9_DRIVER, DSHOT_SERVO_9_CHANNEL, actuators_dshot_values[DSHOT_SERVO_9].cmd);
322#endif
323#ifdef DSHOT_SERVO_10
324 dshotSetThrottle(&DSHOT_SERVO_10_DRIVER, DSHOT_SERVO_10_CHANNEL, actuators_dshot_values[DSHOT_SERVO_10].cmd);
325#endif
326#ifdef DSHOT_SERVO_11
327 dshotSetThrottle(&DSHOT_SERVO_11_DRIVER, DSHOT_SERVO_11_CHANNEL, actuators_dshot_values[DSHOT_SERVO_11].cmd);
328#endif
329
330#if DSHOT_CONF_TIM1
331 dshotSendFrame(&DSHOTD1);
332#endif
333#if DSHOT_CONF_TIM2
334 dshotSendFrame(&DSHOTD2);
335#endif
336#if DSHOT_CONF_TIM3
337 dshotSendFrame(&DSHOTD3);
338#endif
339#if DSHOT_CONF_TIM4
340 dshotSendFrame(&DSHOTD4);
341#endif
342#if DSHOT_CONF_TIM5
343 dshotSendFrame(&DSHOTD5);
344#endif
345#if DSHOT_CONF_TIM8
346 dshotSendFrame(&DSHOTD8);
347#endif
348#if DSHOT_CONF_TIM9
349 dshotSendFrame(&DSHOTD9);
350#endif
351
352 // update public structure with latest telemetry data
353 // and send actuator feedback message
354 struct act_feedback_t feedback[ACTUATORS_DSHOT_NB] = { 0 };
355 for (uint8_t i = 0; i < ACTUATORS_DSHOT_NB; i++) {
356 feedback[i].idx = get_servo_idx_DSHOT(i);
357 if (actuators_dshot_values[i].activated) {
359 // RPM in telemetry is electrical RMP with a scale of 100,
360 // so physical value is 2 * 100 / motor_poles
361 const int32_t rpm = dtelem.frame.rpm * 200 / DSHOT_MOTOR_POLES;
362 feedback[i].rpm = rpm;
363 feedback[i].set.rpm = true;
364 actuators_dshot_values[i].rpm = (float)rpm;
365 actuators_dshot_values[i].current = (float)dtelem.frame.current * 0.01f;
366 actuators_dshot_values[i].voltage = (float)dtelem.frame.voltage * 0.01f;
367 actuators_dshot_values[i].energy = (float)dtelem.frame.consumption;
368 actuators_dshot_values[i].temp = (float)dtelem.frame.temp;
369#if DSHOT_BIDIR
370 // overwrite RPM if DSHOT_BIDIR is used as it provides faster update
371 const uint32_t erpm = dshotGetRpm(actuators_dshot_private[i].driver, actuators_dshot_private[i].channel);
372 if ((erpm != DSHOT_BIDIR_ERR_CRC) && (erpm != DSHOT_BIDIR_TLM_EDT)) {
373 feedback[i].rpm = erpm * 2 / DSHOT_MOTOR_POLES;
374 feedback[i].set.rpm = true;
375 actuators_dshot_values[i].rpm = (float)feedback[i].rpm;
376 } else {
377 feedback[i].set.rpm = false;
378 }
379#endif
380 }
381 }
382 AbiSendMsgACT_FEEDBACK(ACT_FEEDBACK_DSHOT_ID, feedback, ACTUATORS_DSHOT_NB);
383}
Main include for ABI (AirBorneInterface).
#define ACT_FEEDBACK_DSHOT_ID
struct dshot actuators_dshot_values[ACTUATORS_DSHOT_NB]
bool activated
current dshot channel is activated
float cmd
command
float current
current
float voltage
motor current
#define ACTUATORS_DSHOT_NB
Maxnum number of DSHOT commands This should be large enough for max applications: 8 motors +1 in case...
float rpm
rpm
void gpio_setup_pin_af_pullup(ioportid_t port, uint16_t pin, uint8_t af)
Setup a gpio for input pullup with alternate function.
Definition gpio_arch.c:61
void gpio_setup_pin_af(ioportid_t port, uint16_t pin, uint8_t af, bool is_output)
Setup a gpio for input or output with alternate function.
Definition gpio_arch.c:65
void actuators_dshot_arch_init(void)
Arch dependent init.
struct dshot_private actuators_dshot_private[ACTUATORS_DSHOT_NB]
#define DSHOT_MOTOR_POLES
#define CONCAT_GPIO(num, name)
static void dshot_set_struct(struct dshot *ds, struct dshot_private *dsp, DSHOTDriver *driver, uint32_t channel)
static void dshot_init_struct(struct dshot *ds)
static void esc_msg_send(struct transport_tx *trans, struct link_device *dev)
void actuators_dshot_arch_commit(void)
DSHOTDriver * driver
static struct uart_periph * dev
struct Electrical electrical
Definition electrical.c:92
Interface for electrical status: supply voltage, current, battery status, etc.
void dshotStart(DSHOTDriver *driver, const DSHOTConfig *config)
Configures and activates the DSHOT peripheral.
Definition esc_dshot.c:155
void dshotSetThrottle(DSHOTDriver *driver, const uint8_t index, const uint16_t throttle)
prepare throttle order for specified ESC
Definition esc_dshot.c:302
DshotTelemetry dshotGetTelemetry(DSHOTDriver *driver, uint32_t index)
return last received telemetry data
Definition esc_dshot.c:469
void dshotSendFrame(DSHOTDriver *driver)
send throttle order
Definition esc_dshot.c:405
DSHOT driver based on ChibiOS.
DshotTelemetryFrame frame
Definition esc_dshot.h:159
#define DSHOT_BIDIR_TLM_EDT
Definition esc_dshot.h:66
#define DSHOT_BIDIR_ERR_CRC
special values returned by dshotGetRpm function
Definition esc_dshot.h:65
DSHOT Driver configuration structure.
Definition esc_dshot.h:182
telemetry with timestamp
Definition esc_dshot.h:158
Some architecture independent helper functions for GPIOs.
int32_t rpm
RPM.
Definition actuators.h:54
struct act_feedback_t::act_feedback_set_t set
Bitset registering what is set as feedback.
uint8_t idx
General index of the actuators (generated in airframe.h).
Definition actuators.h:45
PRINT_CONFIG_VAR(ONELOOP_ANDI_FILT_CUTOFF)
Specific RAM section for DMA usage on F7.
#define IN_DMA_SECTION_NOINIT(var)
Definition ram_arch.h:85
uint16_t rpm
Definition rpm_sensor.c:33
#define FALSE
Definition std.h:5
DSHOT driver structure.
Definition esc_dshot.h:287
int16_t register_periodic_telemetry(struct periodic_telemetry *_pt, uint16_t _id, telemetry_cb _cb)
Register a telemetry callback function.
Definition telemetry.c:51
Periodic telemetry system header (includes downlink utility and generated code).
#define DefaultPeriodic
Set default periodic telemetry.
Definition telemetry.h:66
int int32_t
Typedef defining 32 bit int type.
unsigned int uint32_t
Typedef defining 32 bit unsigned int type.
unsigned char uint8_t
Typedef defining 8 bit unsigned char type.