AnsweredAssumed Answered

Getting printf on STM32F407 Discovery board

Question asked by ihatetoregister.ihat on Jun 11, 2015
Latest reply on Jun 11, 2015 by Clive One
Hi i am new to embedded system programming and stumbled upon this basic problem of re-directing output to the ITM Port0. I read multiple posts on the same but sadly I cant get it to work. I shall try to be as descriptive as possible. I am following the lab mentioned here Page 15 Section 19. 

Board : STM32F407 Discovery board
Keil 5.15 MDK 

 * CMSIS-RTOS 'main' function template

#define osObjectsPublic                     // define objects in main module
#include "osObjects.h"                      // RTOS object definitions
#define ITM_Port8(n) (*((volatile unsigned char *)(0xE0000000+4*n)))

 * main: initialize and start the system
int main (void) {
     int value = 1;
  osKernelInitialize ();                    // initialize CMSIS-RTOS
  // initialize peripherals here
  // create 'thread' functions that start executing,
  // example: tid_name = osThreadCreate (osThread(name), NULL);

     ITM_Port8(0) = value ;
     while(ITM_Port8(0) == 0);
     ITM_Port8(0) = 0x0D;
     while(ITM_Port8(0) == 0);
     ITM_Port8(0) = 0x0A;
     osKernelStart ();                         // start thread execution 

 I know the settings for the core clock speed are important so i set it correctly to 168MHz . Here is the snapshot to be sure.,bqdc5c9#1

What am i missing here ? Seems my debug view gets nothing . Any help for me ?