Here's what worked for me:
First, set up the tap:
sudo ip tuntap add mode tap tap0
sudo ip addr add
10.0.2.2/24 dev tap0
sudo ip link set dev tap0 up
Or if you're on FreeBSD:
sudo ifconfig tun0 inet 10.0.2.4 10.0.2.4 netmask 255.255.255.0
sudo ifconfig tun0 up
(
https://github.com/open-simh/simh/blob/master/0readme_ethernet.txtsays only 10.0.2.4 thru 10.0.2.14 addresses are permitted, not sure if that's true anymore)
Next, set up a NAT in your simh config file:
attach ni nat:tcp=2323:
10.0.2.4:23,tcp=2121:
10.0.2.4:21Within TOPS-20, escalate your privileges with "ena", then edit as follows:
system:hosts.txt original:
NET : 10.0.0.0 : My-Network : GATEWAY : 10.0.0.100 : My-Gateway : : :
IP/GW,TCP/TELNET : HOST : 10.0.0.100 : My-Gateway : : :
IP/GW,TCP/TELNET : HOST : 10.0.0.51 : My-System : KLH-KL : TOPS20 :
TCP/TELNET,TCP/FTP,TCP/SMTP :
...became:
NET : 10.0.2.4 : My-Network :
GATEWAY : 10.0.2.2 : My-Gateway : : : IP/GW,TCP/TELNET :
HOST : 10.0.2.2 : My-Gateway : : : IP/GW,TCP/TELNET :
HOST : 10.0.2.4 : My-System : KLH-KL : TOPS20 :
TCP/TELNET,TCP/FTP,TCP/SMTP :
system:internet.address original:
IPNI#0,10.0.0.20,PACKET-SIZE:1500,LOGICAL-HOST-MASK:255.0.0.0,DEFAULT,PREFERRED
...became:
IPNI#0,10.0.2.4,PACKET-SIZE:1500,LOGICAL-HOST-MASK:255.255.255.0,DEFAULT,PREFERRED
system:internet.gateways original:
PRIME 10.0.0.100, 192.168.1.1
...became:
PRIME 10.0.2.2, 192.168.1.1
domain:resolv.config
added "DSERVE 10.0.2.3" to the end of the default nameservers
...then reboot (ctrl-e CEASE NOW) Then you can telnet to port 2323 of localhost. Be sure to switch telnet to character mode with ctrl-] and "mode character", or it won't echo your input.
I was able to telnet from within TOPS-20 on my RPi running FreeBSD, but for some reason it doesn't work on my Debian PC, even with a raw IP. Never tried the FTP client, don't know how to setup the server.