Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > More E-Book Readers > iRex

Notices

Reply
 
Thread Tools Search this Thread
Old 12-24-2008, 02:36 PM   #16
phasesync
Junior Member
phasesync began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Dec 2008
Device: iRex DR1000S
I was able to compile the hello_world program via the shell (Debian on VMware). Copied the compiled program and a .desktop file on the DR (SD card) and it worked. I tried Anjuta/PokySDK but this gives me package requirements errors (gtk+-2.0, glib-2.0 not found). What am I doing wrong here?

Poky-qemu works perfectly with the iOn SDK.

Code:
> cd /usr/local/poky/eabi-glibc/arm
> source environment-setup
> poky-qemu zImage-2.6.23-qemuarm-xxx.bin poky-image-ion-devel-qemuarm-xxx.rootfs.ext2
The Home screen, a Settings option and a dialog pops up with "the battery is almost empty."

Tomek: Did you deploy the hello_world by copying it to the SD card?

I still don't know how to setup networking for the emulator and DR device. The Poky handbook contains information about QEMU/USB networking but I don't know if all is the same for iOn as it is for Poky... though iOn is 99% Poky right?

Last edited by phasesync; 12-26-2008 at 04:54 AM.
phasesync is offline   Reply With Quote
Old 12-25-2008, 07:34 AM   #17
phasesync
Junior Member
phasesync began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Dec 2008
Device: iRex DR1000S
In hello_world's configure.ac there is a PKG_CHECK_MODULES(DEPS, gtk+-2.0 >= 2.2 glib-2.0 >= 2.2).

Code:
>cd /usr/local/poky/eabi-glibc/arm
>source environment-setup
>cd ~/hello_world
>autoreconf --install
>./configure --host=arm-poky-linux-gnueabi
>make
works perfect (no dependency failures in config.log), though

Code:
>pkg-config --modversion gtk+-2.0
gives us version 2.12.7 which is less than 2.2, therefor I would suspect an error/warning like I get using Anjuta.

To ./configure in Anjuta...

>anjuta hello_world.anjuta
>Edit->Preferences
added Poky SDK addon
configured cross-compiler options in Poky SDK
use a full poky tree -> /usr/local/poky/eabi-glibc/arm
toolchain triplet -> arm-poky-linux-gnueabi
use QEMU Device emulator
-> zImage-2.6.23.qemuarm-xxx.bin
-> poky-image-ion-devel-qemuarm-xxx.rootfs.ext2
> Build->Clean Project
> Build->Run Autogenerate
> Build->Run Configure

Uh oh...

