[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
ADTPro/VSDRIVE over WiFi (was: mass storage for Apple //c)
On Monday, May 20, 2013 10:58:18 AM UTC-4, Ivan X wrote:
> So I've been playing around with the (relatively new) VDRIVE component of the ADTPro package. It lets you access a ProDOS disk image of whatever size, called "Virtual.po" in the "disks" folder of a computer running the ADTPro server software.
>
>
>
> But it works over serial, so you don't need an Uthernet card or whatever, only a USB-to-RS232 cable. You just run VSDRIVE from BASIC.SYSTEM and then the disk image mounts as S2D1. You can CAT,S2 and go to town.
>
>
>
> So then Raspberry Pi. It's cheap and small enough that It could really be a mass storage card for a //c (or any other Apple II). After much futzing, it works, and It's super cool. I managed to also get it to work with a ProDOS disk image over the internet. Apple II cloud computing!
>
>
>
> Because the ADTPro server uses Java and various binary serial libraries, I had to:
>
>
>
> - get Java 1.8 early access for ARM-hf (https://jdk8.java.net/fxarmpreview/index.html)
>
> - put it in /usr/local/java
>
> - set JAVA_HOME=/usr/local/java/jdk1.8.0 in /etc/environment
>
> - set PATH to include /usr/local/java/jdk1.8.0/bin in ~/.bashrc
>
> - install librxtx-java package (via apt-get per usual)
>
> - alter adtpro.sh to specify:
>
> /usr/share/RXTXcomm.jar in the java classpath
>
> -Djava.library.path=/usr/lib/jni
>
> -Dgnu.io.rxtx.SerialPorts=/dev/ttyAMA0:/dev/ttyUSB0
>
> - comment out the serial port gettys in /etc/inittab
>
>
>
> Because I use my Pi headless, I also installed xrdp, which allows me to get to its desktop with an RDP or VNC client on my Mac. Then, from an xterm on the Pi desktop, I ran ADTPro, chose the ttyUSB0 serial port at 115200, and I was able to bootstrap VDRIVE and go to town.
>
>
>
> Then I found socat, which bridges a serial port to a TCP port, and since the ADTPro server now has a feature to talk to a TCP port, I was able to actually run ADTPro in my office, poke a hole in my router at home to access the Pi via SSH, and forward the socat port through the tunnel from work to home, so the ADTPro server at work could "make contact" with the serial port on the pi. So I could CAT,S2 and access a ProDOS disk in a remote location. THAT IS COOL. (I could have also done it with a direct port forward rather than SSH tunnel, but then all my precious Apple II top secret documents wouldn't be encrypted.)
>
>
>
> I'm kind of excited about this. And the Raspberry Pi model A (the $25 one with only a single USB and no Ethernet) can supposedly be powered with 5v 300 mA, which makes me wonder if the 12v 300 mA pin on the //c video expansion port can be used with some sort of device to reduce the voltage, and then the Pi becomes a true self-contained storage device for the //c. (I'm completely clueless when it comes to electricity, so I don't know how viable this is.)
>
>
>
> Now I gotta see how much software is happy when using VDRIVE.
So I found this gizmo:
http://www.usconverters.com/index.php?main_page=product_info&cPath=70&products_id=404
It joins your wifi network and contains and bridges its RS232 serial to a TCP port, allowing data to pass back and forth between a TCP/IP application on the LAN (or WAN), and your Apple II. For power, it includes a 5v header (which can be attached to pin 6 on the external drive connector), or it also accepts mini-USB, or 5V on pin 9 of the DE-9. It also has a switch to put it into DTE or DCE mode. It's pretty slick.
So of course I wanted get an Apple //c to work with ADTPro and VSDRIVE, over WiFi. On my Mac, I configured the ADTPro server to use the IP address and TCP port of the serial-WiFi bridge, and started localhost mode (there's no button for this; you have to start it from the command line).
Anyway, IT WORKS...almost. It actually works fine on a IIgs. On my IIc Plus, VSDRIVE seems to be ok, though I saw one unexpected I/O ERROR. With ADTPro, it seems to read the data fine, and then during the first disk write, the ADTPro server appears to keep trying to send data, and aborts the transfer before the disk write can complete. This doesn't happen with a USB-to-serial cable directly attached to the same host computer. My guess is that it has something to do with the IIc's hardware handshaking weirdness (or lack thereof), but maybe it has to do with how the serial-WiFi bridge buffers, or maybe it's simply the fact that the IIgs writes the floppy much faster than the IIc Plus does (even at Normal speed).
I also don't know exactly where the serial cable that I'm using came from, so I might make my own per David's instructions on the ADTPro site with a regular //c. Also, there's a lot of parameters for the serial-wifi unit, so I haven't given up yet. If I can get it to work, this might be yet another option for the problem everyone's eager to solve, which is how to make a //c have a larger world than the floppy in its drive. (Though a Raspberry Pi might actually be cheaper, and Osgeld and Cedric's forthcoming creations might be easier.)