6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Mon May 20, 2024 6:15 pm

All times are UTC




Post new topic Reply to topic  [ 16 posts ]  Go to page 1, 2  Next
Author Message
PostPosted: Sat Aug 05, 2023 6:48 pm 
Offline

Joined: Wed Mar 22, 2023 3:58 am
Posts: 37
Location: teh interwebz
I found this discontinued keyboard on Ebay for $12 that's the perfect size for a portable retro computer:

https://i.imgur.com/PgikFnh.jpeg

It has two flat ribbon cables, one with 7 pins and one with 12 pins. I presume one is for rows and the other is for columns.

I did an exhaustive search for documentation, and the only datasheet I was able to find is this four-page PDF, which reveals nothing about the cable pinouts:

https://www.fcl.fujitsu.com/downloads/M ... kb1406.pdf

Now I'm naively thinking I can figure out the rows and columns for each key by putting ohmmeter probes on each conductor of each cable and pressing keys to do a continuity check. I imagine that there are diodes in the keyboard to prevent current from taking multiple paths, so it would be important to connect the meter in a particular direction. Moreover, many of the keys are multi-function, so I'd have to try various combinations of keys to see what happens.

Before I go down that rabbit hole, I want to see if (1) anyone has used this keyboard and can provide a mapping, or (2) barring that, if anyone can give me some pointers on how to proceed with the hacking.


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 7:17 pm 
Offline

Joined: Fri Jul 09, 2021 10:12 pm
Posts: 741
Nice keyboard. 7x12 is 84 but there are only 64 keys. 8x8 would have worked. Perhaps they wanted to support 7-bit bytes, or perhaps some of the pins are not part of the matrix, or maybe the matrix uses all the pins but isn't fully-populated with keys.

Continuity checks seem sensible first of all. If at the end all 7x12 connections seem to correspond to rows and columns then great. If some do not then they could be some sort of power and ground, in which case there may be active circuitry inside and you need to be more cautious. Does it have any LEDs?


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 7:26 pm 
Offline

Joined: Wed Mar 22, 2023 3:58 am
Posts: 37
Location: teh interwebz
There are no LEDs on the keyboard, nor do I see any way a microcontroller would fit in there. It appears to be a purely passive device.

Not only would 8x8 have worked, it would've been more readily usable with the vintage keyboard scan ICs I have on hand.


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 7:27 pm 
Offline

Joined: Wed Mar 22, 2023 3:58 am
Posts: 37
Location: teh interwebz
A keyboard that spits out 7-bit ASCII codes would actually be ideal for my purposes.


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 7:36 pm 
Offline

Joined: Fri Jul 09, 2021 10:12 pm
Posts: 741
Hah, I doubt it will spit out ASCII codes - the datasheet says it is a row/column matrix as you said.

You can speed the process up by shorting all the 7 connectors together, and all the 12 connectors together, and doing a continuity check from one to the other. Asssuming one connector is for rows and the other columns, it should show no continuity unless you press a key.

If so, unshort one of the connectors and test each signal in turn, identifying all the keys in this row. Then do the reverse and figure out all the keys in each column. If one of the signal lines doesn't seem to correspond to any keys then something fishy is going on, but otherwise you should then know the row and column for every key.


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 8:05 pm 
Offline

Joined: Wed Mar 22, 2023 3:58 am
Posts: 37
Location: teh interwebz
Thanks for the advice!

Do you think it's more likely the 12-pin connector is for rows or for columns?


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 8:31 pm 
Offline

Joined: Fri Jul 09, 2021 10:12 pm
Posts: 741
What's the difference, electrically?


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 8:59 pm 
Offline

Joined: Wed Mar 22, 2023 3:58 am
Posts: 37
Location: teh interwebz
If there are diodes in series with each key switch, current would only flow in one direction. I can simply try the meter in both directions till I get a hit though.


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 9:10 pm 
Offline

Joined: Fri Jul 09, 2021 10:12 pm
Posts: 741
Yes, the polarity may matter if there are diodes, and maybe only for some keys like shift, ctrl, space, etc, but even so I don't think there's a particular standard for whether rows or columns are high or low, it's just a helpful metaphor. If it's documented then you can adopt their terms, otherwise I think you're free to call them whichever way makes most sense to you.


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 9:21 pm 
Offline
User avatar

