ps2 key board data conversion

Status
Not open for further replies.

raman00084

Full Member level 6
Joined
Nov 29, 2010
Messages
375
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,298
Visit site
Activity points
4,076
i have a ps2 key board program that decodes the key press value into ascii. example the return value of the ps2 key board is
ps2_keyvalue= 64
how to convert the ps2_keyvalue to my assigned value for example

ps2_keyvalue = 64 for the 64 i am assigning another value example 10
like this i will be assigning different values for different ascii codes
can i use array for this?

please send some c code for doing the above job i am a beginner in c
 

Assign an array of char, with the all values you want, and read it with the keyvalue as index. This will work as a lookup table.
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…