Monday, June 9, 2014

Friday, May 9, 2014

dosemu networking issues.

I have decided to stick with WWIV 4.30 under dosemu for now, as there are a number of annoying bugs under WWIV5 compiled for Linux, and I know C much better than I know C++, so I can do a number of mods in the 4.30 code that I can't in the 5.0 code ;) So I thought I'd set up networking under dosemu, and I noticed something quite peculiar. I decided the easiest method to get things working would be to use bridging on my ethernet card. Keep in mind that I connect to this computer via wlan0. Here is the settings in my dosemu.conf:

$_pktdriver=(on)
$_vnet = "tap
$_netdev = "tap0"


And here is my bridge.sh:

brctl addbr br0
ifconfig eth0 0.0.0.0 promisc up
brctl addif br0 eth0
ifconfig br0 192.168.1.13 netmask 255.255.255.0 up
tunctl -u 1000
ifconfig tap0 0.0.0.0 promisc up
brctl addif br0 tap0


And I go into dosemu and set up a basic tcp.cfg for use with mTCP, and I can ping out to Google by both name and IP. Great! So, I exit the emulator and go back into Linux and try to download the Microsoft TCP/IP networking stuff for DOS. No go. I try to ping Google by name. Nope. By IP? Nope. OK. Reboot, since I don't have the bridge coming up on boot. I double check everything, all look good, and I run my script again, but don't go into dosemu. Can't ping Google. I can ping my default gateway, though. Hmmm... Reboot again and lets try this a command at a time:

brctl addbr br0

I can still ping Google.

ifconfig eth0 0.0.0.0 promisc up

I can no longer ping Google.

ifconfig eth0 down
ifconfig eth0 0.0.0.0 up


I can ping Google again.

So, it appears that putting eth0 into promiscuous mode is causing me to not be able to ping Google via wlan0. But if I run the script and boot into dosemu, I can reach the Internet just fine. So instead of connecting via wlan0, I connect via eth0 and the exact same thing happens. Very strange that I can't get out to the Internet from the my host OS, but can from the guest OS. Maybe if I connect via eth0 and disable wlan0 completely... Doesn't make sense to me that having one nic in promiscuous mode should impact the other at all, unless my router is getting confused...

Wednesday, May 7, 2014

More on WWIV under Linux

Every time I turn around, one bug or another is biting me in my Linux WWIV setup, so I think I've decided to use my knowledge of how to get DOS doors running to run the DOS version of WWIV from back in the day, so it'll be at least fairly stable while I work out some bugs. Since the Linux version is file-compatible, I'll be able to move back to it pretty seamlessly at some point. Since I decided to run the DOS version, I thought I'd check to see availability of the source of the old versions, since it was commercial software. I went to bbs.wwiv.com via telnet (that's the official WSS BBS) and, since I registered back in the day, Trader Jack gave me access to those file areas, so it will be a modded board fairly quickly ;) I'm attempting to do virtual networking between dosemu and Linux as well, but keep managing to drop my network interface while I'm connected from remote ;) I'll sort that out later, though, since it's a minor convenience thing ;)

Friday, April 25, 2014

Doors under WWiV

As promised, here is how to set up doors under WWIV for Linux. It took a lot of trial and error, and pouring over documents and howtos for other BBS packages, but I finally found the solution at Daydream BBS software support. I was going to provide an actual walk-through, but then I realized that I didn't deviate from those instructions. So, follow the directions there to a tee, and you'll have no issues at all. My external maintenance script is run via cron and uses pretty much the exact same setup, except I do not pass -u virtual to dosemu, as it will fail because that script does not run from a vty, and serial { virtual com 1 } assumes that you're running from a vty.

You could also write separate scripts instead of using the door_script that's provided, but that's not really needed except in cased like tedit (for TW), as it runs from the TW folder. So I just modified a copy door_script to hard-code the door name and folder. You could do this for every door if you wished, but I find it just as easy to use the single script.

If anyone needs any specific help, please ask.

Wednesday, April 23, 2014

Thoughts on WWiV on Linux

Here are some of my thoughts on running WWiV 5 under Linux. First, it's fairly simple, especially if you do your initial 4.30 setup under dosemu instead of DosBox. The difference between the two is that DosBox creates Linux filenames which are all upper case, while dosemu creates them lower case. WWiV 5 under Linux requires them in lower care, in general. Directory names are defined via WWiV's init (or, initlite) so can be either. Some of the menus need to be upper case because they are called that way from other menus, but the extensions should be lower case. The main menu files should be lower case, but the menu editor might choke on them, so ln -s each file to an upper case filename with lower case extension. This might be required to get editing to work on the other menus as well, but I don't recall.

Aside from upper/lower case filename issues, there are a few bugs I've noticed which appear in the current build under Linux, but not Windows. First, the time left always displays as 0, which is a problem primarily for the door dropfiles. The problem appears to be that IsUserOnline() never returns true under Linux for some reason. The fix was to open utility.cpp and, within the function double nsl(), find the first if statement, and add " || 1" to the first if statement so that it always evaluates to true, instead of to false.

The second bug has to do with filenames as well. in printfile.cpp, the function printfile() doesn't build the filename.ext based on the user's ANSI settings, and only displays the filename exactly how it is passed to it. Because filenames are quite often passed without an extension so that non-ansi users will get filename.msg while ansi users will get filename.ans, this causes quite a few menus/help items to be broken by default. My solution for this was to temporarily remove the extensions from those files that are passed to printfile() without one. This means no separate ansi/non-ansi files, unfortunately. But most modern telnet clients should support ansi, so that's not a huge deal. The bigger issue is the telnet client not using the correct upper-ascii character set. FWIW, this is CP437, and is supported in both the Linux and Windows versions of putty.

In a future post, I will detail how I got DOS doors to work. This took a lot of trial and error, but ultimately worked great :)