Joined: Wed Feb 13, 2013 1:38 pm
Posts: 586
Location: Michigan, USA
Perhaps some switches have their own pin (ctrl, fn, shift)?


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 9:43 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8440
Location: Southern California
That looks like a really nice keyboard!
No True Scotsman wrote:
A keyboard that spits out 7-bit ASCII codes would actually be ideal for my purposes.
and
Michael wrote:
Perhaps some switches have their own pin (ctrl, fn, shift)?

I've thought about that, but not really spent the time to figure out what might work best.  Besides the n-key rollover needed for fast typing, you have <Shift>, <Ctrl>, etc. which are always used in combination with other keys, and they won't repeat.  With the repeating ones, you'd want to be able to tell it how long to wait before a held-down key starts repeating, and how fast to repeat, and not fill a buffer with repeats if the computer is not ready to accept them, something that my PC with separate keyboard violates which can be irritating.  I designed a product for work about eight years ago that had a 16-key keypad, with 0-9, then A-F were shifted keys, and other shifted keys were YES/ENTER, NO/ESC, MENU, HOME, and END.  The shift was push-on/push-off, since it was intended to be operated with one hand and holding the shift key while pressing another might not be so practical, and the only keys that had auto-repeat were the cursor keys so for example you wouldn't have to press the right-arrow key twelve times to move twelve places to the right.  Depending on where you are in the menu tree, you can see it could be a big problem if the YES/ENTER key had auto-repeat!

_________________
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 10:41 pm 
Offline

Joined: Wed Mar 22, 2023 3:58 am
Posts: 37
Location: teh interwebz
That keyboard is smaller in person than it looks in the photo, but it'll get used in some project or another.


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 10:43 pm 
Offline

Joined: Wed Mar 22, 2023 3:58 am
Posts: 37
Location: teh interwebz
Michael wrote:
Perhaps some switches have their own pin (ctrl, fn, shift)?


Possibly. In fact, it may have to be that way to facilitate holding down a shift(ish) key whilst typing another key sequence.


Top
 Profile  
Reply with quote  
PostPosted: Sat Aug 05, 2023 11:19 pm 
Offline
User avatar

Joined: Fri Dec 11, 2009 3:50 pm
Posts: 3354
Location: Ontario, Canada
No True Scotsman wrote:
It has two flat ribbon cables, one with 7 pins and one with 12 pins. I presume one is for rows and the other is for columns.
I have doubts about this assumption. To be on the safe side, I'd just view them as 19 unknown pins.

I'd use a variation on the procedure George suggested. Press and hold one (or several) keys down; then, go hunting until you find some continuity. I'd use a pattern like this:

  • Focus on pin 1: Test from 1 to 2, then 1 to 3, 1 to 4 etc.
  • Focus on pin 2: Test from 2 to 1, then 2 to 3, 2 to 4 etc.
  • Focus on pin 3: Test from 3 to 1, then 3 to 2, 3 to 4 etc.
  • ( etc )

Testing from 1 to 2 implies the opposite polarity compared to testing from 2 to 1, so the procedure works even if diodes are present (which I doubt, but anyway...). Note, BTW, that the "continuity" test needs to reveal values as high as 1,000 ohms. So, be sure your meter (or other apparatus) will detect a diode in series with 1,000 ohms.

Having found the first instance of continuity, release additional buttons until only one is pressed (the one whose continuity has been detected).

You've now identified one pin that you can consider to be a column and one pin that you can consider to be a row. :) With this key information, the puzzle begins to unravel more quickly. You can now improvise some new test patterns to finish the job, starting by putting the focus on one of the two pins you've identified.

-- Jeff

PS- I'd stick with this approach even though, as Michael says, some switches may have their own pin. You'll sort the whole thing out eventually.

_________________
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html


Top
 Profile  
Reply with quote  
PostPosted: Sun Aug 06, 2023 8:28 am 
Offline

Joined: Mon Jan 19, 2004 12:49 pm
Posts: 691
Location: Potsdam, DE
Is there no visibility of the traces on the circuit board from the back?


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 16 posts ]  Go to page 1, 2  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: