Is there such a thing as a USB to Parallel converter? - Page 1
Forum section: electronics / general

author: Ben321
author_rank: Frequent Contributor
timestamp: April 06, 2019, 12:33:42 am
content: I've seen USB to Printer converters, but that's not the same. They use some special protocol that lets them work ONLY with printers, and nothing else. There's a lot of hobby projects out there intended to let you interface a PC to the external hobby project circuit via parallel port. Problem is, no modern PCs have a parallel port. And many hobbyists already are buying up old legacy PCs for this purpose, drastically reducing the number available you can find on places like eBay. Eventually all existing legacy PCs will be owned by hobbyists, making it impossible for new hobbyists to perform the same experiments.So I'm thinking that a USB to Parallel converter would be a good solution to this. Yet, I can't find ANYTHING on the internet about a company that makes such a converter. Does anybody here know if such a converter exists? If you know of such a device, please let me know. Also if there's a technical reason that such a device can't be made, please let me know.

author: bsudbrink
author_rank: Frequent Contributor
timestamp: April 06, 2019, 12:46:28 am
content: Not sure about the USB variety, but PCIe cards are available. Problem is that they can't use the original PC I/O addresses, so any original compiled software won't work unless you can patch it somehow.

author: ElectronicSupersonic
author_rank: Regular Contributor
timestamp: April 06, 2019, 01:12:46 am
content: Arduino maybe?http://www.robotmaker.eu/ROBOTmaker/thttps://www.tindie.com/products/uptoolate/lptshield-parallel-port-for-arduinos/Or as already mentioned, a PCI adapter card. I have a motherboard (relatively old ~8y) which doesn't have an LPT port in the I/O plate, but does have a dedicated pin header which is 100% functional replacement (used it for SPI IC programming via self-made adapter board). So you can still find some motherboards with LPT, albeit in from of a pin header.

author: NiHaoMike
author_rank: Super Contributor
timestamp: April 06, 2019, 01:19:43 am
content: There are a few USB to parallel converters that work a bit different than most, I once got one to try hacking around with interfacing with it only to find out it doesn't need a special circuit to turn it into a GPIO. (It used a MCS7715 if I remember correctly.)Here's one way to hack the more common kind of USB to parallel adapter:http://web.archive.org/web/20130226141444/http://www.ccs.neu.edu/home/bchafy/parallel/parallel.html(You can use a 555 instead of that convoluted circuit.)

author: RoGeorge
author_rank: Super Contributor
timestamp: April 06, 2019, 01:33:56 am
content: Some laptops have PCM-CIA card slots. There are PCM-CIA LPT cards.For desktop, there are PCI or PCI-e LPT cards.LPT cards have the physical LPT chip inside, so any software and any device will work, including LPT hardware-lock keys, scanners, etc.USB to LPT adapters are a software emulation of a LPT, many programs and many devices might not work with such USB to LPT adapters.

author: amyk
author_rank: Super Contributor
timestamp: April 06, 2019, 03:14:53 am
content: Make your own:https://www-user.tu-chemnitz.de/~heha/basteln/PC/USB2LPT/ul-17.en.htmIf the chip sounds familiar, that's because it is the same one used in the infamous Saleae Logic and its clones.

author: Ben321
author_rank: Frequent Contributor
timestamp: April 06, 2019, 06:44:28 am
content: Thanks guys for your suggestions, but NONE of those are possible for me. Most new laptops have no expansion port like PCMCIA. Also NO laptops have a PCI-e slot (those are large cards for desktop only). One thing I will NOT do is buy a new computer. And guess what, my current main PC is a laptop, (not a desktop, this saves a LOT of space in my room). Its ONLY expansion connectors are USB ports, so ANY devices I attach MUST be USB devices. Hence I'm looking for a lot of USB alternatives to things typically associated with large cards that would fit in a desktop's PCI-e slot.

author: ruffy91
author_rank: Regular Contributor
timestamp: April 06, 2019, 06:59:33 am
content: Many current Laptopa have ExpressCard (which is PCI-e in a much smaller form-factor).The problem with USB is, that you will never be able to emulate something other than a parallel port printer. An example for such an adapter is the PL2305. Maybe if you need less than 1.5Mbps you could use this.There are also Laptops with ExpressCard Slots or Thunderbolt 3. Both are PCI-e and there are lots of adapter or external PCI-e cases which support fully featured Parallel Port cards without problem.

author: Ben321
author_rank: Frequent Contributor
timestamp: April 06, 2019, 07:04:53 am
content: Quote from: ruffy91 on April 06, 2019, 06:59:33 amProblem is these don't let the OS see a "parallel port". The OS only sees a "printer" connected to the computer. So there is no possibility of sending 8bit control signals to turn on and off the 8 data pins on the parallel port to control custom-made external devices. The only commands it sees are when you press ctrl+p on your keyboard to print a document.

