Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 17:33 27 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 : Creating my own ps2 keyboard with MMBasic

Author Message
Plasmamac

Guru

Joined: 31/01/2019
Location: Germany
Posts: 554
Posted: 09:31am 08 Oct 2023
Copy link to clipboard 
Print this post

Hi , id like to build my own  Ps2 keyboard with MMBasic and the pico.
So i need to create the PS2 protocol within MMBasic. What di you think?
Plasma
 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 6798
Posted: 09:42am 08 Oct 2023
Copy link to clipboard 
Print this post

It depends on how far you want to go. The simplest PS/2 keyboard (just the basic keys) might be ok, but some keys send several characters. You might find that scanning the keyboard in software isn't very fast, especially if you want rollover detection. Probably fine for ordinary typing but not for gaming.

Lots of info Here

The transmission protocol might be difficult to get the timing right in MMBasic. You may need to use BITSTREAM or even a PIO.

I suggest you try a little ASCII keyboard routine first and see how you get on.
Edited 2023-10-08 19:45 by Mixtel90
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9308
Posted: 05:45am 09 Oct 2023
Copy link to clipboard 
Print this post

Holtek used to sell a PS/2 keyboard chip in 40-pin DIL, but I don't know if you can get them anymore.  


HT82K628A_Holtek.pdf


It would probably be easier to go this route, then to try to have MMBASIC generate the PS/2 codes, as I understand the PS/2 protocol is pretty fast.
Smoke makes things work. When the smoke gets out, it stops!
 
Frank N. Furter
Guru

Joined: 28/05/2012
Location: Germany
Posts: 830
Posted: 07:05am 09 Oct 2023
Copy link to clipboard 
Print this post

Maybe this will help you?

Arduino ps2dev library
https://github.com/Harvie/ps2dev/tree/15cb56c78ddccfeeeccf4e26e04d2385c380a1f4

Frank
 
Print this page


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

© JAQ Software 2024