Minor tweaks
* config file * timer driver
This commit is contained in:
parent
45fde375b8
commit
64b8265e90
@ -88,12 +88,3 @@
|
|||||||
//#define SPI5_GPIO_PORT
|
//#define SPI5_GPIO_PORT
|
||||||
//#define SPI5_GPIO_PINS
|
//#define SPI5_GPIO_PINS
|
||||||
|
|
||||||
/****************************************************************************
|
|
||||||
* ADC pin and use configuration
|
|
||||||
****************************************************************************/
|
|
||||||
|
|
||||||
// ADC1: ADC1_0 --> PA0, ADC1_1 -->PA1
|
|
||||||
//#define USE_ADC1
|
|
||||||
//#define ADC1_GPIO_PORT _GPIOA
|
|
||||||
//#define ADC1_GPIO_PINS PIN_0|PIN_1
|
|
||||||
|
|
||||||
|
|||||||
@ -3,9 +3,6 @@
|
|||||||
extern Clock_t sysclks;
|
extern Clock_t sysclks;
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
/** timerX_isr
|
|
||||||
* timerX ISR (Interrupt Service Routine)
|
|
||||||
*/
|
|
||||||
static OnTick callback1 = 0;
|
static OnTick callback1 = 0;
|
||||||
static OnTick callback2 = 0;
|
static OnTick callback2 = 0;
|
||||||
static OnTick callback3 = 0;
|
static OnTick callback3 = 0;
|
||||||
@ -31,6 +28,7 @@ void TIM4_IRQHandler(void) {
|
|||||||
TIM4->SR &= ~0x1F;
|
TIM4->SR &= ~0x1F;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
int timer_config_cb(TIM_TypeDef* tmr, uint32_t* clk, OnTick cb) {
|
int timer_config_cb(TIM_TypeDef* tmr, uint32_t* clk, OnTick cb) {
|
||||||
IRQn_Type irqn;
|
IRQn_Type irqn;
|
||||||
uint32_t irq_priority;
|
uint32_t irq_priority;
|
||||||
|
|||||||
Reference in New Issue
Block a user