AnsweredAssumed Answered

sw4stm32 basic function and printf not working

Question asked by g. lewis on Feb 9, 2017
Latest reply on May 29, 2017 by Mark Shoe

Hi, I'm beginner and I started by a blink project using SW4STM32 along with STMCubeMx libraries set up for my board which is the STM411RE board.

It  works well using the following lines in the main while loop:

      for(int i=0;i<14200000;i++);

but It doen't work when I tried to replace the for statment: for(int i=0;i<14200000;i++); by a function declared above the main{}


void tempo(void){
    for(int i=0;i<14200000;i++);

This is really simple but I'm stuck here.

I got another problem with the printf statemenent that doesn't do anything. Don't know if this is correlated to it but it seems that there is something wrong on the configuration of Eclipse or missing I guess.

ps: I have include stdio.h on top of the program.

Thanks for your help