I am testing new ADI Monitor debug kernel that was included in the Keil v.8.01 eval package. Kernel is working as expected (download, stepping, breakpoints, ...), but there is no serial putchar() output on the terminal 1 window as indicated in the documentation. The hardware is OK (code without ADI Monitor is running correctly). Below is the code used for testing. Configuration of UART was removed for ADI Monitor according to the ADI Monitor documentation. The LED is toggled but there is no serial output. Something is probably wrong but I am out of idea ,,:-( Please, can anybody help?
#include <stdio.h> #include <ADuC836.h> #define ADIMONITOR #define SET_FCLK (PLLCON = 0x00) // Fclk = 12.582912 MHz #define LED T0 // pin P3.4 void main (void){ unsigned int i; #ifndef ADIMONITOR SET_FCLK; // core clock 12.582192 MHz //UART config, T3 clock, 9600 bauds (page 60 in the ADuC 836 manual) T3CON = 0x85; // (9600, 12.582912 MHz core freq.) T3FD = 0x12; // divider for 9600 bauds SCON = 0x52; #endif while(1) { LED = !LED; // toggle LED putchar('A'); for (i = 0; i < (10000); i++) // delay ; } }