Thursday, November 22, 2007

Some success with X/Qt

After a lot of unsuccessful trials with the Xqt package in the feed I had some success with the old version of Xqt (0.0.8). I also had to install the sharp-compat-libs to make this run. Both packages are not in the official OZ feed. After installing both packages and running makecompat on Xqt. To start Xqt, run at /home/root:

# export DISPLAY=:0.0
# .xserverrc
# .xinitrc
I also installed several things from the Xqt feed (blackbox, fonts etc...). So once running these commands I get a functional X server running the blackbox windowmanager. Until now I've encountered two major problems,
1) The Return key is not functional. The only workaround I could find to this problem is to use xmodmap and to map another key. To remap the "Home" key:
# xmodmap -e "keycode 64 = Return"
2) The other problem is that fn-click does not produce a right click (this is because fn does not function, like the return key). Again, the only way I found to work around this problem is using xmodmap to switch between the mouse buttons:
# xmodmap -e "pointer = 3 1 2 4 5"
will cause a click to be a right click. to return to the default state:
# xmodmap -e "pointer = 1 2 3 4 5"

Thursday, October 11, 2007

Alsa Mixer

Sometimes the alsmixer settings get corrupted, so I take a note of the "good" settings:

  • Sidetone: 100
  • Mic Boost: Off
  • Playback: (Off) 81
  • Playback De-mphasis: None
  • Capture Mic: On
  • ADC High Pass Filter: On
  • Input Mux: Line In
  • Jack Function: Off
  • Output Mixer HiFi Playback Switch: On
  • Output Mixer Line Bypass: On
  • Output Mixer Mic Sidetone Switch: Off
  • Speaker Function: On
  • Store DC Offset: Off

Wednesday, August 8, 2007

The good book (dagger) and ZBedic

The good book
I though installing dagger and the sword engine to study the bible a little bit... but The "uninterruptible sleep" probelm appeared again...

Install dagger & sword:

# ipkg install -d loop0 dagger sword
# ipkg-link add dagger; ipkg-link add sword-dev; ipkg-link add sword
No problem starting dagger the first time, then I change the path to the books to ~/Documents/books/sword/, restart dagger (as requested) - then dagger goes into coma. I think it has something to do with the loop0 because I see [loop0] entry in ps which is also in D state. Maybe the problem appears because I'm using fat fs for the SD card... I tried installing dagger to the internal memory - that didn't help so eventually I removed the whole thing.

ZBedic - the electronic dictionary
Installing zbedic:
# ipkg install -d loop0 zbedic
# ipkg-link add zbedic; ipkg-link add libsqlite3-0
Now a dictionary is required. At the zbedic homepage I found WordNet 1.6. Just put it somewhere and direct zbedic to it (int the configure menu).

zbedic can be connected to opie-reader. From the zbedic documentation: In opie-reader settings, under the Locale tab enter 'zbedic' as Application and 'find' under Message. In the Misc tab under 'Select Action' check Dictionary.

Saturday, July 14, 2007

Gimp, AbiWord, Firefox and Emacs

I have setup Xserver, so now I want to have fun with some of those X applications.

GIMP,
is the GNU Image Manipulation Program,

# ipkg install -d loop0 gimp
# ipkg-link add gconf-dbus ; ipkg-link add gimp ; ipkg-link add gnome-vfs-dbus ; ipkg-link add gnome-vfs-plugin-file ; ipkg-link add libart-lgpl-2-2 ; ipkg-link add libexif9 ; ipkg-link add libpopt0 ; ipkg-link add libxmu6 ; ipkg-link add libxt6 ; ipkg-link add tiff
GIMP is really slow to start up, and slow on use.

AbiWord,
AbiWord is a word processing program similar to Microsoft® Word,
# ipkg install -d loop0 abiword # ipkg-link add abiword ; ipkg-link add aspell ; ipkg-link add enchant ; ipkg-link add glibc-gconv-cp1252 ; ipkg-link add glibc-gconv-ibm850 ; ipkg-link add glibc-gconv-iso8859-15 ; ipkg-link add libaspell15 ; ipkg-link add libfribidi0 ; ipkg-link add libgnomecanvas-2-0 ; ipkg-link add libgnomeprint-2-2-0 ; ipkg-link add libgnomeprintui-2-2-0
Firefox
# ipkg install -d loop0 firefox
# ipkg-link add firefox ; ipkg-link add libbonobo ; ipkg-link add libgnome ; ipkg-link add libidl-2-0 ; ipkg-link add orbit2
and ipkg install again, to fix the postinst errors.
When I tried to start firefox it hanged and I had to reboot - so firefox does not work and I removed it.

Emacs
# ipkg install -d loop0 emacs
# ipkg-link add emacs
this is a very big installation (15MB), and rather lengthy.

Thursday, July 12, 2007

Changing the default shell to bash

