DIY USB Switching Unit - Page 1
Forum section: electronics / general

author: essele
author_rank: Frequent Contributor
timestamp: November 16, 2019, 09:19:06 pm
content: I seem to be on a bit of a roll at the moment, just got a prototype working of a PSoC based USB 5 to 1 switching unit, this is using relays salvaged from old ebay HP/Agilent 44471A relay cards.It's very simple, really just the PSoC and a couple of ULN2003's ... initial testing looks good, so I just need to repurpose the USBTMC code from the Yaugi to provide a USBTMC or USBUART interface.I've used the same approach as the HP modules ... so the quad pole relay is paralleled to act as a dual pole, presumably this was to reduce contact resistance, but also to cope with isolation limits with pin proximity.The picture mostly hides the massive schoolboy error of not checking the footprint yet again and having too small holes for the relays, but luckily with a "just the right amount of flux" I managed to get them all soldered on ;-) ... clearly I'm not leaving school anytime soon!I've just ordered an enclosure and front and rear (pcb) panels ... the intention is to have some led's and a couple of tactile switches on the front panel (for manual selection.) I was going to use Pomona binding posts, but that's £120 in posts which seems mad, so I'll just go for Cliff gold plated ones for now.Slowly I'm getting to the point where I hope I can do something remotely metrologisty ... I now have three LTZ1000 references (in various states of completeness), a USB temp/pressure/humidity sensor (v2 coming soon), a USB switching unit, and a selection of USB GPIB interfaces .. all home made ... which goes a small way in offsetting how much I've spent on actual kit in the last year or so!

author: niner_007
author_rank: Frequent Contributor
timestamp: November 17, 2019, 06:46:18 am
content: I have a similar project in my backlog, and I believe too USB is absolutely the way to interface and controlone question, why these obscure PSoC controller, and not a more available and hackable microcontroller like an STM32?

author: essele
author_rank: Frequent Contributor
timestamp: November 17, 2019, 07:33:24 am
content: Quote from: niner_007 on November 17, 2019, 06:46:18 amIt's probably mostly familiarity ... I've been playing with the PSoC range on and off for quite a few years.But, I do find that they generally "just work", most of the heavy lifting for USB for example is done for you ... I hadn't done anything usb before Yaugi, and it was really simple to get working, and relatively easy to start doing more complex stuff.The programmable logic blocks are also a big draw for me, I dabbled a bit with FPGA's, and so having a (very small) equivalent on the chip is really nice ... not needed at all for this, but essential for my Fluke 8840A CPU emulator (for bus recreation) and potentially handy for the Yaugi to speed things up.The dev environment is ok, although only available on Windows which is a bit annoying ... they do seem to be moving to a new platform with the newer range of devices (PSoC 6), which unfortunately don't look like they are going to be hand solderable any time soon.I did buy a dev board for an STM32 device and had a quick dabble ... it felt a lot more complex, and there seemed to be some confusion about which set of API's to use ... but again, that's probably just my lack of familiarity rather than anything.