I built a lot of custom stuff that way for my PC.
I built a lot of custom stuff that way for my PC.
A buddy of mine got an Apple Mac. It was lovely, except... no GPIO. But it had a serial port. Creating simple devices that could talk to the Mac serial port was my first introduction to microcontrollers. Of course, programming those microcontrollers required a device programmer, which I built and connected to... you guessed it... the parallel printer port of my PC.
I got started with AVR microcontrollers with a DIY parallel port ISP adapter: just cut a printer cable in half, solder in 4 resistors and you were good to go :-)
Then spend a ridiculous amount of time re-learning assembly to port the parallel port LED blinking program from DOS to the AVR.
Only needing the few scavenged parts and buying just the MCU was a lot cheaper than buying the "recommended" adapter cable or some eval board, making the whole thing affordable for my 13 year old self.
If you must, as it's possible at the same prices to instead get much more powerful microcontrollers with RISC-V or ARM processors, like the ESP32 or STM32 lines.
Early PCs were actually really similar to modern Arduino boards. UART for Serial Port, GPIO is basically parallel ports, ADC vs Gamepad port, etc. etc.
20MHz Arduino Uno compares favorably to 16MHz 80386, its really just RAM that's feeble (2kB SRAM on Arduino Uno, which is much less than computers in the 80s), but its not too hard to expand RAM out a bit (or buy a comparable uC today that has 1MB or so of RAM)
-----------
Even then, today's I2C ports (Arduino / Rasp. Pi) are way easier than old ISA stuff, but you run into very similar issues. I2C address collisions can cause a lot of pain, and ISA boards had DIP switches to move those peripherals to other ports.
I2C is much more streamlined compared to ISA. Especially because we don't care about speed anymore (if you "need speed", USB and other protocols exist. All the protocols for modern uCs are for convenience: SPI, UART, I2C, etc. etc.)
That being said: Rasp. Pi, Beaglebone Black, Le Potato, and many other SBCs are proper computers with proper OS support.
---------
Back in the 80s, the Microcontroller vs Microcomputer concept wasn't really solidified yet. Yes, the 8051 and Z80 existed, but they were still external memory bus and kinda microprocessor-ish.
Then again, I'm the type who considers an analog comparator to be a 1-bit ADC so...
It's 8bit, any operations with wider numbers require several instructions.
80386 was mostly 4-clocks per instruction. A 20MHz 80386 only scored 5MHz MIPS. Most 1980s/90s computers were multiple-clock-ticks per instruction (8051 was 12-cycles per instruction, so a 12MHz 8051 is only 1 MIPS).
I don't think Intel got to single-cycle instructions until 80486?? Hard to remember all the differences...
Furthermore, the ATMega328p has many 16-bit instructions, like add, which operate over two registers in one clock tick.
* An ad hoc standard descended from Centronics printers for transferring data on a 7 bit parallel TTL bus.
* The IBM PC Parallel Port Interface, an extremely simple (like four chips!) 8086 ioport based controller for the various lines in the port that was used for decades as a general GPIO interface for whatever gadgets you wanted to hack together.
To the enduring shame of everyone involved in the disaster, the USB standardization process for "parallel port" treated only the first definition. It only does data transfer at the line level, there's no individual control over the wires as there is for the PC interface.
It's basically useless, unless your problem really is to connect a printer to your USB host. That said, there are proper USB GPIO controllers out there. But DOS software written to the old standard (and there was a lot of it!) is unrunnable junk now.
In the pre-PC home computer world, there were products like that, and even in the early x86 ISA PC world, there were analog/digital I/O cards that didn't break the bank.
I use FTDI 232h based devices to drive 433Mhz transmitters, using gpio/bitbang functionality. There are multiple pins that can be used for that so theoretical parallel port like functionality can be achieved.
Now that I'm not broke anymore, still pi is out of stock everywhere