nixers
Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - Printable Version
+- nixers (https://nixers.net)
+-- Forum: Embedded (https://nixers.net/Forum-Embedded)
+--- Forum: Other Embedded Platforms and Hardware Hacking (https://nixers.net/Forum-Other-Embedded-Platforms-and-Hardware-Hacking)
+--- Thread: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience (/Thread-Installing-OpenWRT-on-the-Zipit-Z2-for-a-20-pocketable-linux-experience)


Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - hades - 30-07-2013

Hi, unixhub! You guys have all probably wished, at some point or another, for a tiny, cheap computer that could fit in your pocket and run *nix on the go. I wished, for a long time, for the same thing, and now, I've finally found my nirvana: the Zipit Z2. With a 312 MHz processor and 32MB of RAM, it's sufficient for running a minimal linux system and doing some everyday tasks. I've used mine for emulating Gameboy games, playing vitetris, browsing the forums here, playing music, and chatting on IRC.

Now, I intend for the remainder of this post to be a tutorial. If you want to spend the best 20 dollars you've ever spent (Okay, 28 if you count the price of an SD card), then go ahead and bookmark this thread.

You can order a Z2 for 14 bucks (plus shipping, which equalled 20 for me) here. Once you have your Zipit ordered, you'll need a MiniSD card. Of course, most laptops have a regular-sized SD port, so you'll probably want to order one of these types of sets- a microSD card with a miniSD and Standard SD adapters - which is what I used.

Once both of those things arrive, download this zipped archive. Unzip it and copy its contents to your miniSD card. This is mozzwald's "Flashstock" script, which installs the U-boot bootloader onto the tiny flash memory on the Z2, overwriting the Z2's original OS. Once you're done copying this to the SD card, open a terminal, enter "sync", then unmount the SD card. Put the card into your Z2 and power it on. Follow the onscreen dialogues to flash your device.

Once you're done with that, power off your device and put your SD card back into your computer. Format the card as Ext2. Now, download the unofficial port of OpenWRT for the Z2 here. OpenWRT is a version of linux designed for routers - it's perfect for embedded systems and is extremely lightweight, which makes a lot of sense for the Z2. A minimal install of OpenWRT can be squeezed into 2MB. Anyway, when you're done downloading that tar.gz file, open a terminal once again and become root - you must be root from this point on. move the tar.gz file to the SD card, then use the tar command to extract it. Once you're done, run "rm *.tar.gz" for cleanup, "sync" to make sure the SD card is free from processes, and then unmount the SD card. Put the SD card in your Zipit and boot. Once the text hasn't scrolled for a good 5 seconds, press enter to start the shell. Hit the stop button at the top of the keyboard to switch shells (there are two open at a time). To configure the wi-fi, you'll need to use vi to edit /etc/config/wireless (which is commented to guide you). As soon as you're connected, run "opkg update" and then try installing something - I highly recommend the text editor of the gods, vim - so just type "opkg install vim". To run a graphical package, you'll need to be in the second terminal - don't ask me why, it just works that way. I highly recommend running "opkg vitetris ohboy elinks vim irssi"

Here's the official Z2 OpenWRT page, which has more helpful info: http://chainxor.org/openwrt-zipit/

Anyways, it you have any questions, feel free to ask me, and if you really get in a bind and need help, get on irc.freenode.net #zipit. The folks who ported OpenWRT to the Zipit are all there and ready to help.

Of course, with U-boot, you can try other distros. There's a port of Debian for the Z2, a port of Arch, a port of Ubuntu (eww), a pen-testing distro called Sidetrack, and tons of others. The procedure is almost always the same, just unzip (as root) the rootfs onto the SD card and you're good to go.

Good luck, guys! I hope this device makes someone here as happy as it has made me! And of course, pictures are coming soon!


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - venam - 30-07-2013

That's a nice tutorial and a very cheap one.
How much the initial system take of the total ram?
Isn't it hard to use because of the lack of ram?


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - hades - 30-07-2013

Not at all, right now I have mocp playing a song and irssi running and it's only taking up 10 megs of RAM. Like I said, OpenWRT is designed to run on wireless routers, and as such, is perfectly content to use 32 megs. It makes for a wonderful handheld Linux experience.


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - berk - 30-07-2013

Nice one coop! :)


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - hades - 30-07-2013

Thanks! Let me know if any of you guys decides to get a Z2. I'd be glad to offer any assistance you need. Also, it'd be nice to get a few of the guys from the zipit hacking community to come over here. They're really knowledgeable about *nix (Especially the guys who ported OpenWRT to the zipit.. They pretty much built it from scratch in a cross-compiler, piece by piece)


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - ArchiMark - 12-08-2013

Excellent tutorial...and great timing as I got my Z2 last week.... ;-)

Got Z2 flashed and booting up OK...but trying now to get connected to wifi network....

Haven't managed to get connected to network yet...but according to info read on the http://chainxor.org/openwrt-zipit/ page z2 wifi is working...so, think the /etc/config/wireless needs some further tweaking....

Do I need to re-edit this file if I want to connect to a different network or is there an easy way to set things up so that it finds available networks and let me choose which to connect to?

Understand that the 'happy face' key is the 'esc' key. Do you know what key is the 'ctrl' key?

Also, what key combo do you use for the '(' and ')' characters?

Is there a keymap somewhere to look at?

Thanks for any assistance to this linux noob.... ;-)

