EDIT: Changed primary example from Zork Dungeon to the default OS shell.
I have a console application running on a modern machine. I also have an Apple //e with a Super Serial Card, which allows it to function as a dumb terminal via a serial COM connection (details are useless beyond that). I can connect these two devices just fine using a USB Serial port.
When the modern machine has Linux booted, by configuring COM settings and giving myself rights to the group the device file belongs to, I can run
$ bash </dev/ttyUSB1 >/dev/ttyUSB1 2>/dev/ttyUSB1
and get a bash session on the Apple - the Linux machine acts as server and runs the program, but input and output go to the Apple, which is a simple client. This also works with more dedicated programs, such as dungeon
(Zork).
How do I do the same thing in Windows? Obviously, I cannot replicate the above solution exactly since Windows only lets me have a COM
port open in one place at a time - running the Windows analogue of the above command,
C:\> cmd <COM4 >COM4 2>COM4
gives me an Access Denied error.
I can send data to the COM port:
C:\> echo "Hello" >COM4
and read raw input (including control and escape characters!) from the COM port:
C:\> type <COM4
but I cannot do both at the same time, in the same or separate processes.
I tried using PuTTY and RealTerm, but both of those only let me operate the Apple from the Windows machine, which proves the connection works but is exactly the opposite direction of what I want. How do I host a Windows console application for access from a connected terminal?