The default shell can be changed in /etc/passwd, by changing /bin/sh to /bin/bash for the root entry, to look like this:

root:DJa2sk3j82das:0:0:root:/home/root:/bin/bash
but this will break the default dropbear ssh server, to fix it install the openssh server,
# ipkg install -d loop0 openssh-sshd
# ipkg-link add openssh-sshd
and ipkg install again to fix the errors

Wednesday, July 11, 2007

X and OPIE - the saga continues

I decided that the proper way to make X work along side with OPIE is to follow the HowTos/OPIE and GPE.
So after changing -terminal 2 to -terminal 3 in /etc/init.d/opie

I first installed gpe-dm thinking (wrongly) that this will solve the problem,

# ipkg install -d loop0 gpe-dm
# ipkg-link -d loop0 gpe-dm

then ipkg install again to fix the errors. gpe-dm started X which I had to stop from command line by /etc/init.d/gpe-dm stop

I installed gpe-task & gpe-base-depends
# ipkg install -d loop0 gpe-task-base gpe-base-depends
# ipkg-link add bl ; ipkg-link add gpe-base-depends ; ipkg-link add xcursor-transparent-theme ; ipkg-link add detect-stylus ; ipkg-link add esd ; ipkg-link add gpe-autostarter ; ipkg-link add gpe-conf ; ipkg-link add gpe-confd ; ipkg-link add gpe-login ; ipkg-link add gpe-screenshot ; ipkg-link add gpe-soundserver ; ipkg-link add gpe-task-base ; ipkg-link add gpe-theme-industrial ; ipkg-link add gtk-engine-industrial ; ipkg-link add gtk-engine-mist ; ipkg-link add gtk2-theme-angelistic ; ipkg-link add hotplug-dbus ; ipkg-link add ipaq-sleep ; ipkg-link add libfontconfig-utils ; ipkg-link add libgtkstylus ; ipkg-link add libxsettings0 ; ipkg-link add libxss1 ; ipkg-link add matchbox-themes-gtk ; ipkg-link add rxvt-unicode ; ipkg-link add startup-monitor ; ipkg-link add suspend-desktop ; ipkg-link add teleport ; ipkg-link add ttf-bitstream-vera ; ipkg-link add xst
then ipkg install again to fix the errors.

Now reboot, gpe and opie will run after reboot...
Ok, now there is some kind of a problem with fluxbox, so I changed the x-window-session symlink to point to the matchbox-session,
# ln -s /usr/bin/matchbox-session /usr/bin/x-window-manager
Now everything runs fine (but with the matchbox windowmanager).

To disable the the login screen, set AUTOLOGIN to true in /etc/sysconfig/gpelogin

After fixing ~/.profile (removing the exec command from .profile and fixing passwd - see the following post) and linking x-window-manager,
# ln -s /usr/bin/matchbox-session /usr/bin/x-window-manager
fluxbox starts ok.

To prevent from GPE to start on boot remove it from the boot sequence,
# rm /etc/rc5.d/S99gpe-dm

Saturday, July 7, 2007

A new SDL library

zodttd is working on a new version for psx4all for the Zaurus, he has released a new version which includes also a new and improved DSL library. I tried the new library and I saw a noticeable improvement in performance. With the new SDL library the arrow keys are in the right direction.

I installed it manually to /media/loop0/packages/user/lib and then linked,

# ln -s /media/loop0/packages/user/lib/libSDL-1.2.so.0.7.2 /media/loop0/packages/user/lib/libSDL-1.2.so.0
I checked the files thay uses libSDL:
  • VBA - still can't run sound but there is an improvement in performance.
  • snes9x - I saw an improvement in the performance, but the screen flickers with the new library.
  • gpsp - still couldn't use it.
  • ScummVm - The menu bug is back - it seems that the fn key is mapped to alt in this version of SDL and ScummVm wouldn't accept any key combination as F5.
  • mplayer - works fine.

X and OPIE

The original idea was to setup the X according to endors mini how-to X/Qt on OESF, and then to use Xqt2 as an Xserver. the first part worked fine, but I couldn't convince the Xqt2 server work properly. Then something corrupted the boot sequence and I had te reflash. I installed X again, with some success, but not Xqt2.
The situation after the installation process is that fluxbox hangs during startup in such a way I have to soft-boot the Zaurus (Alt-Home-B). It seems that if I stop OPIE start the X from the command line and go back to OPIE X will start up fine. I thought the problem was memory so I created a swap file -but this didn't solve the problem.
I have found a little bit more about this problem, it seems that in the cases fluxbox hangs it goes into "uninterruptible sleep" ('D' status under top or ps - someone said that D stands for 'Dead'). Apparently there is no way to kill those processes apart of reboot.

first add the X11 feed to /etc/ipkg.conf,

