5-year old needs help with his Philips branded WYSE-board

User avatar
snufflecat

14 Nov 2018, 10:08

Hi folks,

Sorry in advance for a lot of questions that show signs of me not really knowing what I'm doing.
In short, feel free to explain things to me like I'm 5 years old, I'm not a mechanical engineer and have a very basic understanding of how electronics work, but I'm determined to get this to work. I'm here because I want to learn, so please be gentle. :)

Right, so here's the story:
Some time ago I acquired a Philips board that turned out to be a WYSE-board in disguise. It's got 107 keys.
Here's some pictures:
Photo 05-11-2018, 13 34 57.jpg
Photo 05-11-2018, 13 34 57.jpg (5.68 MiB) Viewed 2579 times
Spoiler:
Photo 05-11-2018, 13 35 01.jpg
Photo 05-11-2018, 13 35 01.jpg (4.81 MiB) Viewed 2579 times
Photo 05-11-2018, 13 35 07.jpg
Photo 05-11-2018, 13 35 07.jpg (4.51 MiB) Viewed 2579 times
Photo 05-11-2018, 13 35 19.jpg
Photo 05-11-2018, 13 35 19.jpg (6.35 MiB) Viewed 2579 times
Photo 05-11-2018, 13 35 24.jpg
Photo 05-11-2018, 13 35 24.jpg (5 MiB) Viewed 2579 times
Photo 10-11-2018, 22 44 28.jpg
Photo 10-11-2018, 22 44 28.jpg (6.41 MiB) Viewed 2579 times
Now, I've understood so much that I have to trace the matrix (I've read sixty's tutorial on the topic) and wire everything up to a Teensy, but what halts the process is a few steps:

- Figure out how what the matrix looks like
- Picking a suitable converter (I have some experience with Hasu's AEK-converter, and have downloaded and poked around in Soarer's stuff)

What have I done about the matrix?
I've used a multimeter and checked which solder points on each key are connected to what pin on the internal chip.
I logged the results in this spreadsheet:
The rows correspond to the pin number on the chip
The rows correspond to the pin number on the chip
Capture.PNG (68.46 KiB) Viewed 2579 times
With the following numbering on the pins:
chip.jpg
chip.jpg (668.45 KiB) Viewed 2579 times
The thing is that I don't know how I "consolidate" the duplicate values in the spreadsheet into a single matrix, a single set of rows and columns.

Questions:
Matrix
- How do I figure out how many rows and columns the matrix has?
- Do I have to look at the PCB? And in that case, what do I look for?

Software
- What would be better to use here? TMK or Soarer's?


Like I said, I'm asking about things I don't really understand fully, but I'm eager to learn. If there's any saints out there that are willing to explain what I need to do then I'd be thrilled. If there's anything you need to better explain then don't hesitate to ask for it, be it better pictures or other things.


Thanks for reading.

User avatar
Muirium
µ

14 Nov 2018, 11:09

Lesson #1

Controllers and converters are NOT the same thing.

Every keyboard has a controller. It’s the chip that drives the matrix. It scans rows against columns to detect which switches are pressed, and it passes this along to the computer in whatever protocol it supports: USB, AT, etc. When we build custom keyboards, we put our own controller inside. And sometimes we even tear out and replace a vintage keyboard’s original controller because it speaks some protocol we can’t convert. But this is a lot more work than using a converter.

A converter intercepts a controller’s output and converts it into something else. Soarer’s converter, for instance, is usually used to take a fully functional AT keyboard’s output and convert it to USB. A converter doesn’t scan the matrix. The controller is still doing that.

Some controllers and some converters can be programmed to perform fancy tricks like layers and macros.

The two popular projects that I know about—Soarer’s and Hasu’s TMK—both have controller and converter support, which may well be what confused you. Controllers and converters are different things! Related logic but different functions.

Questions?
Last edited by Muirium on 14 Nov 2018, 11:20, edited 1 time in total.

User avatar
Muirium
µ

14 Nov 2018, 11:14

Lesson #1a

You might want to look into this particular converter:

workshop-f7/wyse-converter-t7424.html

I don’t know if it’ll work with your specific Wyse. Look into it!

User avatar
snufflecat

14 Nov 2018, 11:29

Muirium wrote:
Spoiler:
Lesson #1

Controllers and converters are NOT the same thing.

