Paparazzi UAS v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
input_capture_arch.h
Go to the documentation of this file.
1#pragma once
2
3#include "ch.h"
4#include "hal.h"
5
6
7#ifdef __cplusplus
8extern "C" {
9#endif
10
16 } ;
18 typedef struct TimICDriver TimICDriver;
21
39
40
57
58
66
75
83
91
100
101 void timIcRccEnable(const TimICDriver * const timicp);
102 void timIcRccDisable(const TimICDriver * const timicp);
103
104
105
106#ifdef __cplusplus
107}
108#endif
void timIcStop(TimICDriver *timicp)
stop a quadrature encoder driver
void(* TimICCallbackCapture_t)(const TimICDriver *timicp, uint32_t channel, uint32_t capture)
void timIcObjectInit(TimICDriver *timicp)
Initializes an input capture driver.
void timIcStopCapture(TimICDriver *timicp)
stop to capture
void timIcRccEnable(const TimICDriver *const timicp)
void timIcStart(TimICDriver *timicp, const TimICConfig *configp)
start an input capture driver
TimICCallbackCapture_t capture_cb
uint32_t channel
mutex to protect data read/write in concurrent context
void timIcStartCapture(TimICDriver *timicp)
start to capture
@ TIMIC_READY
@ TIMIC_ACTIVE
@ TIMIC_STOP
@ CH2_FALLING_EDGE
@ CH1_RISING_EDGE
@ CH4_RISING_EDGE
@ CH3_RISING_EDGE
@ CH2_RISING_EDGE
@ CH1_BOTH_EDGES
@ CH4_FALLING_EDGE
@ CH3_BOTH_EDGES
@ CH3_FALLING_EDGE
@ CH4_BOTH_EDGES
@ CH1_FALLING_EDGE
@ CH2_BOTH_EDGES
TimICCallbackOverflow_t overflow_cb
@ TIMIC_INPUT_CAPTURE
@ TIMIC_PWM_IN
void timIcRccDisable(const TimICDriver *const timicp)
enum TimICState state
void(* TimICCallbackOverflow_t)(const TimICDriver *timicp)
enum TimICMode mode
const TimICConfig * config
Current configuration data.
stm32_tim_t * timer
hardware timer pointer (example : &STM32_TIM1)
TimIC Driver configuration structure.
Structure representing a TimIC driver.
uint16_t foo
Definition main_demo5.c:58
unsigned int uint32_t
Typedef defining 32 bit unsigned int type.