[config.log]
configure:6697: checking for DEPS
configure:6705: $PKG_CONFIG --exists --print-errors "gtk+-2.0 >= 2.2 glib-2.0 >
= 2.2"
Package gtk+-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gtk+-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'gtk+-2.0' found
Package glib-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `glib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glib-2.0' found

which stops us from building the project :-(

Code:
> echo $PKG_CONFIG_PATH
/usr/local/poky/eabi-glibc/arm/arm-poky-linux-gnueabi/usr/lib/pkgconfig
Anjuta probably does not use the environment variables set by sourcing the environment-setup. Strangely the gtk and glib version numbers are less than expected if I'm not mistaken.

Last edited by phasesync; 12-26-2008 at 04:54 AM.
phasesync is offline   Reply With Quote
Advert
Old 12-25-2008, 07:53 AM   #18
phasesync
Junior Member
phasesync began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Dec 2008
Device: iRex DR1000S
Sometimes it is possible to overlook a little picture with settings ;-)

The following Poky SDK setting I had configured wrongly:

> use a full poky tree -> /usr/local/poky/eabi-glibc/arm

instead use the following as Adam showed us already in a snapshot of his Poky SDK settings:

> use an external toolchain -> /usr/local/poky/eabi-glibc/arm

I do like to know what the differences are between the the two possibilities.
phasesync is offline   Reply With Quote
Old 12-26-2008, 12:29 AM   #19
Tomek
Enthusiast
Tomek began at the beginning.
 
Posts: 29
Karma: 10
Join Date: Sep 2008
Location: USA
Device: Kindle DX
Quote:
Originally Posted by phasesync View Post
I tried Anjuta/PokySDK but this gives me package requirements errors (gtk+-2.0, glib-2.0 not found). What am I doing wrong here?
I was also getting similar errors when first trying to use Ubuntu 8.10 with Anjuata/PokyPlugin. The plugin was complaining about something so I tried building Anjuata from sources and started getting similar gtk+-2.0, glib-2.0 version errors. I finally tried the same on Ubuntu 8.04 and didn't get these problems. Here I didn't build anything from sources. Just installed Ubuntu 8.04, then prebuild anjuta and the plugin from the repositories and it just worked.

Quote:
Tomek: Did you deploy the hello_world by copying it to the SD card?
I have not copied it to the SD card. Once I had the hello_world project build and QEMU started, I selected "Tools->Run remote..." from Anjuta's menu. At that point "Command to run:" prompt come up where I typed: "hello_world", then it asked for root password which I quickly figured was simply "root" and then looking at QEMU I saw the hello_world app running. I don't have the actual DR1000s device so I have not deployed it to the real device, only to the emulator.

By the way, you can ssh into the IP address it shows when prompting for the root password and poke around the emulator's file system which I found helpful. In my case the IP address is setup to be 192.168.7.2 which I'm guessing is probably the same for everyone. Just make sure to ssh as root/root.
Tomek is offline   Reply With Quote
Old 12-26-2008, 12:59 AM   #20
Tomek
Enthusiast
Tomek began at the beginning.
 
Posts: 29
Karma: 10
Join Date: Sep 2008
Location: USA
Device: Kindle DX
Is it possible to read ebooks in QEMU? I'm not sure what would the best way to get the ebook to the image, but it looks like 'wget' is available so that would be one way. I can't figure out however where to place the content. I tried several places with a *.txt file but I never see it available from Menu->Open... in QEMU which always takes me to the "Settings" option.

For example, there is a /usr/share/uds/ebooks symlink that points to /media/mmcblk0p1/eBooks folder which doesn't exist by default. I created the folder and a test *.txt file there, but it still doesn't open.

I'm also curious if anyone here has tried developing a custom Universal Document Shell (UDS) plugin yet? I'm studying the examples and would love to be able to bounce ideas around, ask for help, and eventually help out other newcomers. Specifically, I haven't figured out yet what is the main entry point for the plugin? That is, what is the first function/method that is called by the UDS system? So far it looks like IPluginLibrary interface's "is_supported_document" may be up there near the top... but how does the system know about the new plugin? Does the plugin register somewhere?

Last edited by Tomek; 12-26-2008 at 01:12 AM.
Tomek is offline   Reply With Quote
Advert
Old 12-26-2008, 04:25 AM   #21
phasesync
Junior Member
phasesync began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Dec 2008
Device: iRex DR1000S
Quote:
Originally Posted by Tomek View Post
I'm not sure what would the best way to get the ebook to the image, option.
You can use SCP
Code:
> scp ~/hello_world/src/hello_world root@192.168.7.2:/tmp
Quote:
By the way, you can ssh into the IP address it shows when prompting for the root password and poke around the emulator's file system which I found helpful...
Nice job, yesterday I also noticed the same IP 192.168.7.2 address in Anjuta trying to "Tools->Deploy". I had to "apt-get install rsync" but after this it just gave me the unexplained error. Gladly I noticed a line in the Anjuta deployment output containing a line with "ssh".

> ssh -o "CheckHostIP no" -o "StrictHostKeyChecking no" -o "UserKnownHostFile /dev/null" -l root 192.168.7.2 rsync --vvlogDTpre.iL ./usr

I did the following things:

deb -> linux debian shell
emu -> qemuarm shell

Services running on the emu:
Code:
deb> nmap 192.168.7.2

PORT     STATE SERVICE
22/tcp   open  ssh          (dropbear ssh deamon)
111/tcp  open  rpcbind    (RPC program number mapper)
849/tcp  open  unknown 
856/tcp  open  unknown 
3632/tcp open  distccd    (distributed c/c++ compiler server)
4224/tcp open  xtell        (simple messaging server)
6000/tcp open  X11        (xserver)

deb> ssh 192.168.7.2 (logon with root as password)
emu> cd /
Filesystems on the emu
Code:
emu> mount

rootfs on / type rootfs (rw)
/dev/root on / type ext2 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
/dev/root on /dev/.static/dev type ext2 (rw)
tmpfs on /dev type tmpfs (rw)
devpts on /dev/pts type devpts (rw)
tmpfs on /var type tmpfs (rw)
tmpfs on /media/ram type tmpfs (rw)
To startup "hello_world" without Anjuta directly from the device
Code:
emu> export DISPLAY=192.168.7.2:0.0
emu> /tmp/hello_world
Create, format, copy card image
Code:
deb> dd if=/dev/zero of=/tmp/card-image count=20480
deb> mkfs card-image
deb> scp card-image root@192.168.7.2:/tmp/
From the emu shell it was not possible to format as ext2.

Quote:
For example, there is a /usr/share/uds/ebooks symlink that points to /media/mmcblk0p1/eBooks folder which doesn't exist by default. I created the folder and a test *.txt file there, but it still doesn't open.
It is possible to mount the card using a loopback device
Code:
emu> mkdir /media/mmcblk0p1
emu> mount -o loop=/dev/loop0 /tmp/card-image /media/mmcblk0p1/
emu> mkdir /media/mmcblk0p1/eBooks
After brutally killing the generic Xserver called "Xfbdev" and restarting the Xserver the "Document" folder appeared.
Code:
emu> ps
emu> kill [PID of Xfbdev]
emu> /etc/X11/Xserver
deb> scp poky-handbook.pdf root@192.168.7.2:/media/mmcblk0p1/eBooks
Now it is possible to get access to the card and open the PDF using QEMU (Xwindow).

Probably just creating a folder "/media/mmcblk0p1" and restarting the Xserver could work also.

Quote:
I'm also curious if anyone here has tried developing a custom Universal Document Shell (UDS) plugin yet? I'm studying the examples and would love to be able to bounce ideas around, ask for help, and eventually help out other newcomers. Specifically, I haven't figured out yet what is the main entry point for the plugin? That is, what is the first function/method that is called by the UDS system? So far it looks like IPluginLibrary interface's "is_supported_document" may be up there near the top... but how does the system know about the new plugin? Does the plugin register somewhere?
You, me and probably some other people seem to have the same goals. We will get there eventually

checkout http://developer.irexnet.com/pub/iOn/SDK/1.03/

Last edited by phasesync; 12-28-2008 at 06:17 AM.
phasesync is offline   Reply With Quote
Old 12-26-2008, 06:23 PM   #22
Tomek
Enthusiast
Tomek began at the beginning.
 
Posts: 29
Karma: 10
Join Date: Sep 2008
Location: USA
Device: Kindle DX
Quote:
Originally Posted by phasesync View Post
Probably just creating a folder "/media/mmcblk0p1" and restarting the Xserver could work also.
It does work and persists between Qemu restarts
Tomek is offline   Reply With Quote
Old 01-09-2009, 05:35 PM   #23
Tomek
Enthusiast
Tomek began at the beginning.
 
Posts: 29
Karma: 10
Join Date: Sep 2008
Location: USA
Device: Kindle DX
Has anyone figured out yet how to use a dictionary and writing on PDFs in QEMU? I can't get these to work. I can read the ebooks, I placed a DRM-free dictionary in /media/mmcblk01/System/Dictionaries and can open it as a book, but the dictionary lookup menu option remains disabled. I've been trying to develop a plugin that makes use of a dictionary, but I'm not sure if QEMU allows that functionality.
Tomek is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
DR1000 Public BETA of the DR1000S 2.0 software available rfog iRex 150 09-21-2010 12:00 PM
B&N new software development location Fbone News 1 08-25-2010 03:08 AM
I love my new DR1000S, thoughts & questions, 3rd Party Software Cliffe iRex 3 04-26-2009 10:02 AM
iRex DR1000 Software Development website vwinstead iRex 23 02-04-2009 12:21 PM


All times are GMT -4. The time now is 10:53 PM.


MobileRead.com is a privately owned, operated and funded community.