zappanaut / pikvm-usb-atx-ctrl

Enable PiKVM to control ATX operations of multiple computers via USB.
MIT License
45 stars 6 forks source link

Hardware has header for UART, but it is disabled and used for debug instead? #2

Open Krotu opened 1 year ago

Krotu commented 1 year ago

Is it possible to switch pins 1/2 back to UART? I want to be able to use them for a HID device if possible.

Krotu commented 1 year ago

To expand on this, a ch9329 can be used with a usb serial cable to provide mouse/keyboard control on pikvm devices that do not have otg. I can use notro/pico-usb-io-board to get the serial port working, but this removes the unique id on the gpio provided by this fork (making it less useful when operated with a switch). If possible the serial interface attached to pins 1/2 could do with being enabled and having the same unique id.

This would simplify the kvm switch wiring since only a video cable and the usb for the atx control would be needed, the atx control boards serial pins could then be attached to a ch9329 which could then be attached to an internal usb2 header.

zappanaut commented 1 year ago

Hi! This sounds like a nice idea. I don't see why the UART on pin 1/2 should not work. The generation of a unique ID is also part of the main branch. The "trick" is to use udev scripts to create the according sym-links. I would expect this to be possible for the UARTs, too. I am on holiday, so I can't check on this atm, but I hope to have a look next week.

Just one drawback: While saving a cable you won't be able to use any pikvm storage device.

Krotu commented 1 year ago

Thanks for the information, I didn't realise the unique ID generation was in the main branch, I guess I just need to disable the second uart (only the first is attached to header on the hardware) and then make a similar udev rule to the gpio for the tty so I end up with a tty-by-serial too.

zappanaut commented 1 year ago

Yes, this should work. Please let me know how it goes. I could not resist and also just ordered a ch9329 board, may take a few weeks though...