Author Topic: TMK PS/2 to USB keyboard converter  (Read 185844 times)

0 Members and 1 Guest are viewing this topic.

Offline hasu

  • Thread Starter
  • Posts: 3472
  • Location: Tokyo, Japan
  • @tmk
    • tmk keyboard firmware project
Re: TMK PS/2 to USB keyboard converter
« Reply #250 on: Mon, 13 April 2020, 17:41:45 »

I guess power voltage causes if the issue happens on specific keyboards.
You did solder bridge on J1?

Lol. J1 was not solder bridged, but I just bridged it myself and the keyboard now works perfectly. That was clearly the problem. Welp, at least there was a really easy solution this time!!

Good to hear that.


Quote
EDIT:
PancakeMSTR, Could you try this new converter on your Zenith, Omnikey and RT101+ and report the result on its thread? It would be helpful to improve the converter firmware code. The converter supports AT,XT and Terminal with one firmware like soarer's
https://geekhack.org/index.php?topic=103648.0

I'd be delighted. I'll report back with results when I get a chance to test it.


Thanks as usual Hasu!

Great, Iooking forward!

Offline PancakeMSTR

  • Posts: 491
Re: TMK PS/2 to USB keyboard converter
« Reply #251 on: Tue, 14 April 2020, 10:07:57 »
Hi Hasu,

So, strangely, I tried that same trick - solder jumping J1 - with my RT101+ that is behaving identically to how the Omnikey was, but it didn't work :(

Still the same behavior with the RT101+ (have to reset the pro micro to get the keyboard to connect properly). So I dunno, that's a weird one. Gonna have to look into other options for it.

And I tested your IBM PC converter on the Omnikey. I replied in the corresponding thread, but, long story short, it seems to be working pretty well but for some minor weirdness.

I'll reply there with follow up tests on the RT101+ and Zenith. Probably some other stuff too, if it works well (which it looks like it will) I'll likely use it as my de-facto standard going forward. I have quite a few more keyboards still to convert (though, to be fair, they are mostly ADB).

Anyway, great work Hasu! I remain wildly impressed by your commitment to this community!
« Last Edit: Tue, 14 April 2020, 10:11:38 by PancakeMSTR »
   

Offline hasu

  • Thread Starter
  • Posts: 3472
  • Location: Tokyo, Japan
  • @tmk
    • tmk keyboard firmware project
Re: TMK PS/2 to USB keyboard converter
« Reply #252 on: Tue, 14 April 2020, 19:20:12 »
Hi Hasu,

So, strangely, I tried that same trick - solder jumping J1 - with my RT101+ that is behaving identically to how the Omnikey was, but it didn't work :(

Still the same behavior with the RT101+ (have to reset the pro micro to get the keyboard to connect properly). So I dunno, that's a weird one. Gonna have to look into other options for it.

You are using two Pro Micros? Did you got the Pro Micros from same source?
Post pics of them and wirings, that would be useful.

Can you use same Pro Micro with both Omnikey and RT101+? I mean one which works well with Ominikey in particular.

Also check output from hid_listen to confirm that you are using same firmware on the two Pro Micros. You will see version string like below.
Quote
Waiting for new device:....
Listening:


TMK:23305ad9/LUFA






Quote
And I tested your IBM PC converter on the Omnikey. I replied in the corresponding thread, but, long story short, it seems to be working pretty well but for some minor weirdness.

I did check your post. Thanks.
I don't find any reason why problem happens only with F11 and RALT. These keys have normal scan code and nothing special.

Are you sure that this PS/2 converter doesn't has the minor weirdness?
Also what if with Soarer's converter?

I believe you already did but I must ask. Did you try cleaning the switches?






Offline Maniac

  • Posts: 28
Re: TMK PS/2 to USB keyboard converter
« Reply #253 on: Wed, 02 September 2020, 15:35:21 »
Sorry to resurrect an old topic, but I could use some answers.

How would one use this converter with the Cherry G80-11800 keyboard? It has a single cable that splits into two PS/2 connectors, one for keyboard and the other for the trackball. Any way to get both working with this converter?

Thanks

Offline textmode

  • Posts: 15
