Sunday, March 28, 2010

The mind is an amazing thing

I'm sitting here playing with an Apple IIgs emulator on my PC and I actually remembered the command to boot a disk from the monitor prompt (type the slot # and press Ctrl-P). That's something I haven't done or even thought about in over 20 years! Amazing.

(Then again, I still remember CALL -151 and 3D0G too).

Friday, March 26, 2010

Reviving my Apple //e

For a long time I've known that there are utilities available to archive old Apple II disks onto the PC but never got around to actually doing it. I still have boxes full of 5.25" disks containing all kinds of pirated games and other apps (warez) that I painstakingly collected back in the 80's when I ran the Shooting Star BBS. I also still have my Sider ][ 20MB (yes that's MEGAbyte not GIGAbyte) hard drive containing all my heavily modified BBS code. Recently I was contacted by one of my old users (not as infrequent as you might think) who got me interested in pursuing this again. So I dug out the //e and powered it up. Last time I tried this I couldn't get any 5.25" disks to boot but this time everything worked! I was even able to run AppleWorks and open some old high school homework files. So now I just need a USB-to-serial adapter and I'll be in business using ADTPro. Not really looking forward to 9600 baud serial disk transfers though...

-DC-

PS: For those who are interested, you can run lots of old Apple II games in your browser for free (just in case you really miss those low-res graphics).

Tuesday, March 23, 2010

I've written a streaming MP3 player for Android

It's probably been done and I just couldn't find it, but after I got my Droid I really wanted a way to traverse and play my home MP3 (and OGG) music collection. So I decided I'd write my own app. It would be a good project for me since I'm a long-time VB programmer looking to learn more Java.

At this point, I've got a working beta version that I'm pretty happy with. I was hoping I could use ConnectBot to make a secure authenticated connection to my home server, but my app kept crashing when using it (socket connection issues--need to work on this later). I set up a Lighthttp web server on my DNS-321, where all my music resides, and connected using HTTP (I've got other servers running at home and already use DDNS so this was relatively painless.) The app allows me to traverse all my MP3 files and folders that are on my DNS-321 via a spinner, and I'm able to pick a file/folder for playback. The cool thing is that the MediaPlayer object I'm using, which comes with Android, actually streams MP3 files over HTTP so the playback starts right away. Unfortunately, even though OGG files are supported with this player, they won't stream (boo Google!) So now I'm having to convert most of my music from OGG to MP3, although I plan to implement a pre-download feature for OGG files later. My PS3 doesn't play OGG either so it makes some sense to switch, even though I think OGG is superior to MP3 for several reasons.

If anyone is interested in trying out the beta version of my player (named StreamStar), let me know. I'd like to get some feedback before making it available in the Market. Plenty of bugs remain since programming Android is fairly complex and not nearly as easy as writing a simple desktop app! Not to mention being somewhat new to Java.

PS: I plan to eventually revise the code so that nearly any web server could be used, not just Lighthttp.

Tri-booting Vista, XP, and Linux


I've been successfully dual booting Vista and Linux (openSUSE) for a while now. The trick was to install Vista first (already done when I bought the laptop) and then openSUSE. GRUB was automatically installed and handled the dual boot situation well.
But after all the problems I've had with Vista not running programs that work fine in XP (Joint Ops, SSH/SMB port forwarding--see my other blog entry, my Hauppauge TV card) I decided that I also needed to be able to boot XP. But how do you get XP installed without clobbering GRUB or anything else? Turned out to be trickier than I thought...
First step is to use Vista's Disk Manager to shrink its partition and make room for XP. I was able to free up about 13GB of space which will be enough for now. Then I formatted it as NTFS.
I knew that installing XP was going to clobber GRUB by overwriting the Master Boot Record (MBR) on my hard drive. So I fired up my trusty Knoppix boot CD and used the program DD to backup the MBR to a file. The trick here is to only back up part of the MBR (the first 448 bytes) because the rest contains the parition table which we don't need to mess with.
Once the MBR has been backed up, you can start the XP install process. Just make sure to specify the new partition as the installation destination. No need to format it (did that above using Vista.)
After XP finishes its install the computer will reboot. XP will boot up because GRUB is now toast. Let it finish the install process completely--your old partitions and data will remain untouched.
Next step is to get GRUB back. Boot up Knoppix again and find that MBR backup file that was created above. Use DD again to copy the original MBR back to the disk.
When you reboot, you should see GRUB again. But you'll notice that XP is not one of the boot options. You'll need to modify the GRUB menu file (usually menu.lst--depends on your version of Linux) and add an entry for XP.
Once you've added XP to the list of boot options in GRUB, reboot and select it from the list. If all goes well, XP should boot up (and so should all the other OS's.)
If for some reason Vista won't boot anymore, you'll need to run Vista's Startup Repair tool to fix it.
That's it!
(Well not quite, at least not for me. I soon learned that HP does not provide XP drivers for my Pavilion dv6500 laptop! I had to find a hacked nVidia driver to install--one with a modified INF file to allow installing on XP, among other things. Also, since this laptop has a SATA drive controller, the XP install CD does not see it and, since I don't have a floppy drive, I couldn't hit F6 to install it! Solution was to use nLite to create a new XP install CD with the necessary driver.)