Thanks to startmenu for posting that diff, it made it easier to see what goes where...
I didn't touch the resource files, but I do have a preliminary slirp version working.
I can't get this bit to work for the life of me..
Code: Select all
int delay=60*TIMER_USEC;
timer_add(slirp_tic,&delay,TIMER_ALWAYS_ENABLED,NULL);
I would think this would fire the procedure slirp_tic every 60 ms? Anyways even an empty procedure hangs the system. So clearly I'm wrong. Instead I'm resorting to some horrible hack that sits inside the ne2000_poller procedure, something like this:
Code: Select all
fizz++;
if(fizz>60*TIMER_USEC){fizz=0;slirp_tic();}
Since it looks like it fired once every millisecond. Or an incredible amount of times when I logged it!
So it's enough that I can telnet to my OS/2 BBS, and poke around, although the telnet client really leaves a lot to be desired. I need to inject one of those TCP Fossil drivers so I can use a 'real' terminal program.
Obviously the benefit is that this doesn't require any drivers, or other insanity, 'it just works', all in user mode. Things like ftp won't work so don't excited. No you can't ping
http://www.google, and if you do a manual IP config it *MUST* be:
ip 10.0.2.15
mask 255.255.255.0
gateway 10.0.2.2
DNS 10.0.2.3
If you love to ping, ping 10.0.2.2 which just confirms that SLiRP is alive. It's under a BSD license, since SLiRP is part of the old FreeBSD TCP/IP stack.
Give me a few minutes, and I'll have binaries, and diffs....
Also as a suggestion changing the link libs/flags from:
Code: Select all
LIBS = -mwindows -lwinmm -lalut -lopenal32 -lddraw -ldinput -ldxguid -ld3d9 -lstdc++
to
Code: Select all
LIBS = -mwindows -lwinmm -lalut -lopenal32 -lddraw -ldinput -ldxguid -ld3d9 -lwsock32 -liphlpapi -lstdc++ -static-libstdc++ -static-libgcc -static
Gives an executable that only needs alut.dll, which makes redistribution much easier...
Ok,
binary is here, sorry you have to deal with passwords, it's in the 404 (it changed from time to time).
http://vpsland.superglobalmegacorp.com/ ... 0ece930.7z
And
the diff:
http://vpsland.superglobalmegacorp.com/ ... 0ece930.7z
This is for the latest rev, which I think is 318.
Oh and configure your NE2000 for 0x300 IRQ 10 (so I guess no 8bit ISA machines...)
and in the pcem.cfg you need to add the lines:
Yeah I know. ugh. Setting these to zero disables the card. I have other stuff to do, but playing around with the rc scripts should make it easy enough to change the port/irq, and enable/disable.