Wednesday, April 16, 2014

WWiV 5 on Linux

Just thought I'd let everyone know what I've been up to of late - working on WWiV 5 on Linux. So far, it's installed and (somewhat) functional, but, because I am compiling it natively, and not running under DOSbox or dosemu (which I *have* contemplated using 4.24a instead), I am having problems with doors. I have to run them under dosemu, and it doesn't appear that the dosemu autoexec.bat is running. When I telnet in, and go to the doors, I launch a DOS door, and it hangs at "Launching..." until I press CTRL-C, then it drops me back at the door menu. I feel like I'm pretty close to cracking that nut, though, at which point I'll work on some networking (WWiVnet, Fidonet, and Usenet... Maybe Dovenet) and let everyone know how to access it once those are done. Very, very close. :)

Friday, April 4, 2014

JAMMA Cabinet

A friend of mine is giving me a JAMMA cabinet, specifically, a Street Fighter II cabinet (which is actually JAMMA+), but the JAMMA board is dead, as is the CRT. The cabinet itself is presumably in decent enough shape and the remaining hardware presumably works.

I've been wanting to build a MAME cabinet for a long time, so this will save me a ton of work and expense. I already have everything I need to convert it to a functioning MAME cabinet. I have a Raspberry Pi for the brains. It doesn't have enough GPIO pins to wire up all of the Street Fighter II controls without getting a bit fancy (a matrix layout is easy enough, but the software would be a bit more complex), but I can concentrate on player 1's controls initially. I have an LCD monitor that will work nicely with the Pi as well. If I decide I want a CRT, I can pick up an old TV for free off of Craigslist, I'm sure, adding 0 cost, since the Pi can output to that as well ;)

I have a couple of options when it comes to Player 2's controls. I can hack up a USB game pad, or I can hack up a USB keyboard. Either will work, but there are some known issues with hacking keyboards for use in arcade cabinets. I imagine I should be able to find either for fairly cheap, adding very little, if any, cost to the project.

I also plan on loading Quake onto the Pi, as I have been dying to play is with arcade controls forever.

If I do this right, maybe spending a few bucks on connectors, I should be able to do these mods and make them completely reversible, should I later decide to restore the cabinet to its former glory. Regardless, once I have the cabinet (in a couple of weeks), I'll post pictures, along with a progress report on my conversion.