How about just a simple 'echo-ing' program to make sure everything is working first
Type on the PC, characters should show up on the PC. Led should blink once for each character received/sent-back. Don't type any faster than 54 characters per second.Code:Include "modedefs.bas" DEFINE OSC 3 DEFINE HSER_RCSTA 90h DEFINE HSER_TXSTA 24h DEFINE HSER_SPBRG 92 DEFINE HSER_CLROERR 1 Char VAR BYTE : led var portb.6 : output led : input portb.5 : output portb.7 Main: HSERIN [Char] : led = 1 : HSEROUT [Char] : pause 10 : led = 0 : GOTO Main END




Bookmarks