10 #include "../includes/buzzer_control.h"
11 #include "../includes/config.h"
12 #include "../includes/parameters.h"
18 #define BUZZER_FREQ 4000
20 #define PERIOD_BUZZER_US (1000000 / BUZZER_FREQ)
28 TIM_TypeDef* Buzzer_Timer_Number =
reinterpret_cast<TIM_TypeDef*
>(
29 pinmap_peripheral(digitalPinToPinName(
PIN_BUZZER), PinMap_PWM));
31 STM_PIN_CHANNEL(pinmap_function(digitalPinToPinName(
PIN_BUZZER), PinMap_PWM));
39 MICROSEC_COMPARE_FORMAT);
void BuzzerControl_Init(void)
Initialization of HardwareTimer for buzzer.
void BuzzerControl_On(void)
Switch buzzer ON.
HardwareTimer * Buzzer_Hw_Timer
void BuzzerControl_Off(void)
Switch buzzer OFF.
uint32_t Buzzer_Timer_Channel