Hi everyone.
I made a keyboard driver, with brazilian key map. and i've got a problem:
when i press ? key, if in map array i have this: '?' it prints me a wierd symbol on a grey background ( i do not modify the backgroung wich is black for other chars ) and it is flickering. If in the array I put the ascii code for ? char, i get the ? flickering on grey background.
I'm using fritzos printf function ( the which cames with pk0.7 ).
Any one can tell me why this is happens?
Keyboard problems
-
jrfritz
Re:Keyboard problems
Well, that key in ASCII may mean soemthing other than that character.....(I am the manager of FritzOS)...
I don't know why its doing that, and the only guess I can make is that character means something else for the video card....
I don't know why its doing that, and the only guess I can make is that character means something else for the video card....
-
eL JeDi
Re:Keyboard problems
I've got the same problem but with ? and ?! chars. I'm working on it.
here is my key map, if anyone wants to try it:
char unsh[] = { NULL, ESC,'1','2','3','4','5','6','7','8','9','0',0x60,0xA1,BKS,TAB,'q','w','e','r','t','y',
'u','i','o','p',0,'+',ENTER,0,'a','s','d','f','g','h','j','k','l','?',0,0,0,0x87,'z','x','c','v','b','n','m',',','.','-',0,0,0,' ',0,AF1,AF2,AF3,AF4,AF5,AF6,AF7,AF8,AF9,AF10,0,0,AHOME,AUP,APGUP,'-',ALEFT,'5',ARIGHT,
'+',AEND,ADOWN,APGDN,AINS,ADEL,0,0,0,AF11,AF12 };
This is spanish key map for unshifted keys.
0x87 is char ?
0x60 is '
0xA1 is ?
here is my key map, if anyone wants to try it:
char unsh[] = { NULL, ESC,'1','2','3','4','5','6','7','8','9','0',0x60,0xA1,BKS,TAB,'q','w','e','r','t','y',
'u','i','o','p',0,'+',ENTER,0,'a','s','d','f','g','h','j','k','l','?',0,0,0,0x87,'z','x','c','v','b','n','m',',','.','-',0,0,0,' ',0,AF1,AF2,AF3,AF4,AF5,AF6,AF7,AF8,AF9,AF10,0,0,AHOME,AUP,APGUP,'-',ALEFT,'5',ARIGHT,
'+',AEND,ADOWN,APGDN,AINS,ADEL,0,0,0,AF11,AF12 };
This is spanish key map for unshifted keys.
0x87 is char ?
0x60 is '
0xA1 is ?
-
Tim
Re:Keyboard problems
Try 'unsigned char' instead of 'char', or use literal numeric values instead of '?'. C doesn't handle non-US characters well... 
- Pype.Clicker
- Member

- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:Keyboard problems
what actually happens is that neither Linux nor Windows (and your development env. is probably one of those) use the same characters table as BIOS do. So if you compile your file with a '?' (=0xE7 in Linux) in it and then try to display it from a bootsector, you'll discover that another character is on the screen (most probably a math symbol or a table-writing symbol)...
-
eL JeDi
Re:Keyboard problems
Hi,
Tim, it was a mistake form my copy+paste. I use unsined char in the array.
I'm going to try to change BIOS ASCII code to the same as linux uses before to fix my kernel to boot from grub.
Tim, it was a mistake form my copy+paste. I use unsined char in the array.
I'm going to try to change BIOS ASCII code to the same as linux uses before to fix my kernel to boot from grub.