author: OwO
author_rank: Super Contributor
timestamp: April 06, 2019, 07:08:11 am
content: A cheap STM32 with USB can be programmed to show up as a CDC ACM device, then you can send custom byte sequences to write or read GPIOs.

author: Ben321
author_rank: Frequent Contributor
timestamp: April 06, 2019, 07:14:05 am
content: Quote from: OwO on April 06, 2019, 07:08:11 amProgrammed? You mean I need to flash its firmware before it can do this? Running Zadig to install the CDC driver won't work? Flashing firmware is one step beyond where I'm at in my hobby. I wouldn't TOUCH firmware on anything. I leave firmware ALWAYS at default, because one mistake can BRICK the device. If there's something off-the-shelf I can use, I'll use that.Since CDC seems to be the official generic standard for USB-to-serial converters. Why are there no off-the-shelf USB-to-serial converters from any legitimate company that use this standard?On another note. Not all laptops have an ExpressCard slot. Not even most new ones. My laptop certainly does NOT have one.So again. I'm back to using ONLY devices that can plug into a USB port.

author: janoc
author_rank: Super Contributor
timestamp: April 06, 2019, 11:13:59 am
content: Quote from: Ben321 on April 06, 2019, 07:04:53 amWell, if you are hoping to bitbang a parallel port under a modern OS, I think you need to go back to the drawing board. That is normally not possible without admin rights (and often not even then) due to the way the OS works these days (virtual memory and all that). It would need a custom driver (in Windows) or root access (in Linux). Either way, it would be pretty much unsuitable for anything requiring tight timing, for example.You are going to be much better off to offload that "pin twiddling" to a microcontroller that you control over USB.However, I feel this is an XY problem here - explain what you are trying to achieve and why you need this kind of functionality and then people will be able to give you more meaningful answers.

