Shop OBEX P1 Docs P2 Docs Learn Events
PS2 Keyboard signals on Propstick output lines? — Parallax Forums

PS2 Keyboard signals on Propstick output lines?

T&E EngineerT&E Engineer Posts: 1,396
edited 2006-10-06 12:08 in Propeller 1
It has been a while since I have been on this forum. I have a Propstick and have built the PS2 circuit and TV monitor circuit to see keys typed on the TV when going through a PS2 keyboard.

I want to connect a PS2 keyboard to my ZX81 computer. I am hoping it would not be too difficult using a PropStick and keyboard driver. How do you send the keyboard signals to output pins on the Propeller so that it can be read by the data lines (8) on a ZX81 computer? It sounds like an expensive way to interface but I have everything and thought it would be a good project to try. I do not know Assembler on the Propeller yet and barely know Spin coding. Any help here?

Thanks.

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2006-10-06 02:24
    Correct me if I'm wrong, but·the ZX81 computer had its own keyboard that it scanned by itself did it not?· I never had a ZX81, so I don't know enough details, but I can't imagine it having a PS/2 keyboard.· In that case, the Propeller has to·drive the PS/2 keyboard, decode the key codes, translate them to key closures compatible with the ZX81 keyboard, and present the fake key closures to the ZX81.· Right?· I suspect you'd have to do the Z80 interfacing in assembly language and use the keyboard object supplied with the Propeller Tool to handle the PS/2 keyboard.
  • T&E EngineerT&E Engineer Posts: 1,396
    edited 2006-10-06 03:07
    The ZX81 has a membrane keyboard that is a simple matrix style connection. Nothing to complicated here.

    http://www.mainbyte.com/ts1000/sch.html

    http://www.user.dccnet.com/wrigter/index_files/ZXKBDv3.htm

    What I would like the PropStick (Spin code) to do is all of the decoding and the ZX81 would not have to decode anything in assembly code.

    Basically the 8 outputs going to the ZX81 data lines for the keyboard would still allow the ZX81 matrix keyboard to function and it sends the correct keycode to the datalines that would match a matrix keyboard.

    I think this is correct in what it would need to do.

    Comments?
  • Mike GreenMike Green Posts: 23,101
    edited 2006-10-06 03:59
    You will need to do this in assembly language to get a fast enough response to the various control lines. It does look simple enough. The PS/2 keyboard routine (in SPIN) would lookup the current keyboard character in a table which would give the 8 bit scan address and data bits. The assembly driver would simply compare the A8-A16 value with the scan address and, when equal, would output the 5 bit data value on the data lines while the I/O strobe was active.

    You probably will need to modify the current PS/2 keyboard driver to pass key up transitions to the ZX81 routine so the 5 bit data value can be cleared when the PS/2 keyboard key is released.

    Post Edited (Mike Green) : 10/6/2006 4:03:15 AM GMT
  • NewzedNewzed Posts: 2,503
    edited 2006-10-06 12:08
    On my Timex Sinclair, which was the first computer I ever had, I remember disconnecting the little membrane keyboard and substituting a teletype keyboard I picked up from a surplus place.· That has been about forty years ago and I have no idea of how I did it - I just know that it worked.

    Sid

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Sid Weaver
    Need a TV Module?

    Newzed@aol.com
    ·
Sign In or Register to comment.