Re: TMK PS/2 to USB keyboard converter
« Reply #254 on: Fri, 11 December 2020, 22:38:04 »
Quote from: Maniac
How would one use this converter with the Cherry G80-11800 keyboard? It has a single cable that splits into two PS/2 connectors, one for keyboard and the other for the trackball. Any way to get both working with this converter?
If normal keyboard and mouse function are sufficient, you may get good enough results with a normal active ps/2 to usb converter cable. They usually come with two ps/2 inputs and one usb output and are pretty easy to use and relatively cheap. If you're not using an US keyboard, make sure that the converter supports the extra key.

If you want to use this converter here, you can probably plug the keyboard plug into it and plug the mouse into the aforementionned cheap converter cable.

I'm reading this thread (even though it's discontinued) because I'm intrested in experience regarding how well V-USB worked for keyboards here? The code says that it's discontinued? Where there any problems with it? I'd eventually like to have two USB outputs and am wondering if a cheap Atmel AVR can do the job (normal keyboard and normal mouse data only).

Offline hasu

  • Thread Starter
  • Posts: 3472
  • Location: Tokyo, Japan
  • @tmk
    • tmk keyboard firmware project
Re: TMK PS/2 to USB keyboard converter
« Reply #255 on: Fri, 11 December 2020, 23:33:15 »
As long as I remember V-USB works well when PS/2 singnal is handled by hardware USART of AVR.
V-USB can block 50us at max and this prevents from handling PS/2 signal with ISR of pin interrupt(on falling edge). This is reason why hardware USART is needed for V-USB.

You can build firmware for V-USB with  'make -f Makefile.vusb' and I think it still works.
TMK firmware is rather big in terms of flash size, it requires 16KB at least by default configuration.  I tested it on ATMega168 and ATmega328 years ago. You will have to disable many features and rewrite some code to use it on ATtiny with small flash.

Offline textmode

  • Posts: 15
Re: TMK PS/2 to USB keyboard converter
« Reply #256 on: Sat, 12 December 2020, 15:58:10 »
Quote from: hasu
As long as I remember V-USB works well when PS/2 singnal is handled by hardware USART of AVR.
V-USB can block 50us at max and this prevents from handling PS/2 signal with ISR of pin interrupt(on falling edge). This is reason why hardware USART is needed for V-USB.
Thank you! That is very helpful. Most projects regarding V-USB just implement a small, partial keyboard or a mouse and don't provide enough information about its limitations.

My intention is to build a keyboard with trackpoint, additional PS/2 mouse and a KM switch that allows to connect all this to two diffrent computers without having to reconnect after each switch. As I (or rather QMK or TMK) will have to do some processing anyway (reading keyboard matrix, perhaps applying some minor modifications to keyboard actions, reading two PS/2 lines and merging them into one mouse), the input for the microcontroller(s) that control(s) the USB port doesn't have to be PS/2 - won't fit directly into the protocol either as it'll have to include keyboard actions (press/release key; LED control is probably less important) and mouse movement packages.

The job of the microcontroller with V-USB would be to simulate a (mostly) idle keyboard and mouse for the computer it's connected to and to process and forward keypresses and mouse movement that are passed on to it from another microcontroller (perhaps a teensy?).

Hope I won't run out of ports there...hardware ports seem to be quite limited in their amount, even in larger AVRs. Scanning keyboard matrix, reading two ps/2 ports, serving hardware USB and passing on information to the USART of the V-USB controlled other microcontroller - not *that* stressful for a microcontroller, but if it runs out of timers or other ressources...

I've also taken a look at the ATmega32u4 found on some Arduino boards. At first that looked very promising - AVR that can do hardware USB *and* is sold soldered on a tiny board with accessible pins (SMD soldering is far beyound my skill level) - but it seems it can handle only 6 USB endpoints (3 pairs of in/out). Two endpoints are taken up for general USB control; two more are used by the Arduino hard/software for programming the chip and talking to it - so there isn't enough left for controlling a keyboard and a mouse at the same time if I understand that right.

Quote from: hasu
You can build firmware for V-USB with  'make -f Makefile.vusb' and I think it still works.
TMK firmware is rather big in terms of flash size, it requires 16KB at least by default configuration.  I tested it on ATMega168 and ATmega328 years ago. You will have to disable many features and rewrite some code to use it on ATtiny with small flash.
Yes, those ATtiny seem to be pretty small, but I don't have to go that small. Most important is that it can be soldered and programmed without too much hassle. TMK seems to be written in C without using the Arduino libraries - that ought to help a lot already. And it looks very intresting. I think I'll have to dig deeper into TMK.