Mark


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - hades - 12-08-2013

(12-08-2013, 04:27 PM)ArchiMark Wrote: Excellent tutorial...and great timing as I got my Z2 last week.... ;-)

Got Z2 flashed and booting up OK...but trying now to get connected to wifi network....

Haven't managed to get connected to network yet...but according to info read on the http://chainxor.org/openwrt-zipit/ page z2 wifi is working...so, think the /etc/config/wireless needs some further tweaking....

Do I need to re-edit this file if I want to connect to a different network or is there an easy way to set things up so that it finds available networks and let me choose which to connect to?

Understand that the 'happy face' key is the 'esc' key. Do you know what key is the 'ctrl' key?

Also, what key combo do you use for the '(' and ')' characters?

Is there a keymap somewhere to look at?

Thanks for any assistance to this linux noob.... ;-)

Mark
I've been just editing the /etc/config/wireless file, but I think there's an easier way to connect - I just haven't looked for it. I'm sure the guys over on the #zipit irc channel would know...
On my zipit, the "..." Key is the ctrl key, and Shift plus the comma and period keys will make parentheses. I'll have to find the keymap, I'll come back and post the link when I find it


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - ArchiMark - 12-08-2013


Thanks for your input.....

Still trying to connect, but at home now..so, will try it again here...hopefully will be more successful...

Meanwhile, here's link to keymap..... ;-)

http://engine12.com/files/gmenu-zipit/packages/keymap.map.jpg


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - hades - 12-08-2013

Ah, that's the one I was looking for. Yes, it came in handy when I was trying to do some Python tutorials on my Zipit a few weeks ago, as parentheses and brackets and some other symbols were necessary.


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - Mafia - 12-08-2013

I think I'm gonna have to buy one of these :o


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - jbeale - 06-09-2013

I have two stock Zipit Z2 devices, been on a shelf for a few years. I'm trying to follow these instructions. I unzipped FlashStockv01.zip onto a 2 GB uSD card (using a WinXP box) and put that card in a miniSD adaptor into a stock Zipit Z2, and powered it up. It proceeded to give me the stock Z2 intro screens etc. as if the card was not there. I tried SDFormatter, reloaded, retry; same result. The SD card format was FAT. Is there something I'm doing wrong (apart from using windows :-)?


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - hades - 06-09-2013

I think it needs to be Ext2 but I'm not sure. Try doing it from linux and also make sure you copy it as root and if it still doesn't work, open a terminal window in linux, navigate to your SD card, and run "sudo chmod +x *" to make sure all the files on the SD card are set as executable.


RE: Installing OpenWRT on the Zipit Z2 for a $20 pocketable linux experience - hades - 25-03-2015

Update:

Got the Zipit out of storage today, since I haven't messed with it in a couple of years. I have a specific use for it in mind, too: Now I have my own office at work, but my computer sits behind a mess of firewalls and I can't install programs. This means that to monitor IRC channels, I need something small that can sit beneath my monitor and won't take up much space or draw much attention. And so, I'm going to be using the Zipit for that.

But if I'm taking it out of storage and playing with it, why just use it for IRC? I started thinking of other uses it could have, and I remembered that I can't browse 4chan on my work computer - perfect job for the Zipit.

Using a browser that displays images on the Zipit is tedious, so I'll need a sleeker solution - making my own standalone 4chan app. That I will write in Python.

So, I guess this will take the place of my Unix Diary entry for today.

TL;DR - I'm writing a standalone 4chan app for a computer that's slow even by 1998's standards. Fun.