src/gz x11 http://ewi546.ewi.utwente.nl/mirror/www.openzaurus.org/official/unstable/3.5.4.1/feed/x11
src/gz x11-old http://ewi546.ewi.utwente.nl/mirror/www.openzaurus.org/official/unstable/3.5.4/feed/x11
src/gz upgrades-old http://ewi546.ewi.utwente.nl/mirror/www.openzaurus.org/official/unstable/3.5.4/feed/upgrades
Then install (don't forget to ipkg update) xserver-kdrive-fbdev and it's dependencies,
# ipkg install -d loop0 xserver-kdrive-fbdev
# ipkg-link add libxau0 ; ipkg-link add libxdmcp0 ; ipkg-link add libxfont1 ; ipkg-link add xserver-kdrive-fbdev
next, install xserver-common,
# ipkg install -d loop0 xserver-common
# ipkg-link add libexpat0 ; ipkg-link add libfontconfig1 ; ipkg-link add libx11-6 ; ipkg-link add libxcalibrate0 ; ipkg-link add libxext6 ; ipkg-link add libxft2 ; ipkg-link add libxrandr2 ; ipkg-link add libxrender1 ; ipkg-link add libxtst6 ; ipkg-link add xdpyinfo ; ipkg-link add xmodmap ; ipkg-link add xrandr ; ipkg-link add xserver-common ; ipkg-link add xtscal
install xbase-clients
# ipkg install -d loop0 xbase-clients
# ipkg-link add libxmuu1 ; ipkg-link add xauth ; ipkg-link add xhost ; ipkg-link add xrdb ; ipkg-link add xset
install libcairo1,
# ipkg install -d loop0 libcairo1
# ipkg-link add libcairo1 ; ipkg-link add libpixman1
install gpe-session-scripts (this will install GPE),
# ipkg install -d loop0 gpe-session-scripts
# ipkg-link add atd ; ipkg-link add blueprobe ; ipkg-link add bluez-utils-dbus ; ipkg-link add dbus-1 ; ipkg-link add gdk-pixbuf-loader-gif ; ipkg-link add gdk-pixbuf-loader-jpeg ; ipkg-link add gdk-pixbuf-loader-png ; ipkg-link add gdk-pixbuf-loader-xpm ; ipkg-link add glibc-gconv ; ipkg-link add glibc-gconv-iso8859-1 ; ipkg-link add gpe-announce ; ipkg-link add gpe-bluetooth ; ipkg-link add gpe-clock ; ipkg-link add gpe-icons ; ipkg-link add gpe-login ; ipkg-link add gpe-question ; ipkg-link add gpe-session-scripts ; ipkg-link add gtk+ ; ipkg-link add libatk-1.0-0 ; ipkg-link add libaudiofile0 ; ipkg-link add libcontactsdb0 ; ipkg-link add libesd0 ; ipkg-link add libeventdb0 ; ipkg-link add libglade-2.0-0 ; ipkg-link add libgpelaunch0 ; ipkg-link add libgpepimc0 ; ipkg-link add libgpevtype0 ; ipkg-link add libgpewidget1 ; ipkg-link add libice6 ; ipkg-link add libiw28 ; ipkg-link add libmb1 ; ipkg-link add libmimedir-0.3-0 ; ipkg-link add libschedule0 ; ipkg-link add libsm6 ; ipkg-link add libsoundgen1 ; ipkg-link add libsqlite0 ; ipkg-link add libstartup-notification-1-0 ; ipkg-link add libxcursor1 ; ipkg-link add libxfixes0 ; ipkg-link add libxinerama1 ; ipkg-link add libxpm4 ; ipkg-link add libxsettings-client0 ; ipkg-link add matchbox ; ipkg-link add matchbox-applet-inputmanager ; ipkg-link add matchbox-common ; ipkg-link add matchbox-desktop ; ipkg-link add matchbox-panel ; ipkg-link add matchbox-wm ; ipkg-link add pango ; ipkg-link add pango-module-basic-fc ; ipkg-link add pango-module-basic-x ; ipkg-link add xkbd ; ipkg-link add xstroke
to correct the errors:
# mkdir /media/loop0/packages/etc/gtk-2.0 # ln /media/loop0/packages/etc/gtk-2.0 /etc/gtk-2.0 -s
and then rerun,
# ipkg install -d loop0 gpe-session-scripts
remove gpe-login
# ipkg-link remove gpe-login
# ipkg remove gpe-login
fluxbox
To solve the "Interruptible sleep" I tried installing it to the internal memory,
# ipkg install fluxbox-gpe
mrxvt - more than rxvt,
# ipkg install -d loop0 mrxvt
# ipkg-link add mrxvt
OpenSSH
I'll install openssh for the X11 forwarding,
# ipkg install -d loop0 openssh-ssh
# ipkg-link add openssh-ssh

ROX-filer
this package seems to be problematic - the first time I installed it it cause corruption in the filesystem - after fsck.ext2 /media/card/images/loop0 and reinstalling the package for the Zaurus - not by ssh'ing it was installed okay.
# ipkg install rox-filer -d loop0
# ipkg-link add libxml2 ; ipkg-link add rox-filer ; ipkg-link add shared-mime-info
and to fix the errors rerun,
# ipkg install rox-filer -d loop0
In order for rox-filer to work propely the APP_DIR variable needs to be defined,
# export APP_DIR=/usr/share/rox/
startx.sh
I couldn't find the package that provides the startx script so I created one, which sets the DISPLAY and APP_DIR variables and runs Xserver, Xinit, rox-filer and fluxbox.

X/Qt 2
I'll try Xqt once more,
# ipkg install xqt2 -d loop0
# ipkg-link add xqt2
Runing Xqt failed with segmentation fault, when I changed the QWS_DISPLAY to "Transformed:Rot270:0" variable I managed to start Xqt but with the same problems as before (screen is rotated and doesn't get refreshed).

Wednesday, July 4, 2007

Corrupted

My last escapade was to install X, I managed to install the fluxbox window manager, then I installed the ROX-Filer file manager, and then things started to go wrong, my Zaurus halted couple of times, afterwards the boot process halted and I had to reboot several times before a successful boot. To be specific the boot sequence halted on "Starting the potmap deamon: portmap.". Pressing Ctrl-C resumed the boot sequence and it halted on "Starting OBEX Push deamon: opd." here nothing helped.

So now it looks like reflashing is inevitable...

Tuesday, June 26, 2007

Remapping the keyboard and ScummVM

I found a way to bypass the menu problem with ScummVM. The menu is originally bind to the F5 key - which does not exists on the zaurus. But I can map Fn-5 to simulate F5, just edit /etc/keymap-2.6.map, and add under,

keycode 6 = five
The following line,
altgr keycode 6 = F5
Now when I run ScummVM and press Fn-5 the menu pops up - hurrah.
So now I can update the old 0.6.1 version to the new 0.9.0 version,
removed the old version,
# ipkg-link remove scummvm-qpe
# ipkg remove scummvm-qpe
and installed the new one,
# ipkg install -d loop0 scummvm
# ipkg-link add libflac4; ipkg-link add libvorbis ; ipkg-link add scummvm
The new version supports skins, so I'll install the modern-dark theme from www.tyrannozaurus.com ScummVM section. After installing a theme the theme.ini and theme.zip filenames should be changed to modern.ini and modern.zip (in /usr/share/scummvm/themes/).
It is also suggested in tyrannozaurus to use the AdvMAME 2x filter.

Saturday, June 23, 2007

gpsp & VisualBoyAdvanced

I found a list of emulators in a post on OESF. I started with gpsp the same way as I did with snes9x, put the bios in the rom's directory, started gpsp - I got the menu, I could use the arrow keys, but couldn't use return (or ok or whatever starts a rom). Cancel did not exit the program, the only way to stop it is killall gpsp via ssh. I also tried to start a rom from command line, but then I got a nonreponsive black screen. Now I had to kill opie inorder to stop gpsp.

Then I tried VisualBoyAdvanced (VBA). Installed it (with -force-depends), I used a similar script to the one I used with snes9x...
and voilla, vba runs, a bit slow, no sound (If I enabled sound it came out statering) - but playable.
I needed to tweak a little bit with ~/VisualBoyAdvance.conf. I switched the arrow keys directions, return did not work so I changed select to Q. I tried playing with the various switches to improve performance but I had no luck there.

Friday, June 22, 2007

snes9x

I found this old ipk on my zaurus, snes9x-sdl-qpe_1.39-r1_arm tried to install it, and it complained for missing libsdl, which was already installed by libsdl-1.2, so I forced demands, and installed:

# ipkg install -d loop0 snes9x-sdl-qpe_1.39-r1_arm.ipk -force-depends
# ipkg-link add snes9x-sdl-qpe
when I tried to run it, I got a black window with sound (which was encouraging). I found this website and used the following switches, no snes9x started but it was rather slow (because of the resize):
# snes9x -hi -x2 -xs 640 -ys 480
The -x2 switch causes snes9x to double the picture so it fits the screen nicely, removing it greatly improves performance (but results in a small window). Another possibility is to use qcop commands to change resolution to 320x200 (like I did for mplayer). Now horizontal lines appeard and the picture was upside down. To solve this I added "SDL_QT_INVERT_ROTATION=0" before running snes9x. Now picture is nice, performance seems reasonable, but, the arrow keys are messed up. I couldn't fix the arrow-keys, but I found a way to redefine the controls, so I used g, l, i & m instead. To set the keys a S9XKEYS variable need to be defined (before starting snes9x):
# export S9XKEYS=27,100,99,115,120,97,122,113,32,103,108,105,109,121,98,112,13
Which translate to:
  • Quit = Cancel
  • D = Button A
  • X = Button B
  • S = Button X
  • X = Button Y
  • A = Button L
  • Z = Button R
  • Q = Start
  • Space = Select
  • The directions are:
Y
IP
G
L
B
MCR

The definition of S9XKEYS is explained here:
S9XKEYS=Quit, A, B, X, Y, L, R, START, SELECT, LEFT, RIGHT, UP, DOWN, LEFTUP, LEFTDOWN, RIGHTUP, RIGHTDOWN
The key codes maybe found in this post or here. Maybe I'll manage to fool SDL with redefining the arrow-keys with opie-keyz.

I use this script to run snes9x and set everything to my taste (almost). I also found these additional switches:
-nso = no sound
-dfr = show frame rate.

Monday, June 18, 2007

Backgammon

Installed opie-backgammon - for those boring moments...

# ipkg install -d loop0 opie-backgammon
# ipkg-link add opie-backgammon
opie-backgamon, like knights suffers from the small window problem, I wonder if there is a way to fix it...

Tuesday, June 5, 2007

FLITE (Text-To-Speech)

I am writing an application for my new GPS (see previous post). In order to have voice output from the Zaurus I have installed FLITE,

# ipkg install flite -d loop0
# ipkg-link add flite; ipkg-link add libflite-cmu-us-kal1; ipkg-link add libflite1
Install a higher quality voice,
# ipkg install libflite-cmu-us-kal16-1 -d loop0
# ipkg-link add libflite-cmu-us-kal16-1
To replace the new voice with the old one replace the following symlink (in the /usr/lib directory),
# mv libflite_cmu_us_kal.so.1 libflite_cmu_us_kal.so.1.lowfreq
# ln libflite_cmu_us_kal16.so.1 libflite_cmu_us_kal.so.1 -s
To test flite simply run,
# flite -t "Hello world"
While we are at it, opie-reader can be setup to read text using flite. First install the opie-reader flite plugin,
# ipkg install opie-reader-output-flitecmd -d loop0
# ipkg-link add opie-reader-output-flitecmd
Now, in opie-reader under "Settings", select the "Scroll" tab. Under "Scroll type" select "Send to output" and under "Output" select "flitecmd". To start reading just start scrolling (Navagation->Scroll).
A word of warning; a. It takes couple of seconds before output starts, and b. The speech cannot be interrupted (as far as I found), opie-reader sends a full paragraph to flite, if you want to stop it - stop the scroll ONCE and wait... (I highly recommend putting a button in the toolbar)

Thursday, May 10, 2007

Global Positioning System (GPS)

I bought a Royaltek RBT-1000 GPS. This is a little (60gr) bluetooth GPS reciever. Connecting it to the Zaurus was really easy (mainly following this ipaq bluetooth gps howto),

  1. Turn the GPS and Zaurus on.
  2. Insert bluetooth CF. I found out that if the Zaurus was suspended with the bluetooth card inserted I had to restart the CF card with,
    #cardctl eject; cardctl insert
  3. Edit /etc/bluetooth/rfcomm.conf,
  4. Bind the dev (If the bind option is disabled).,
    # rfcomm bind /dev/rfcomm0
  5. To see the raw feed,
    # cat /dev/rfcomm0
  6. Start gpsd, this daemon gives a simpler interface to the gps feed, qpegps and (I think) roadmap use it to recieve data from the gps.
    #gpsd -f /dev/rfcomm0
    adding the -n switch turns on the bluetooth immidiatly and leaves it on (even if there is no active connection) otherwise gpsd closes the bluetooth after the connection was closed. This is good if I want to recive data using a command line script like (thanx ckuethe),
    #echo "0" | nc localhost 2947
    This will spit out the position and velocity information.
  7. Connecting to gpsd using telnet,
    # telnet localhost 2947
    there several commands that are documented in the gpsd manpage.
  8. roadmap gps terminal seems to work out of the box,
    # roadgps
    but gives very limited information (only satellite constellation and signal strength).
That was the easy part. roadmap started ok only if I start it from the map folder (where usdir.rdm exists) managed to connect to the gps, but it doesn't show the map (which I got from freemap.co.il). qpegps started ok, but couldn't connect to gpsd which makes it useless.

Thursday, May 3, 2007

bluetooth...

I'm trying to connect my Motorola RAZR V3 using a bluetooth connection. This is what I found to be semi-successful:
On cellphone side:

  1. Enable bluetooth connection.
  2. Enable detection.
On the zaurus side:
  1. Set the pin number:
  2. # echo "0000" > /etc/bluetooth/pin
  3. create the script /usr/bin/bluepincat.sh
    #!/bin/sh
    echo -n "PIN:"
    cat /etc/bluetooth/pin


    Alternatively In Bluetooth Manager (under the Settings tab), uncheck "enable authentification" and "enable encryption", and set the Default Passkey to "0000", this seems to work aswell.

  4. In /etc/bluetooth/hcid.conf, change security from user to auto.
    also change the PIN helper to pin_helper /usr/bin/bluepincat.sh;

  5. Restart the bluetooth service:
    # /etc/init.d/bluetooth stop; /etc/init.d/bluetooth start
Now I can do:
# hcitool inq
and I see the information about the cellphone.
# sdptool browse MAC_ADDRESS
and I see a list of services - with gibberish titles... but list of them nonetheless...

This concludes it, I cannot send files to the cellphone. When I try sending files from the cellphone to the Zaurus I receive a "Service Not Supported" error.

Wednesday, May 2, 2007

zRoadMap again

I've found Wendell Turner's Sharp Zaurus ipk, and installed it:

# ipkg install -d loop0 /media/card/zroadmap_1.0.12-r2_arm5te.ipk
# ipkg-link add kernel-module-usbcore-2.6
# ipkg-link add kernel-module-usbkbd-2.6
# ipkg-link add kernel-module-usbmouse-2.6
# ipkg-link add usbutils
# ipkg-link add zroadmap
after copying the files from /opt/QtPalmtop/share/roadmap to ~/.roadmap/
# cp /opt/QtPalmtop/share/roadmap/* ~/.roadmap/
and starting roadmap from ~/.roadmap:
# cd ~/.roadmap
# roadmap
But there is still the issue of getting maps....

Tuesday, May 1, 2007

qpeGPS & zRoadMap

Install qpegps:
first, install gpsd:

# ipkg install gpsd -d loop0
# ipkg-link add gpsd
Then libgps14:
# ipkg install libgps14 -d loop0
# ipkg-link add libgps14
Then qpe:
# ipkg install qpegps -d loop0
# ipkg-link add qpegps
In order for the map download to work, downmap and gif2png needed to be extracted into /opt/QtPalmtop/bin
wget is needed to be installed (apparently the busybox version is not compatible with downmap)
# ipkg install wget -d loop0
# ipkg-link add wget
Now I'll try to download Haifa area maps... this takes some time (24 maps are downloaded)

Apperantly the popup menu doesn't work... :-(

zroadmap
I'll try my luck with zroadmap:
# ipkg install -d loop0 zroadmap
# ipkg-link add zroadmap

It seems that the directories are not configured well, roadmap searches for the file usdir.rdm which I found in /opt/QtPalmtop/share/roadmap/, once I started roadmap from this directory it started ok (but no maps...).
No luck finding maps, So I removed it
# ipkg-link remove zroadmap
# ipkg remove zroadmap

Friday, March 30, 2007

QPDF2 - pdf reader for OPIE

Install QPDF2:

# ipkg install qpdf2 -d loop0
# ipkg-link add qpdf2; ipkg-link add t1lib

Works out of the box

Saturday, March 10, 2007

Links

I've added some links to the files I've used in the last post

Friday, March 9, 2007

Reflash OZ3.5.4.1

GPE fail to load, so I decided to reflash the whole thing.

Before reflashing, I moved the root folder to root.old.

# mv /home/root /home/root.old
Downloaded the OpenZaurus 3.5.4.1 OPIE Image from ewi546.ewi.utwente.nl mirror and followed the OpenZaurus C7x0/Install Howto.


Loop0 Image:

I have an image on the SD. To create one (512MB):
# dd if=/dev/zero of=ext2.img bs=1024 count=512000
Format the image as ext2: # mkfs.ext2 /media/card/images/loop0.imgCreate a directory to accommodate the mount:
# mkdir /media/loop0
to manually mount the image:
# mount -t ext2 -o loop /media/card/images/loop0.img /media/loop0
add it to fstab so it will be auto-mounted upon reboot, add the following line at the end of /etc/fstab:
/media/card/images/loop0.img /media/loop0 ext2 loop,rw 0
This can be verified by:
# mount /media/loop0
Exit OPIE:
# /etc/init.d/opie stop
Move /home/ and /opt/ directories to loop0:
# mkdir /media/loop0/home
# mv /home/root /media/loop0/home

# ln /media/loop0/home/root /home/root -s

# mv /opt /media/loop0/
# ln /media/loop0/opt /opt -s
Restart OPIE
# /etc/init.d/opie start

Configure USB networking:
I use this Windows XP driver for USB networking (I tried this only with OpenZaurus on Windows XP). Some times the driver crashes, I then reenable USB from the Zaurus side (see below)... sometimes I have to reboot windows...
Zaurus Side (usb0):
ip: 192.168.0.100
Subnet Mask: 255.255.255.0
Gateway: 192.168.0.1
DNS: 192.168.1.1
PC Side:
Make sure the IP 192.168.0.1 is free.
In network settings, advanced tab, enable internet sharing with the Zaurus interface.
settings:
ip: 192.168.0.1
Subnet Mask: 255.255.255.0
Gateway: 192.168.0.100
DNS: 192.168.1.1

EnableUSB:
Create the script enableUSB.sh:
#! /bin/sh
# Check if usb storage module is loaded, if it does remove it.
if ["`lsmod | grep g_file_storage`" != "" ]; then
echo g_file_storage is loaded
echo Unloading g_file_storage
rmmod g_file_storage
fi

# Check if usb networking module is loaded, if it does remove it.
if ["`lsmod | grep g_ether`" != "" ]; then
echo Stopping USB networking module...
echo Unloading g_file_storage
rmmod g_ether
fi

#Load USB networking module:
echo Starting USB networking module...
modprobe g_ether

#Enable the network interface.
echo Bringing up network interface:
ifup usb0
Enable networking
# /media/card/myScripts/enableUSB.sh
To automatically enable networking on reboot:
# ln -s /media/card/myScripts/enableUSB.sh /etc/rcS.d/S49local
For ssh to work a password must be set:
# passwd
Now ssh can connect to the Zaurus from the host computer.

Install to loop0:
In order for ipkg to be able to install packages to loop0 (using the -d loop0 switch) it must be mounted using the ipkg-link, at the end of /etc/ipkg.conf add:
dest loop0 /media/loop0/packages/


Timezone
First, update ipkg:
# ipkg update
Install timezones-asia:
# ipkg install -d loop0 timezones-asia
# ipkg-link add timezones-asia
For some reason /etc/profile does not search for ~/.profile to fix it I added before the export line:
if [ -e "$HOME/.profile" ]; then
. $HOME/.profile
fi
Set the local timezone in ~/.profile
export TZ="Asia/Jerusalem"
Update the clock:
# ntpdate nist1.datum.com

Install
mplayer
# ipkg install -d loop0 mplayer
# ipkg-link add liblzo1; ipkg-link add libmad0; ipkg-link add libmp3lame0; ipkg-link add libsdl-1.2-0; ipkg-link add mplayer; ipkg-link add mplayer-common
The mplayer from the feed is missing the font files (maybe the local fonts can be used...) to have OSD mplayer fonts should be copied to ~/.mplayer/fonts.
Key binding can be configured in input.conf. To see a list of available commands run:
# mplayer -input cmdlist
to see a list of keys:
# mplayer -input keylist
I'm using mpfsr.sh script to run mplayer:
#! /bin/sh

if [ "$1" = "" ]; then
echo "Please supply filename"
else
#disable screen saver and autosleep:
qcop QPE/System 'setScreenSaverMode(int)' 2
qcop QPE/System 'setScreenSaverIntervals(int,int,int)' 0 0 0

#change resolution to 240x320:
fbset -n -xres 240 -yres 320 -match;

#Invert rotation, for some reason with default rotation SDL runs upside down. and then start mplayer:
SDL_QT_INVERT_ROTATION=1 mplayer $@

#change resolution back to normal:
fbset -n -xres 640 -yres 480 -match;

#enable screensaver and autosleep:
qcop QPE/System 'setScreenSaverIntervals(int,int,int)' -1 -1 -1
qcop QPE/System 'setScreenSaverMode(int)' 100

#Update the screen otherwise the screen remains black.
qcop "QPE/System" "applyStyle()";
fi

Add MyScripts and MyApps tabs:
tabs are directories under /opt/QtPalmtop/apps, so to create new tabs:
# mkdir /opt/QtPalmtop/apps/myApps
# mkdir /opt/QtPalmtop/apps/myScripts

A .directory file is also needed to be created for both directories:
[Desktop Entry]
File=/opt/opie/apps/myApps/.directory
Icon=myAppsIcon
Type=application/octet-stream
Name=MyApps
Restart OPIE for the changes to take effect:
# /etc/init.d/opie stop
# /etc/init.d/opie start
Install BASH:
# ipkg install -d loop0 bash
# ipkg-link add bash
The default shell cannot be changed in /etc/passwd, but I can add to ~/.profile:
exec /bin/bash
which will do the trick this is a very bad solution.

To disable the history file, add to .bashrc:
unset HISTFILE

Install less:
less is much better than more...
# ipkg install -d loop0 less
# ipkg-link add less

Install opie-autorotateapplet
I don't like the autorotation feature, and I think it causes problems when closing the hinge, this applet can disable/enable the autorotation "feature"
# ipkg install -d loop0 opie-autorotateapplet
# ipkg-link add opie-autorotateapplet
Install opie-reader
# ipkg install -d loop0 opie-reader
# ipkg-link add opie-reader; ipkg-link add opie-reader-codec-aportis; ipkg-link add opie-reader-codec-arrierego; ipkg-link add opie-reader-codec-chm; ipkg-link add opie-reader-codec-isilo; ipkg-link add opie-reader-codec-plucker; ipkg-link add opie-reader-codec-ppms; ipkg-link add opie-reader-codec-reb; ipkg-link add opie-reader-codec-weasel; ipkg-link add opie-reader-filter-htmlfilter
Hebrew fonts
Install unicode which includes also hebrew fonts:
# ipkg install -d loop0 qte-font-unifont-160
# ipkg-link add qte-font-unifont-160;
ipkg-link add qpf-font-common

Install ZKBApplet
# ipkg install -d loop0 opie-zkbapplet
# ipkg-link add opie-zkbapplet
ZKBApplet requires a XML file with the key definitions. this file should be placed in /opt/QtPalmtop/share/zkb/.

Install opie-clipboardapplet:
# ipkg install -d loop0 opie-clipboardapplet
# ipkg-link add opie-clipboardapplet

Disable LCD Softkeys:
Mark out the entries for the LCD Softkeys in /etc/keymap-2.6.map (lines 121-131).
reboot for the changes to affect.


Install opie-networkapplet

# ipkg install -d loop0 opie-networkapplet
# ipkg-link add opie-networkapplet
Couldn't make this to work...

Install opie-memoryapplet
# ipkg install -d loop0 opie-memoryapplet
# ipkg-link add opie-memoryapplet

Install ScummVM-qpe:

Using the version from the old (OZ3.5.4) feed, all other versions seem to have a problem with the menu key (not working):
# ipkg install -d loop0 /media/card/scummvm-qpe_0.6.1b-r0_arm.ipk
# ipkg-link add libmpeg2; ipkg-link add libogg0; ipkg-link add libvorbisidec1; ipkg-link add scummvm-qpe
At the beginning the cursor is a bit off, to fix that, choose "Fix aspect ratio" under options (in the main screen).
A newer version is installed later


Install Knights
Knights is a front end for the Phalanx chess engine.
# ipkg install -d loop0 knights
# ipkg-link add knights; ipkg-link add phalanx

Tuesday, March 6, 2007

Continue with freeciv...

I stopped compiling last night, today when I tried to continue I got the following error:

install: cannot stat `/stuff/tmp/work/all-linux/ttf-dejavu-2.13-r0/dejavu-ttf-2.13/*.ttf': No such file or directory
when trying to install ttf-deavu-2.13-r0. The problem is probably a defective /stuff/sources/dejavu-ttf-2.13.tar.bz2. Removed that file (and also its md5 counterpart). And then:
# bitbake -crebuild ttf-dejavu
This caused bitbake to download the file again and to build it ok. Continue with freeciv:
# bitbake freeciv

Now it failed with gtk+:
***Can't link to Pango. Pango is required to compile
*** GTK+...
According to /stuff/tmp/work/armv5te-linux/gtk+-2.8.9-r7/gtk+-2.8.9/config.log cairopango-1.0 library is missing...


Monday, March 5, 2007

Statistics

I subscribed to Google Analytics to get some statistics about the blog.

Bug #1940

bitbake failed compiling libX11 with the following error, with makekeys causing floating point exception. Somebody just posted a fix in the OE Bugtracker.

So I'll try to continue...
To fix the bug I edit: /stuff/tmp/work/armv5te-linux/diet-x11-X11R7.1-1.0.1-r4/libX11-X11R7.1-1.0.1/src/util/makekeys.c
and change

KeySym val;
} info[KTNUM];

#define MIN_REHASH 10
#define MATCHES 10

char tab[KTNUM];
to

KeySym val;
} info[KTNUM];

#define MIN_REHASH 15
#define MATCHES 10

char tab[KTNUM];
I created a /stuff/setVars to setup the enviroment, with the two export command in it:
export PATH=/stuff/bitbake/bin:$PATH
export BBPATH=/stuff/build:/stuff/org.openembedded.dev

Now bitbake:
# cd /stuff/
# . setVars
# bitbake freeciv
This fixed the problem.

Saturday, March 3, 2007

Trying to compile freeciv for OZ

I want to compile FreeCiv for the Zaurus:

  • Set local configuration (/stuff/build/conf/local.conf), change/insert the following lines:
    • DL_DIR = "/stuff/sources"
    • BBFILES := "/stuff/org.openembedded.dev/packages/*/*.bb"
    • MACHINE = "c7x0"
    • DISTRO = "openzaurus-unstable"
    • ASSUME_PROVIDED += "qemu-native"
    • Remove the last line in the file.
  • Setup the enviroment:
# export PATH=/stuff/bitbake/bin:$PATH
# export BBPATH=/stuff/build:/stuff/org.openembedded.dev
  • Try to compile:
# bitbake freeciv
  • No luck today - bitbake failed.

Friday, March 2, 2007

Created YoGZLog

Wandered around google and stumbled upon this place...
Maybe I'll use it for my Zaurus log...