Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 20:40 25 Nov 2024 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : Wanted PS/2 keyboard test program

Author Message
al18
Senior Member

Joined: 06/07/2019
Location: United States
Posts: 205
Posted: 11:58pm 11 Apr 2024
Copy link to clipboard 
Print this post

Looking for a simple PS/2 keyboard test program for the PicoMite VGA. I’m testing a number of keyboards for a friend, and the good ones will be donated to Goodwill. Looking for a graphical layout of a standard 101 key keyboard onscreen. I press each key and if the key press registers, the key turns green onscreen.

The PicoMite seems a good fit, as it boots in 2 seconds. An old Windows PC takes at least a minute, and you can’t hot swap a PS/2 keyboard.

Has anyone written such a program they would like to share?
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4226
Posted: 07:22am 12 Apr 2024
Copy link to clipboard 
Print this post

You can make this very fancy, but many people will have to look at the keyboard, and then the screen, an then the keyboard, and…
But humans can look and listen simultaneous….


 Do
   A$=Inkey$
   If A$<>"" Then
     'Print Asc(A$)
     Select Case Asc(A$)
       Case < 32
         Play tone 400,400,100
       Case > 90
         Play tone 500,500,100
       Case Else
         Play tone 600,600,100
     End Select
   EndIf
 Loop


You can test all keys except num_lock and caps_lock. But these have LED's on a typical keyboard.
The tone is different when you press <CTRL-H> or <SHIFT-H> or <H>, that is how you check the control and shift keys.
Be carefull about caps_lock when it's ON you cannot detect shift key is operated.

Success

Volhout

Take care with <CTRL>+"C"....
Edited 2024-04-12 18:10 by Volhout
PicomiteVGA PETSCII ROBOTS
 
Print this page


To reply to this topic, you need to log in.

© JAQ Software 2024