------| Atari XL as usb keyboard |-----			
			
SIO2Arduino is used as disk emulator and later extended to allow			
serial communication to a host pc. Translation code was added to			
convert atari key codes to ps2 keycodes. 			
			
XLK08.BAS			
atari basic program to send key strokes to the SIO2Arduino hardware			
			
900 KCNT=3			
910 EOL=155			
920 AADR=753			
930 KADR=764:POKE (KADR),255			
940 OPEN #1,8,0,"P:"			
950 K=PEEK(KADR):IF K=255 THEN 950			
960 POKE (KADR),255			
970 PUT #1,K:PUT #1,EOL			
980 IF K=39 THEN 1010			
990 PUT #1,K:PUT #1,EOL			
1000 GOTO 950			
1010 ON PEEK(AADR)=3 GOTO 1010			
1020 PUT #1,K:PUT #1,EOL			
1030 GOTO 950			
			
XLK09.BAS has the following change in line 900			
900 CLOSE #1:KCNT=3			
910 EOL=155			
920 AADR=753			
 ...			
			
adding CLOSE #1 allows me to interrupt and add more code and then rerun			
the keyboard program without errors			
			
original codes are based on the following source			
https://github.com/whizzosoftware/SIO2Arduino
			
notes ====			
to display basic listing on a unix terminal			
cat PROGRAM.BAS | tr '\233' '\n'			
			
..                                                                         
SIO2Arduino.diff                               2018-May-29 15:28    44.1 KB
intro                                          2018-Jun-06 14:58     0.8 KB
.