ps2dev icon indicating copy to clipboard operation
ps2dev copied to clipboard

Possible to output keyboard and mouse at the same time? (ie. y-splitter cable)

Open sofakng opened this issue 3 years ago • 3 comments

Can this library be used to output a PS/2 keyboard and mouse at the same time?

For example, some computers only have one PS/2 port but a y-splitter can be used to combine a PS/2 keyboard and mouse to the same PS/2 cable.

sofakng avatar Jan 11 '22 01:01 sofakng

Are they using two separate data pins or one common pin for both keyboard and mouse data? I totally agree that this is interresting topic, i don't really have time to develop it myself, but i will happily review PRs as long as they do not break existing functionality.

Harvie avatar Jan 11 '22 08:01 Harvie

I didn't do enough research before asking so I apologize, but it looks like the keyboard and mouse use separate pins:

1 = KBD DATA 2 = MOUSE DATA 3 = GND 4 = +5V 5 = KBD CLOCK 6 = MOUSE CLOCK

If I understand correctly, should be able to create two instances of the PS2DEV class and pass in the separate data and clock lines and it should "just work" ?

sofakng avatar Jan 11 '22 14:01 sofakng

If I understand correctly, should be able to create two instances of the PS2DEV class and pass in the separate data and clock lines and it should "just work" ?

Yes. But i've never tried to create two instances. It might work unless there will be some clash, eg. both instances trying to configure same timer. I don't really remember how this works. Perhaps you should try that and report :-)

Harvie avatar Jan 11 '22 14:01 Harvie