Paparazzi UAS  v5.2.2_stable-0-gd6b9f29
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
ppm_arch.h File Reference

STM32 ppm decoder. More...

+ Include dependency graph for ppm_arch.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.


 The ppm counter is set-up to have 1/6 us resolution. More...
#define RC_PPM_SIGNED_TICKS_OF_USEC(_v)   (int32_t)((_v)*RC_PPM_TICKS_PER_USEC)

Detailed Description

STM32 ppm decoder.

Definition in file ppm_arch.h.

Macro Definition Documentation


Definition at line 52 of file ppm_arch.h.

#define RC_PPM_SIGNED_TICKS_OF_USEC (   _v)    (int32_t)((_v)*RC_PPM_TICKS_PER_USEC)

Definition at line 49 of file ppm_arch.h.

#define RC_PPM_TICKS_OF_USEC (   _v)    ((_v)*RC_PPM_TICKS_PER_USEC)

Definition at line 48 of file ppm_arch.h.


The ppm counter is set-up to have 1/6 us resolution.

The timer clock frequency (before prescaling): STM32F1: TIM1 -> APB2 = HCLK = 72MHz TIM2 -> 2 * APB1 = 2 * 36MHz = 72MHz STM32F4: TIM1 -> 2 * APB2 = 2 * 84MHz = 168MHz TIM2 -> 2 * APB1 = 2 * 42MHz = 84MHz

Definition at line 46 of file ppm_arch.h.

Referenced by ppm_arch_init().

#define USEC_OF_RC_PPM_TICKS (   _v)    ((_v)/RC_PPM_TICKS_PER_USEC)

Definition at line 50 of file ppm_arch.h.