Every keyboard has a controller. It’s the chip that drives the matrix. It scans rows against columns to detect which switches are pressed, and it passes this along to the computer in whatever protocol it supports: USB, AT, etc. When we build custom keyboards, we put our own controller inside. And sometimes we even tear out and replace a vintage keyboard’s original controller because it speaks some protocol we can’t convert. But this is a lot more work than using a converter.

A converter intercepts a controller’s output and converts it into something else. Soarer’s converter, for instance, is usually used to take a fully functional AT keyboard’s output and convert it to USB. A converter doesn’t scan the matrix. The controller is still doing that.

Some controllers and some converters can be programmed to perform fancy tricks like layers and macros.

The two popular projects that I know about—Soarer’s and Hasu’s TMK—both have controller and converter support, which may well be what confused you. Controllers and converters are different things! Related logic but different functions.
Questions?
download.jpg
download.jpg (5.98 KiB) Viewed 2546 times
Thank you!
So, to recap: a *controller* replaces the internal chip all in itself, while a *converter* deciphers the signals from the internal chip?

I've looked at the WYSE-converter thread, and was eventually told I should start my own thread, hence why we're here.

I think I started out the way one should when making a *converter*: Buy a cable that connects to the contact on the board, slice it up and wire it up to the corresponding pins on the Teensy.

Questions:
- So when I'm making a *controller*, I still might need to write my own config-files for the software I'm flashing on the chip, right?

- And if I need to do that, do I need to know what the matrix looks like? Do I need to use a multimeter and all that, or do I just need to find a config-file with the same number of keys as my board and tweak it to fit my language/layout?

User avatar
Muirium
µ

14 Nov 2018, 11:54

Aha! You’re getting it now.

So, to your questions:
So when I'm making a *controller*, I still might need to write my own config-files for the software I'm flashing on the chip, right?
Yes. A controller has to be explicitly aware of all the internal details—where all the switches lie on the matrix. You’ve got to tell it that, either in the source code (TMK) or in a separate config file you send to it after initial flashing (Soarer).
And if I need to do that, do I need to know what the matrix looks like? Do I need to use a multimeter and all that, or do I just need to find a config-file with the same number of keys as my board and tweak it to fit my language/layout?
Ha! Yeah, it would be nice if keyboard matrices were consistent. But they are not! The designers seemed to take great pleasure in doing daft stuff differently every time. You’re on the hook to map it out!

Now, something I didn’t see on your spreadsheet was column names and row names. See, a matrix is only really a matrix when the controller knows where to find them! You’ve got to tell it which pins they’re hooked up to.

Here’s what I mean. This is the Soarer config file for a keyboard I made myself, built around his controller.

Code: Select all

# Muirium's Shiny 60%: Mk.II

matrix
	scanrate 1
	debounce 5
	blocking 0

	sense			PD0			PD1			PD2			PD3			PC6
	strobe	PF0		esc			tab			lctrl		lshift		fn2
	strobe	PF1		1			q			a			z			lalt
	strobe	PF4		2			w			s			x			lgui
	strobe	PF5		3			e			d			c			unassigned
	strobe	PF6		4			r			f			v			unassigned
	strobe	PF7		5			t			g			b			space
	strobe	PB6		6			y			h			n			unassigned
	strobe	PB5		7			u			j			m			unassigned
	strobe	PB4		8			i			k			comma		unassigned
	strobe	PD7		9			o			l			period		rgui
	strobe	PB0		0			p			semicolon	slash		ralt
	strobe	PB1		minus		left_brace	quote		unassigned	unassigned
	strobe	PB2		equal		right_brace	unassigned	rshift		rctrl
	strobe	PB3		backslash	unassigned	enter		unassigned	unassigned
	strobe	PB7		back_quote	backspace	unassigned	fn1			pad_enter
end
See those names? PB0 = Teensy pin B0. PD2 = D2 and so on. The key names come from his documentation.

I saved that as a text file, compiled it with scas and wrote it to the Teensy with scwr. Soarer’s tools, all found in the zip on this thread:

workshop-f7/soarer-s-keyboard-controlle ... t6767.html

Anakey

14 Nov 2018, 11:57

Firstly, you will need to draw out the basic switch layout on paper i find it is easier to write on paper then trying on a spreadsheet. Making a layout on KLE and printing that out works well. So for each switch you would mark the chip pin corresponding to the switch pin so each switch should have both a column and row chip pin and the switches are in order of he keyboard itself.

