Let's sound a piezoelectric buzzer and speaker [STM32 Nucleo]
Let's connect a piezoelectric buzzer and speaker to an STM32 MCU (Nucleo board) and play them. This time, I used an inexpensive piezoelectric buzzer (model: LF-MB12B06). This is an application of a peripheral timer. For details, see Timer/Counter [Details of STM32's High Functional and General Purpose Timer]. Table of contents1 Piezoelectric buzzer specifications2 Circuit of […]
PWM dimming of LEDs with MCU [STM32 Nucleo]
How can we use the digital output of MCU to dim LEDs? I will explain the magic trick of using the digital output of MCU to control the brightness continuously in an analog manner, as if dimming were a magic trick. Colum For example, if an analog VR is added to the input and the […]
Variable pulse application [Pulse control with STM32].
This application controls arbitrary frequency pulses with STM32 MCU. In this example, the frequency changes when a pushbutton switch is held down, but it can be applied in many other ways. Setting SpecificationPins used: PB8 Alternate output (Timer output) PC13 Input (Pushbotton SW)Peripheral used: TIM4_CH3 Count CLK1kHz Colum This application uses a combination of switch […]
PWM pulse application [PWM output of STM32]
This is an application program that sets the timer of the STM32 MCU to PWM output. You can see the frequency and pulse duty ratio change depending on the setting value. Setting specification:Pin used: PB8 Alternate output (Timer output)Peripheral used:TIM4_CH3 Counter CLK 1kHz
Fixed pulse application [Pulse output of STM32]
This application program uses the timer of the STM32 MCU to generate a fixed frequency pulse only when an input switch is pressed. Setting Specification:Pin used:PB8 Alternate output(Timer output)Peripheral used:TIM4_CH3 Counter CLK 1kHz