HunterDavis.com 4.0!

15Dec/0819

Don’t Panic! The REAL HitchHikers Guide is here TODAY

As it turns out, with a little bit of effort you can put together a cheap (50$), handheld, wireless, graphical wikipedia browser ala the HitchHiker's Guide.

Don’t panic!  A real guide to everything (Wikipedia)

Prerequisites:
Install Linux (wifi), Xfbdev (x11) and Dillo (browser) on your Zipit Z2 as described here.

DilloRC:
Here's the custom part. After launching dillo for the first time, you'll have a ~/dillo/dillorc file in your home directory. Open that up, and customize the layout to your liking. Personally, I just enable "fullscreen mode" at startup and it hides all the buttons. Then head on down to the "search url" and enter in:

"http://google.com/search?btnI=1&q=en.wikipedia.org +%s"

This tells dillo to use google's "I'm feeling lucky" search on wikipedia for the search term. This allows for instant wikipedia browsing over wireless ala the hitchhiker's guide. All for under 50$ nice!

Filed under: Zipit Hacking 19 Comments
13Dec/0822

Dosbox for Zipit Z2!

Pools of Radiance

It turns out that with a bit of source code modification, you can get dosbox running quite well on your zipit z2!! This is HUGE for me, as I'm currently reliving my youth with a Pools of Radiance campaign on my z2! For those impatient to try it out, DL the openembedded ipkg and modified source files at the end of this post.

Enabling Swap
Follow the directions here for adding a swap file. I recommend a good 64 meg chunk. This will keep dosbox from segfaulting when it searches for available memory.

Modifying Sources
Head into your dosbox source directory (or the dosbox/src directory in your OE bitbake tree) and do a
"grep -r "640" ./* ".
This will return all the source files containing video mode switches. You're going to want to change all the SDL function calls from 640,480 to 320,240.

Installing Dosbox
Bitbake your new dosbox and install prerequisites. You're going to need a whole mess of SDL libraries like sdl-net sdl-image sdl-x11 etc. My usual routine is:
(bitbake host) bitbake (package name) && bitbake package-index
(z2) ipkg update && ipkg install dosbox
if #2 complains, replace (package name) in #1 with missing package


Editing Dosbox config and startup

By default dosbox will enable a number of options that are not conducive to use on the zipit z2. Luckily you can pass the dosbox config file location to it on startup. I start dosbox straight from the command prompt, as opposed to from an xterm window. It saves about 1/2 meg memory, and every little bit helps. I start dosbox with the standard xfbdev script ala:
export DISPLAY=:0.0
Xfbdev -screen 240x320@90 -hide-cursor -br &
dosbox -conf ./.dosboxconf

My dosbox.conf is attached with the code below, but at minimum you'll need to set the following option to enable the arrow keys:
usescancodes=false

And that should get you going. The initial dosbox window will be larger than your display, and the cursor may be scrolled off screen. This will be resolved when you start a game, but I like to add the game start commands to the dosboxconf as below:

[autoexec]
# Lines in this section will be run at startup.
mount c /home/root/
c:
cd poolrad
start

And that's that! You can download the updated source code and ipkg files here.
dosbox modified sources and configs

12Dec/084

Zipit Z2 – A Wireless TOR and Privoxy router in the palm of your hand

So I've got a new pet project, the zipit z2. If you don't know this 50$ handheld is actually a moderately powerful computer. 32 megs of ram, a 2g sd card, and a 300mhz arm processor means I can do quite a bit of interesting stuff (we've certainly worked with less!). After doing the prerequisite install of Angstrom linux, I decided to see what it would take to run tor and privoxy on it.

Zipit Z2

Turns out, not much.

I'll be posting quite a bit more on this in the future, but for those enterprising zipit hackers out there who need an anonymous connection to the outside world, look no further than this post.

Changes required for tor:
If you attempt to bitbake tor, you'll receive c++ build errors about duplicate declarations of a couple of functions. This is due to unnecessary forward declarations of these functions in the .h files. Simply open the .h files mentioned by the errors, and delete the offending line. Tor will then compile fine.

Changes required for privoxy:
If you attempt to bitbake privoxy, you'll receive an error from the configuration script about your build environment. Luckily, it's harmless. Browse into the source tree and open up the 'configure' script. Search for the "incorrect host" (or whichever particular message you received) and delete the if/fi codeblock surrounding it. Do this 3 more times (its in there multiple times) and privoxy will compile fine.

And that's it. Just set your /etc/privoxy/config to forward to socks port 9050 (standard privoxy config) and you're secret squirrel!

Filed under: Zipit Hacking 4 Comments