author: janoc
author_rank: Super Contributor
timestamp: April 06, 2019, 11:19:13 am
content: Quote from: Ben321 on April 06, 2019, 07:14:05 amZadig only tells Windows to use a certain driver with a certain device. However, you need to actually tellthe devicewhat it should act like too! That's what the firmware does. STM32 is a microntroller - a completely generic chip that does literally nothing and only generates heat unless it has been programmed at least once. That's what OwO was referring to.If you want off the shelf USB-to-Serial converter that can be also bitbanged, get the FTDI's FT232H (or FT2232H if you want 2 channels). Just make sure you get the genuine one (i.e.do notbuy it from eBay or China!).Those devices aren't exactly fast if you are trying to control individual pins with them, though (that's not their fault but due to how the USB protocol works - the overhead for flipping a bit is huge).

author: Psi
author_rank: Super Contributor
timestamp: April 06, 2019, 11:24:44 am
content: The best advice i can give you is to stop using the parallel port for things.The port is dead.Even if you could get a 100% complete parallel port on your PC/laptop you would run into other problems.Such as it being hard to communicate with the port from windows apps.The parallel port requires applications have direct hardware access to talk to it. It bypasses the OS entirelyLots of effort has been done since windows XP to prevent apps having direct hardware access because its a big security risk.So trying to implement a parallel port system in say, windows 10, requires hacking to disable various security or running apps as administrator.Its better to reexamine the reason you want a parallel port and find another solution to the problem.You can get USB to GPIO boxes from many companies that include example code to read/write the IO from all the programming languages you might want to use.If you can tell us how you want to interface with outputs/inputs on your computer maybe we can come up with some example products that have easy to use code examples.

author: Ampera
author_rank: Super Contributor
timestamp: April 06, 2019, 01:02:53 pm
content: Easy on the capitals there, seriously. You're PUNCTUATING every other WORD and it makes it ANNOYING to READ. People are just trying to help, and you ain't being too nice about it.Doing a quick search for USB to Centronics, I can find that there are some solutions on the market. These don't say they are specifically for printers, and are likely the same sort of bit banging people are talking about here, just built into a cable. Do I know this for sure? No. Read up a bit from people who have bought them, and see if they've tried to use them for anything besides printers. If it shows up as a regular parallel port, and is capable of all the regular communications, any protected/long mode driver or program should be able to make use of it, as modern operating systems have things called hardware abstraction layers, although older Windows programs may or may not be doing stupid shit, who knows.Also, just because that annoys me slightly, no people aren't buying up old computers for the parallel interfaces, they /definitely/ sell PCI and PCIe solutions for Centronics that are fully compatible with modern operating systems. The reason is that old PC collecting is getting quite popular now, myself an especial buyer. Computers have had Centronics ports on them up until the early 2000's, and they have had motherboard headers up until quite recently. I wouldn't even be surprised if you could find a brand new board with one on it, I know my Z97 board has one. If the worry is getting an old shitbox just for the Centronics interface, find the nearest black box Dell machine from the early 2000's, they are barely even worth anything to collectors at the moment, I'll even give you mine if you happen to live near Albany, NY, maybe you can stick FreeBSD on it.

author: joeqsmith
author_rank: Super Contributor
timestamp: April 06, 2019, 01:21:31 pm
content: Quote from: bsudbrink on April 06, 2019, 12:46:28 amAgree that if OP wants to used software that's an executable and no source, this will be the challenge. Even with the source, as mentioned, it would still be some work getting things working with a modern PC.If the PCIe had been an option, I did find a card that actually will work as a printer port with DOS. As you mentioned, I did have to change the EXE file to point to a new location.

author: coromonadalix
author_rank: Super Contributor
timestamp: April 06, 2019, 03:29:29 pm
content: Quote from: amyk on April 06, 2019, 03:14:53 amhad this interface, worked well under many applications, but sometimes crashed and had drivers problems upon making changes, had to reboot the pc to regain stabilitySadly the only things who works reliably for me are the true parallel port on any pc / laptop, not with pci or pci-e cards, event tried an "pci to isa interface" found in some Compaq desktops with an 8 bit isa lpt card lollMy friend for his radio amateur stuff need lpt interfaces, he must find legacy pc's to make them work, the companies wont / will never upgrade their stuff into serial or usb connectivity.I know you have cypress ic's and ftdi to parallel interfaces, never played with them.

author: Buriedcode
author_rank: Super Contributor
timestamp: April 06, 2019, 05:33:43 pm
content: Quote from: amyk on April 06, 2019, 03:14:53 amI got one of these, many years ago (2009?) and it worked for most JTAG dongles used with FPGAs, namely Xilinx and Lattice download cables. It was about half the speed as a native LPT but that isn't really a problem. I just dug it out and tried it on windows 10. I can wiggle the lines used the app built into the driver, but have yet to get any software using it (that is probably because said software doesn't' work on windows 10). It was very handy for CPLD/FPGA development, back when native USB download cables were expensive.The guy on that site mentions you can just buy a cheap FX2 dev board and use his driver, as that is really all the device is, an FX2 + EEPROM.

author: nctnico
author_rank: Super Contributor
timestamp: April 06, 2019, 05:41:27 pm
content: Bit banging won't happen with a USB to parallel port adapter. However the problem of needing specific hardware access isn't new. A couple of decades ago I designed an EPROM emulator which behaved just like a printer. That way I could print commands and hex files to it from the command line. Using an efficient hex file interpreter I could get transfer speeds of 300kB/s so even large files got downloaded very quick (way quicker than you'd ever could get over a serial port).

author: joeqsmith
author_rank: Super Contributor
timestamp: April 06, 2019, 05:58:07 pm
content: Quote from: nctnico on April 06, 2019, 05:41:27 pmI was wondering about something similar. I still use an Ethernet to Centronics/RS232 print server. These are bi-directional. If OP just wanted to output data, it's as easy as printing a character.Many years ago I made a sort of reverse print server. Rather than having a printer port on the Ethernet, it would collect data from the printer port and send it over Ethernet to a printer. In this case, I used an MC6811 (dates it) with some DRAM and small FPGA to handle the memory control. I wrote the stack in assembler for it.IMO, they would be far better off with one of the low cost data acquisition systems than trying to find a work around for the old Centronics port.

author: jesuscf
author_rank: Frequent Contributor
timestamp: April 06, 2019, 06:25:02 pm
content: Quote from: janoc on April 06, 2019, 11:19:13 amIf you use asynchronous bit bang with FTDI devices they are not very fast, you are right. If you use synchronous bit bang you can achieve very fast pins I/O. I have used both the FT232RL and FT230XS extensively to connect stuff as I used to do when the parallel port was around. I am convinced that nowadays it is easier to program/use an FTDI USB to serial adapter like FT230XS than the parallel port.

author: GlennSprigg
author_rank: Super Contributor
timestamp: April 10, 2019, 11:54:53 am
content: Quote from: Psi on April 06, 2019, 11:24:44 amI whole heartedly agree. The OP's postulation sounds a bit like how my 'brain' works...I have an idea, utilizing what I originally think might be the solution, and get 'locked-in' to that 'path'.The OP has only 'hinted' at the task that he wants to perform, by mentioning control of some I/O devices?Lets assume he wants to control/read 8, 16, etc external real-world devices. These days, it is SO easy tobuild a relatively simple USB interface, for just such projects, off the shelf or in a kit, for very little cost.And the 'programming' as such, can be integrated so easily now, using even 'Visual Basic' to control it all !I mention this, as the OP 'hints?' that he is not an Electronics Engineer or high level Programmer ?