Can any one help me with my problem please ? I have written a simple program wich prints out a data on USART.write module .
I have tried different baud rates but I always get rubish as a result on IDE terminal in Swordfish compiler SE VERSION .
However when I print data before while loop . the data is printed out correctly . the following is my code :
Code: Select all
Device = 18F452
Clock = 10
Include "USART.bas"
Include "convert.bas"
TRISC.6 = 0 // PORTC.6 AS OUTPUT
RCSTA.7 = 1
TXSTA.6 = 0
TXSTA.5 = 1
TXSTA.4 = 0 // asynchronous mode
TXSTA.2 = 1 // high baud rate
USART.SetBaudrate(br9600)
USART.Write("This is a message ",13,10)
While TRUE
USART.Write("This is a message ",13,10) // This doesnt work !!!!!!!!!!
Wend
cheers