Decide on a controller to use, i normally find a Teensy++ gives enough pins and pair a chip pin on the keyboard with a pin on the controller this is because you will need to specify the rows and columns; you may have say 12 row pins and 7 column ones for example. Again it helps to then go back to your paper switch layout and change the chip pin numbers to match the row/column numbers in the matrix e.g. in your example if the rows start at 28 and go to 22 on the chip then that would be row 0 to row 6 of the matrix.

So now we should have our matrix mapped out for the number of rows and columns needed. It will not be in nice neat order because this is how the boards were designed to avoid ghosting without using diodes. Solder wire connecting the chip pins with the corresponding Teensey controller pins.

Next we will move on to making the hex file used to flash to the controller.

Make the layout on KLE if you have not done so. Open up kbfirmware.com and then paste in the raw data from the KLE.

go to the WIRING tab the layout should match with the switch drawing, if the matrix was planned with the board in reverse then use the flip button to make sure the layout matches what you have drawn and set the number of pins and columns to match the amount in your matrix, the diagram above will get messy but we can sort that next.

Go through each individual switch and set the row and column pins so they match the paper diagram that you have

Go to the PINS tab and choose the correct controller the ? should help you choose the right one.

Set the row and column pins so they correspond with the pin on the controller e.g. Row 0 B1, Row 2 B2, etc You can also specify pins for the lock lights if you want these to also function just wire up the controller pin to the chip pin from the LED.

The Keymap tab should be correct if the KLE was done correctly, if not then the basic key codes are there and should be able to construct it easily enough. There is the potential to do complex layering etc if needed but it is best to stick to 1 layer for the first try.

Skip to the settings tab, again make sure the correct controller is selected as well as a bootloader size. for vintage keyboards don't need to worry about backlighting and RGB LEDs. This will also give any errors that might appear.

On the compile tab, select download .hex which will make the hex file needed to flash the micro controller.

Download QMK Toolbox, once installed select the correct controller, browse to the downloaded .hex file plug the Teensy into the pc and press the reset button. In the QMK Toolbox click Flash this will flash the .hex file onto the controller. The keyboard should now be working.

I will be covering this process in a livestream next Wednesday using a recent board that i converted using the process there will be the VOD available which might be easier due to the timezone difference.

User avatar
snufflecat

14 Nov 2018, 13:29

Holy crap Anakey :shock:
download.jpg
download.jpg (5.98 KiB) Viewed 2512 times
Here's a praise for you as well!

I came so far that I managed to copy my layout to KLE, print out the layout and cross-check which keys mapped to what pins. I've discovered that I haven't managed to read all two pins on each key, so I'll do that either this evening or tomorrow some time. As far as I can tell there's about 11 keys I'm missing.

But, is this a 5 or 6 row layout? (I'm guessing 6..)
layout.PNG
layout.PNG (32.01 KiB) Viewed 2512 times

Anakey

14 Nov 2018, 13:59

that is 6 rows looking at physical switches, however there may be 7 or more row pins for the matrix. My most recent board had 12 row pins for a 6 row board. you might end up with say F1 to F4 in Row 0 then also V,B,N,M also in Row 0 so that is why it is helpful to keep the physical switch layout fixed and then specify the column/row pins for each switch. Don't forget that the rows/columns start at 0 so if you have 7 rows it will go from 0-6.

User avatar
Hypersphere

14 Nov 2018, 14:19

You might give the Orihalcon-Soarer converter a try:

https://www.ebay.com/itm/6FT-Soarers-WY ... 2249534551

This worked for me on a Wyse 30 and a full-size Wyse PCE board.

Anakey

14 Nov 2018, 14:37

if you do decide to go with the converter, replace that capacitor by the output, it looks in pretty bad shape, though not surprising for being over 30 years old

User avatar
Hypersphere

14 Nov 2018, 17:29

Anakey wrote: if you do decide to go with the converter, replace that capacitor by the output, it looks in pretty bad shape, though not surprising for being over 30 years old
Good point. That capacitor seems to be a hallmark of old Wyse keyboards! My Wyse boards show evidence of leaking from that capacitor. I haven't replaced the capacitors yet and the boards are still working okay, but the replacements are on my long "to do" list.

Post Reply

Return to “Workshop”