Quantcast
Channel: Microcontrollers, Programming and IoT
Viewing all articles
Browse latest Browse all 1271

STM32f407 board 5V pulse with 40kHz frequency

$
0
0
Hi! I modified the following program to get a pulse of 5V and 40kHz of frequency. I tried it in an oscilloscope and I get a 4V pulse and 12,8kHz frequency. What is wrong in the code??

Code:
#include "stm32f4xx.h"
#include "stm32f4xx_rcc.h"
#include "stm32f4xx_gpio.h"
#include "stm32f4xx_tim.h"
void TM_LEDS_Init(void) {
    GPIO_InitTypeDef GPIO_InitStruct;
    /* Clock for GPIOA */
    RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_GPIOA, ENABLE);
    */
    /* Alternating functions for pins */...
STM32f407 board 5V pulse with 40kHz frequency

Viewing all articles
Browse latest Browse all 1271

Latest Images

Trending Articles



Latest Images