Page 1 of 1

USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 4:30 am
by Vinicius
I'd like to make a case for my MiSTer with original controller ports stuck on the front
and am wondering if I could hook the USB cables via a hub to the SNAC port.
Since it doesn't follow the USB protocol I'm guessing it won't work? Is there an alternative to avoid plugging and unplugging?
To be clear I just want to use one controller at a time.

If there was a way to keep the SNAC adapters plugged in and switch without unplugging it would be cool.
USB adapters like Raphnet's barely have 2? ms lag so they would be a solution. But might as well try to go for the SNAC connection since it's actually cheaper too.

PS: got my DE10-nano 1 month ago and I've been loving the little guy.
Thanks to the devs but also everybody on the forums, they helped me understand the MiSTer and the setup I want.

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 10:36 am
by N.Master
Hi,
If I am not mistaken, the SNAC uses a USB style connector but is not USB bus, it's a serial port directly controled by the FPGA.
So no USB peripherals can be plugged in this port.
Your USB peripherals must be plugged in the usb OTG port on the DE10-nano

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 11:00 am
by grizzly
I´m guessing that a manual and mechanical usb switch could work.
As in it has a real physical switch and NOT a simple push button and then the electronics do the switching.
For example something like this would probably work.
https://www.amazon.com/dp/B01I0Y3GEE
Or this if usb3 ports are needed?
https://www.amazon.com/dp/B077LKGZGZ

But something like this would NOT work at all!
https://www.amazon.com/dp/B07ZK36RBJ

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 12:13 pm
by RetroP
Yes, it would require a USB3.0 switch. A hub or anything USB2.0 wouldn't work at all.

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 12:41 pm
by dshadoff
Electrically or pinout-wise, SNAC has nothing in common with USB; it is only the connector. I do not recomment using USB peripherals on the SNAC port under any circumstances.

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 3:59 pm
by Vinicius
grizzly wrote: Fri Nov 05, 2021 11:00 am I´m guessing that a manual and mechanical usb switch could work.
For example something like this would probably work.
https://www.amazon.com/dp/B01I0Y3GEE
Thank you, a mechanical USB switch sounds like a great idea. The problem is... all switches (like this one on Amazon) are for switching the host, right? The reverse of what I want to do. That and what dshadoff is pointing out.
dshadoff wrote: Fri Nov 05, 2021 12:41 pm Electrically or pinout-wise, SNAC has nothing in common with USB; it is only the connector. I do not recomment using USB peripherals on the SNAC port under any circumstances.
Wow, even the pinout inside the cable is different? So you can't even use an USB extender cable with the SNAC adapters then?

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 6:39 pm
by dshadoff
Not just a pinout difference. Electrically, they are different signalling systems - different frequencies, different impedances, different meanings. The only thing they have in common is the connector, and that was chosen just so that a reasonably cheap and obtainable, PCB-mount, 9-pin connector could be used.

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 7:49 pm
by RetroP
A switch would only be switching physical connections. They have nothing to do with the USB standard other than using the connections.
USB 3.0 extender cables are also fine for use on SNAC.

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 8:04 pm
by RetroP
To be clear, I doubt you would find a switch with multiple inputs to a single output. If you needed this you would just use a hub.
You may well be able to rewire a usb 3.0 switch to work but I haven't done a teardown of one so I dont know what lines they switch.

Anyhow, it's probably easier to just make one up yourself.

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 8:07 pm
by dshadoff
RetroP wrote: Fri Nov 05, 2021 7:49 pm A switch would only be switching physical connections. They have nothing to do with the USB standard other than using the connections.
USB 3.0 extender cables are also fine for use on SNAC.
Not necessarily so. It may make assumptions about the signals on the pins, including power, and may attempt to "condition" the signal actively.
Unless you built it yourself (or at least reverse-engineer it), you cannot say exactly how it treats the signals.

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 8:08 pm
by RetroP
dshadoff wrote: Fri Nov 05, 2021 8:07 pm Not necessarily so. It may make assumptions about the signals on the pins, including power, and may attempt to "condition" the signal actively.
Unless you built it yourself (or at least reverse-engineer it), you cannot say exactly how it treats the signals.
They are passive, they dont process anything, they just switch.

Re: USB hub on the SNAC port?

Posted: Fri Nov 05, 2021 8:40 pm
by dshadoff
Even if they are, USB2.0 is only 4 wires. SNAC need more than that.

Re: USB hub on the SNAC port?

Posted: Sun Nov 07, 2021 3:29 am
by Vinicius
Thank you very much guys.

Now I'm starting to see why antoniovillena.es would make a different user port (DB9 vs USB3 connector).
I'll drop the hub idea and if anything, will see how to bring the SNAC connector to the front of a mini-itx case.

If as RetroP says USB 3.0 extender cables work on the SNAC, that would be pretty handy bc the same case front USB3 could be manually reconnected inside the case to either the SNAC user port or the USB hub (cumbersome, but the possibility is there).

Dshadoff, are you sure USB3 cables can't be used? What you say makes sense, but I do see some info that points to the fact they're OK:
---SNAC Github:
"The SNAC connects to the User port(formerly Serial I/O port) of the IO board on Mister. I recommend a male to female usb3 extension cable between them."
https://github.com/blue212/SNAC
---The Mister FPGA store includes what *looks* like a short USB3 extension cable with their SNAC Adapter For MiSTer USB:
https://misterfpga.co.uk/product/mister ... apter-usb/

Re: USB hub on the SNAC port?

Posted: Sun Nov 07, 2021 5:01 pm
by dshadoff
Usb3 extension cable might work, but there will be a voltage drop depending on the cable. Some systems like Genesis may behave oddly, but NES/SNES should stillbe OK.

Also, my understanding of AntonioVillena’s DB9 is that DB-9 style controllers like Megadrive can be used… but this means that there is a protocol converter in place which prevents anything other than a standard controller from working (mouse, light gun, fishing controller…). Those odd controllers are the actual purpose of the SNAC port.

Re: USB hub on the SNAC port?

Posted: Mon Nov 08, 2021 1:40 am
by Vinicius
Wow, you're a well of knowledge, I appreciate it.
I'll make sure to ask Antonio about zappers before buying his IO board. Indeed for me that would be the biggest selling point for SNAC.

A USB3 cable seems problematic indeed, I see it can drop voltage which is also bad in the case of the PCE/TG16:
viewtopic.php?t=2386 (you responded in this thread too :)
I'll keep considering my options while I use 2-3ms lag USB cables, still quite nice.

Thanks again, all these intricacies are the reason I got my Nano10-DE instead of a complete system. MiSTer is very easy to pick up, hard to master.