8 ms·
The Parallel Port
- PreInternet01 4y agoFor quite a while, the parallel port was the only external high(-ish) speed port on PCs, not only used for printing, but also scanning, networking (with a yellow LapLink cable, or, if you wanted to get really fancy, a Xircom Pocket Ethernet adapter that almost did 10Mbits/s) and even storage (various weird MO contraptions, but also a regular hard disk with almost 1MB/s read performance...). The history in the linked article is quite comprehensive, and touched on the slightly-incompatible (EPP, ECP) standardization efforts for bidirectional use. When USB finally came along, that made things a lot more convenient.
- BirAdam 4y agoEarly USB was terrible on both hardware and software support. It took a long time for most people to stop using parallel. Honestly, the only thing I ever used USB for before the USB2.0 era was computer mice.
- dheera 4y agoI usually ended using the PS/2 adapters because the USB mice wouldn't work when you first plugged them in, but they did if you used the PS/2 adapter, and then I'd just leave them that way.
- dave78 4y agoThis captures the early USB experience pretty well: https://www.youtube.com/watch?v=IW7Rqwwth84 https://www.youtube.com/watch?v=IW7Rqwwth84
- bluedino 4y agoI had a USB 1 IoMega CD-RW that made quite a few coasters. I got a hold of a FireWire card and a Sony CD-RW (i.Link or whatever they called their version) and never looked back.
- ttul 4y agoOut of desperation, I once soldered a bunch of resistors onto a parallel port connector to create a crude DAC converter so I could get my PC to output "high quality" audio. The results were pretty good! I could play MOD files as if I had an actual sound card. Related: https://retro.m1ner.co.uk/2017/08/homebrew-covox-speech-thing/ https://retro.m1ner.co.uk/2017/08/homebrew-covox-speech-thin...
- YZF 4y agoI've done the same... This was a pretty common hack... R/2R ladders FTW.
- Waterluvian 4y agoAs a young kid I remember developing this conclusion that Macs must be better because ours had a SCSI port and the devices were just better and faster than the parallel port devices of our PC.
- ndespres 4y agoMy first MP3 player (the Rio PMP 300) and digital camera (Canon Powershot 600) both used parallel ports for data transfer. Plenty of other weird things used the port, Autocad’s licensing dongles come to mind. It was really used for some versatile functions!
- Damogran6 4y agoConnectix QuickCam in the hizzouse!
- h2odragon 4y agoEarly parallel ports were often used for hacked "GPIO" applications, they gave you more useful lines than a serial port and were often less picky about the voltages. The "Speech Thing" [1] is the most commercial example I can think of, until "laplink" hit. [1] https://en.wikipedia.org/wiki/Covox_Speech_Thing https://en.wikipedia.org/wiki/Covox_Speech_Thing
- BizarreByte 4y agoI used to use the parallel port as basically GPIO. It was easy and cheap, before microcontrollers were as friendly to use as they are now. I built a lot of custom stuff that way for my PC.
- notRobot 4y agoWould that still work with USB → Parallel convertors?
- 0xcde4c3db 4y agoI believe there are some rare adapters that will work with custom drivers, but almost all of them I've seen are programmed specifically to provide a printer device.
- RobotToaster 4y agoMost seem to very specifically be IEEE 1284 adapters, rather than actual hardware parallel ports.
- 0xcde4c3db 4y agoIEEE 1284 is the relevant standard for "modern" (ECP/EPP) parallel ports, but most adapters only provide that interface on the printer side, not a general-purpose host-side interface to control an IEEE 1284 port.
- mikepavone 4y agoECP and EPP are not really useful for GPIO-style use and even the simpler modes are not really desirable if the adapter is implementing the handshaking in hardware. You really just want to be able to manually control all the bits. The original parallel port (and later integrated ones when set to an appropriate mode in the BIOS) allowed this because it was a very simple device and relied on software to handle things like toggling the data strobe line when a byte was written to the data lines.
- 4y ago
- zabzonk 4y agoi once tried to solder my own parallel printer cable. rs232 i could manage, but the parallel cable completely defeated me. i also had a zip drive that plugged into the parallel port, which worked surprisingly well.
- septune 4y agoHave bricked a windows NT server pluging a printer while the machine was ON => kernel panic and NTFS filesystem was corrupted. Beware the parallel port is not hot-pluggable :)
- Zardoz84 4y agoThen something very weird was doing Windows NT. I plug/unplug many times a printer, and a ZIP disk unit, to the parallel port without issues on Windows 95/98/ME. And more recently, a 90's Roland plotter on a 2010's computer that have yet a parallel port, running Debian.
- anthk 4y agoThat happened with PS/2 keyboards and mice too.
- buildsjets 4y agoAT motherboards had a physical, discrete fuse on the keyboard connector that would sometimes blow if you hot-swapped the keyboard. Then soldering iron ahoy. https://forum.vcfed.org/index.php?threads/486-motherboard-keyboard-interface-error.71779/ https://forum.vcfed.org/index.php?threads/486-motherboard-ke...
- anthk 4y agoOh, TIL, thanks. I didn't know that.
- _tom_ 4y agoI hot plugged printers for decodes. No one turned off the computer to unplug or plug-in the printer.
- septune 4y agoYes so did i. The fact is that you can live forever playing Russian roulette if you turn the cylinder every time.
- alar44 4y agoBack in the mid 90s I was teaching myself QBasic and basic electronics. Realizing I could combine the two via the parallel port on our PC was a magical epiphany that I'll never again experience. Being able to "pull" programs into the physical world blew my 14 year old mind.
- somat 4y agoOur modern PC's have a surprising lack of human scale IO. It's all usb, pcie, sata. Nice enough interfaces but very hard to work with from first principles. If you are lucky you will still find an exposed gpio or serial header.
- snvzz 4y agoMost boards have the serial port in a header. It is the same pinout that I/O cards in old PCs in the 1980s used for extra ports. Careful that they are at RS232 levels, not TTL. It is a shame that it isn't directly exposed in the backplate. The control lines can be abused as GPIOs, but I would not recommend doing so. Many USB to TTL UART chips do also expose GPIO functionality, if you want somewhat direct access to GPIOs.
- snvzz 4y agoThe modern equivalent to that experience is through cheap microcontroller development boards. I recommend the RISC-V based ones (e.g. ESP32-C6, CH32V, GD32V, K210). Some SBCs double as development boards, with huge GPIOs capable of a lot besides basic I/O (PWM, I2C, SPI, UART, I2S...) The new, RISC-V based, "VisionFive 2" is a lot of fun.
- Zardoz84 4y agoI remember my father teaching me about some basic digital electronic using the parallel port. How to multiplex and use it as GPIO & primitive expansion bus. Eventually, my father had some board using parallel port for stuff. Including a Dobson telescope control board (based on Mel Barters designs). I had half-write a program to control it from Visual Basic (there was some VB controls that allow to direct control of the parallel port). Sadly, the Dobson mount and the control board was lost when we move to a new house.
- usefulcat 4y ago20ish years ago I was on a team that was working on the PC version of a popular sports game. For the multiplayer mode (2 players only), the way the game worked both instances had to maintain the exact same internal state. For debugging, one of the things we used to do was connect two machines together via the parallel port and let them play each other for hours. It was slow, but still far faster than ethernet because the latency was so much lower.
- FullyFunctional 4y agoAmazingly I was just thinking about the parallel port this morning. My first PC (a Toshiba T1850 notebook) only had a serial port and a parallel port. Wanting faster network performance inspired me to play with PLIP (parallel-port IP). PLIP only works in nibble-mode so I played with the bidirectional support and got it working. However, I didn't measure much improved performance and lost interest. Indeed, later EPP and ECP came around, but at the time I couldn't find any documentation. This article fill of lot of the gap and has some amazing backstories I never knew, very cool.
- TacticalCoder 4y agoMy first two networked Linux computers where my desktop (probably a 486) and a laptop, though the parallel port using PLIP. My desktop was much faster than the laptop so I'd just launch a X11 server on the laptop and then run everything on the desktop. By doing that my brother and I could both use the Internet (Netscape) at the same time, sharing our... 28 800 modem connection : ) Oh the memories.
- FullyFunctional 4y agoIt not too far from how I work today - I have all sorts of devices around the house that I use to ssh and tmux attach to my EPIC server; I’m logically running the same session for months, but the terminal changes several times a day. I don’t think any of the devices in use have a (parallel) printer port though.
- mikepavone 4y ago> Even better, the original IBM PC was capable of a "direction-switching" handshake that allowed the peripheral to use the full 8 bit data bus to return data. This feature was apparently unused and disappeared from subsequent PCs, which is ironic considering later events. I guess this is talking about the XT and AT, but the article kind of makes it sound like this simple bidirectional mode was gone from all PCs after the 5150 when it in fact came back with the PS/2 and remained present on clones long after that. You generally needed to set the right parallel port mode in the BIOS, but I was using this simple bidirectional mode for communicating with a Sega Genesis over its controller port in the mid-2000s.
- jcrawfordor 4y agoSorry, that is a bit unclear. You're right, sort of the oddest thing about IBM's basic bidirectional mode (which is pretty much equivalent to byte mode in 1284) is that support for it went away only briefly. I sort of wonder about the internal events at IBM here, one would think they were probably starting to develop applications for bidirectional mode at the same time they stopped including it, since they brought it back pretty quickly. Something I didn't make clear enough in general is that, as with several other interfaces, the modern "parallel port" is pretty much a clone of the PS/2 specifically.
- mikepavone 4y ago> You're right, sort of the oddest thing about IBM's basic bidirectional mode (which is pretty much equivalent to byte mode in 1284) is that support for it went away only briefly. I sort of wonder about the internal events at IBM here, one would think they were probably starting to develop applications for bidirectional mode at the same time they stopped including it, since they brought it back pretty quickly. You got me curious about this and so I looked into it a bit further. I managed to find IBM's technical documentation[0] for the original printer original printer port card and it looks like it only sort of supports bidirectional use of the data pins. It supports reading the state of the data pins, but it seems this was intended to be used for diagnostic purposes. There's no way to disable the output drivers for these pins like there are on later bidirectional ports. The manual does mention that if something happens to drive the pins the result of reading the port will be that value ORed with whatever was written previously (though I've seen claims elsewhere that it's actually more of an AND), but it also cautions that driving these pins externallly is "in violation of usage ground rules". Apparently some folks did use it this way though and perhaps that's what inspired making it properly supported in the PS/2. It's unclear where this idea that the original PC had this feature, but it went away came from. I looked at the manual for the AT's serial/parallel combo card[1] and the parallel port portion is almost identical. I guess it's possible the hack to use unidirectional didn't work in some 3rd party cards or clones. [0] https://minuszerodegrees.net/oa/OA%20-%20IBM%20Printer%20Adapter.pdf https://minuszerodegrees.net/oa/OA%20-%20IBM%20Printer%20Ada... [1] https://www.minuszerodegrees.net/oa/OA%20-%20IBM%20PC%20AT%20Serial_Parallel%20Adapter.pdf https://www.minuszerodegrees.net/oa/OA%20-%20IBM%20PC%20AT%2...
- joshu 4y agoMany low-end CNC machines still offer DB25 in the expectation that they will talk to a parallel port. I run a machine from Mach3 using a tiny microcontroller (a UC100) to send pulses down a parallel port (though it is controlled by USB).
- VectorLock 4y agoThe parallel port is between the uC and the CNC controller and then you run USB for Mach3 to control the uC?
- joshu 4y agoCorrect. I'm not sure if Mach3 is actually sending pulse data at all. It occurs to me that they could send timestamps plus pulse rates in a more compressed exchange. I believe there are other systems that do work this way.
- intsunny 4y agoI can't be the only person who is amused `.rip` is a global TLD.
- stragies 4y agoAnd not only for dead people! Talk about a descriptive URL ... lol
- NateLawson 4y agoThere's another reason why USB-to-parallel adaptors can't replace a PC with a printer port: the latency for round-trip applications is significantly higher over USB. It takes a few microseconds to read/write a byte from a PC printer port. Over USB, the control message latency leads to this taking tens of milliseconds. USB beats it on throughput, but only when transferring lots of data. Before they disappeared, printer ports on motherboards began getting worse for latency and compatibility. This was likely due to cost reduction since low latency two-way communication was not needed for printing. There was an interface for old Commodore floppy drives that is just remapped pins on the printer port[1]. When PC's circa 2005 stopped working with it, I designed a USB microcontroller board to implement the protocol[2]. It had to do some fancy state machines to get around the round-trip problem, caching a set of commands until the host was ready for the transfer. Then it would send them all back-to-back and start streaming back the bulk data. Fun stuff. [1] https://www.c64-wiki.com/wiki/X1541 https://www.c64-wiki.com/wiki/X1541 [2] http://www.root.org/~nate/c64/xum1541/ http://www.root.org/~nate/c64/xum1541/
- Jenda_ 4y ago> Over USB, the control message latency leads to this taking tens of milliseconds. This sounds an order of magnitude wrong. I have just setup a loopback with a CH340 USB to serial adapter and ran the following code: #!/usr/bin/python3 import serial import time ser = serial.Serial(port="/dev/ttyUSB0", baudrate=1_000_000, timeout=1) iters = 100 x = time.time() for i in range(iters): towrite = b"%i\n"%i ser.write(towrite) line = ser.readline() assert(line == towrite) delta_ms = (time.time() - x)*1000 print("Finished %i iterations in %ims = %.1fms/iteration"%(iters, delta_ms, delta_ms/iters)) and it says Finished 100 iterations in 272ms = 2.7ms/iteration
- pugworthy 4y agoIn the 90's I was on a research ship writing software that towed an instrument (SeaSoar) behind the ship that could be "flown" up and down through the water column. One of the challenges was to make it not go so deep when we came up on the continental shelf. Given the idle nature of a month or two at sea, I started looking at the bathymetric electrostatic chart printer we had, and realized it had some kind of 4 bit output that was basically the raster of each depth print scan. So what I recall is wiring up the 4 pins to the 4 inputs (Busy, Paper-Out, Select, Error) on the DB25 on some PC, and scanning those to read the current bathymetric trace. Then turn that into a visual depth display overlaid on the 640x480 VGA display of the SeaSoar's position. Eventually then, I was able to figure out where the bottom was and have it automatically do a "turn up" when it got within a certain range of the bottom. Bit of a knuckle biter the first time I had to trust it to not smash a quarter million $ instrument into the sea floor. These were fun hacks. You're at sea, no internet, no place for parts, just hacking together stuff and dealing in the moment.
- rcarmo 4y agoThe ending is… uncanny. Excellent read.
- Neil44 4y agoI remember the best multiplayer DOOM experience was got using a little hacky IPX/SPX over parallel driver. When my friend would bring his rig over to my place to play we always spent way longer getting stuff to talk to each other than actually playing. Good times.
- rwmj 4y agoIPX over parallel is true dedication! We at least had network cards so the only difficult part was remembering to put termination in the right places on our 10Base2 ethernet.
- mrlonglong 4y agoOh man, using laplink with the parallel port and serial port was way faster than floppies. Used this method for years to rescue files off computers. You could even bootstrap laplink using dos copy con if there were no working floppies if I recall correctly.