Hi Mister_e & Skimask,
I thought i figured it out:
When googeling if found that the scancode for an "a" = 0x1C = 00011100, the key-scancode has to
be send LSB first resulting in 00111000.
Code:
sendthis = %00111000 'LSB first "a"
gosub calsub
sendthis = %00001111 'LSB first 0xF0 'for release key
gosub calsub
sendthis = %00111000 'LSB first "a"
gosub calsub
goto start
calsub:
parity = ~(sendthis.0 ^^ sendthis.1 ^^ sendthis.2 ^^ sendthis.3 ^^ sendthis.4 ^^ sendthis.5 ^^ sendthis.6 ^^ sendthis.7)
sendthis = sendthis << 1 'move over to insert start bit
sendthis.0 = 0 'start bit
sendthis.9 = parity
sendthis.10 = 1 'stop bit
shiftout kbddata,kbdclk,1,[sendthis\11]
return
Then i thought that the problem was the shiftout. I was sure that it had to be LSB first, clock idles high, because the clock is high to low. But a little experiment with setting this to 1 (Shift data out highest bit first. Clock idles low).
Resulted in a perfect "a" on the laptop sceen !!
But however, that was about the only character that i could generate, so i think this is not right also.
Melanie has posted a scancode table, stating that the scancode for an "a" has to be 0x1E
I can send characters, but they don't match any of the scancodes i input ? What is happening here ?
Anyone ?
Best Regards, UB
Bookmarks