Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > More E-Book Readers > iRex > iRex Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 11-02-2006, 11:00 AM   #1
Antartica
Evangelist
Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.Antartica ought to be getting tired of karma fortunes by now.
 
Antartica's Avatar
 
Posts: 423
Karma: 1517132
Join Date: Jun 2006
Location: Madrid, Spain
Device: quaderno, remarkable2, yotaphone2, prs950, iliad, onhandpc, newton
An idea to mitigate boot time (and app launch time) -- For future use

Hi all. The idea follows:

1. Have all book-reading type apps cache not only one page, but five (the previous page, the current page, and the three next pages)
2. When you exit a book-reading app, write to disk a mng (png-multi-image file) with the 4-bit images of the cached pages.
3. The last viewer used app puts a file in /mnt/free/ whose contents specify the path and name of the saved mng file
4. Do a small kernel module that, at boot, as soon as the disk and the filesystem has been initialized (or reading it "by hand" --after all, it's FAT), reads the file and lets the user browse it with the flipbar (and in screen there would be no pageBar, no icon bar, just the text...) while the O.S. is finishing the initilization.
5. At viewer launch, if a corresponding mng file to the selected document exists, do the same, while the viewer is launching and loading the selected file.

With this in place, the slow startup would not be a problem for book-reading (although it doesn't resolve the usage scenarios of note-taking and of consulting a note).

I can volunteer for the kernel part, but we need the kernel sources and some way to update the kernel in the iliad...

Last edited by Antartica; 11-02-2006 at 11:03 AM.
Antartica is offline   Reply With Quote
Old 11-02-2006, 03:07 PM   #2
scotty1024
Banned
scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.
 
Posts: 1,300
Karma: 1479
Join Date: Jul 2006
Location: Peoples Republic of Washington
Device: Reader / iPhone / Librie / Kindle
My thoughts have been along these lines.

ContentLister needs to be the UI for paging/rotating/zooming/tabbing.

It has a plug in capability for: PDF, DJVU, HTML, TXT, File Selection (existing content lister function), etc...

You launch one app and it loads shared libraries as needed to render content. Content is tabbed.

The new app has a concept of "session" which is persistent. The page image cache could indeed be part of this persistent session state. But for file formats such as DJVU they can re-render a page faster than you can read it from the iLiad's slow storage.

The plugins would self configure via a defined API call: extensions, icons etc...

One big help on startup time would be to shoot X and use Pango/Cairo in a direct frame buffer mode. This would also reduce memory foot print in the new ContentLister and reduce screen update latency.

I would also eliminate the existing UDP service for erasing the screen. I'd just have ioctl calls into the kernel, extending /dev/fb0 sounds reasonable to me (I suspect it already is). One less service to start, one less set of sockets to open in each app, way less overhead in the communication of the erase requests.
scotty1024 is offline   Reply With Quote
Advert
Old 11-02-2006, 03:50 PM   #3
Malder1
Connoisseur
Malder1 began at the beginning.
 
Posts: 52
Karma: 10
Join Date: Aug 2006
Yesterday I though about exactly similar idea!

Please write about your idea on iRex forum and send copy to techsupport@
Malder1 is offline   Reply With Quote
Old 11-02-2006, 04:04 PM   #4
scotty1024
Banned
scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.
 
Posts: 1,300
Karma: 1479
Join Date: Jul 2006
Location: Peoples Republic of Washington
Device: Reader / iPhone / Librie / Kindle
iRex can polish the boot time with a few trivial changes.

in /home/root/start.sh:
Change "/usr/bin/do_updates.sh" to ". /usr/bin/do_updates.sh".

This removes the expense of launching another shell to run the do_updates.sh. (of course if you're running hacker mode, you've already commented it out )

iRex could also do a few things to speed up do_updates.sh.

Existing:

Code:
# Convert the sysset area (if needed)
sysset_layout=`sysset -r -b -a 0 -l 1 | cut -c '3-'`
if [ "$sysset_layout" = "01" ]
then
    sysset_convert_01_02.sh
fi

sysset_layout=`sysset -r -b -a 0 -l 1 | cut -c '3-'`
if [ "$sysset_layout" = "02" ]
then
    sysset_convert_02_03.sh
fi
Faster, removes launching 3 processes.

Code:
# Convert the sysset area (if needed)
sysset_layout=`sysset -r -b -a 0 -l 1`
if [ "$sysset_layout" = "0x01" ]
then
    sysset_convert_01_02.sh
fi
if [ "$sysset_layout" = "0x02" ]
then
    sysset_convert_02_03.sh
fi
scotty1024 is offline   Reply With Quote
Old 11-02-2006, 04:31 PM   #5
scotty1024
Banned
scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.
 
Posts: 1,300
Karma: 1479
Join Date: Jul 2006
Location: Peoples Republic of Washington
Device: Reader / iPhone / Librie / Kindle
They could also speed the boot with this change:

Code:
# Temporary fix to show the WiFi mac address to the user
if [ ! -e /mnt/free/wlan_mac.txt ]
then
    modprobe cf8385 2>/dev/null
    echo "WiFi card MAC address:" > /mnt/free/wlan_mac.txt
    ifconfig wlan0 | awk '$4 ~ /HWaddr/ { mac = $5; gsub(/:/, "-", mac); print m
ac }' >> /mnt/free/wlan_mac.txt
/usr/bin/wireless.sh stop
fi

Last edited by scotty1024; 11-02-2006 at 04:34 PM.
scotty1024 is offline   Reply With Quote
Advert
Old 11-02-2006, 05:07 PM   #6
Malder1
Connoisseur
Malder1 began at the beginning.
 
Posts: 52
Karma: 10
Join Date: Aug 2006
Scotty,
Please can you say expected time before (40 seconds?) and after this optimization?
Also send it to iRex.

And please send them your finding about improvement of text rendering in PDF. I still should use my utility that renders text to bitmaps and then packs to PDFs.
Malder1 is offline   Reply With Quote
Old 11-02-2006, 05:30 PM   #7
arivero
Guru
arivero knows what time it isarivero knows what time it isarivero knows what time it isarivero knows what time it isarivero knows what time it isarivero knows what time it isarivero knows what time it isarivero knows what time it isarivero knows what time it isarivero knows what time it isarivero knows what time it is
 
arivero's Avatar
 
Posts: 607
Karma: 2157
Join Date: Oct 2005
Device: NCR3125, Nokia 770,...
Quote:
Originally Posted by scotty1024
One big help on startup time would be to shoot X and use Pango/Cairo in a direct frame buffer mode.
I'd vote for the survival of X. True, it has always been a performance eater, but its existence does the iLiad more valuable.
arivero is offline   Reply With Quote
Old 11-02-2006, 11:29 PM   #8
scotty1024
Banned
scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.
 
Posts: 1,300
Karma: 1479
Join Date: Jul 2006
Location: Peoples Republic of Washington
Device: Reader / iPhone / Librie / Kindle
Quote:
Originally Posted by arivero
I'd vote for the survival of X. True, it has always been a performance eater, but its existence does the iLiad more valuable.
How about shoot X and only start it for things like the x48 calculator?
scotty1024 is offline   Reply With Quote
Old 11-02-2006, 11:33 PM   #9
scotty1024
Banned
scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.
 
Posts: 1,300
Karma: 1479
Join Date: Jul 2006
Location: Peoples Republic of Washington
Device: Reader / iPhone / Librie / Kindle
Quote:
Originally Posted by Malder1
Scotty,
Please can you say expected time before (40 seconds?) and after this optimization?
Also send it to iRex.

And please send them your finding about improvement of text rendering in PDF. I still should use my utility that renders text to bitmaps and then packs to PDFs.
iRex is fully aware of everything I'm doing, well, they haven't heard about x48 yet...

In any case, they will do as they wish.
scotty1024 is offline   Reply With Quote
Old 11-03-2006, 06:56 PM   #10
scotty1024
Banned
scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.
 
Posts: 1,300
Karma: 1479
Join Date: Jul 2006
Location: Peoples Republic of Washington
Device: Reader / iPhone / Librie / Kindle
In case no one has seen it, this is what the iLiad's boot looks like from the system log perspective.

[code]Oct 17 02:47:46 ereader syslog.info syslogd started: BusyBox v1.01 (2006.07.31-1
4:32+0000)
Oct 17 02:47:47 ereader daemon.info cardmgr[234]: executing: 'modprobe cf8385 2>
&1'
Oct 17 02:47:47 ereader daemon.info cardmgr[234]: + Using /lib/modules/2.4.19-rm
k7-pxa2-irex1/kernel/drivers/pcmcia/cfio.o
Oct 17 02:47:47 ereader user.warn kernel: Before calling register_pccard_driver
Oct 17 02:47:47 ereader user.warn kernel: After calling register_pccard_driver
Oct 17 02:47:47 ereader daemon.info cardmgr[234]: + Using /lib/modules/2.4.19-rm
k7-pxa2-irex1/kernel/drivers/pcmcia/cf8385.o
Oct 17 02:47:47 ereader user.warn kernel: Entering cf_attach()
Oct 17 02:47:47 ereader user.warn kernel: Before registering the client
Oct 17 02:47:47 ereader user.warn kernel: Resetting WLAN.
Oct 17 02:47:47 ereader user.warn kernel: BasePort1=0xf7000000, AssignedIRQ=68
Oct 17 02:47:48 ereader user.warn kernel: After calling wlan_add_card function
Oct 17 02:47:48 ereader user.warn kernel: Leaving cf_attach()
Oct 17 02:47:50 ereader daemon.info cardmgr[234]: executing: './network start wlan0 2>&1'
Oct 17 02:47:50 ereader daemon.info cardmgr[234]: + Default Config
Oct 17 02:47:50 ereader daemon.info cardmgr[234]: + /sbin/iwconfig wlan0 mode Managed
Oct 17 02:47:51 ereader daemon.info cardmgr[234]: + /sbin/iwconfig wlan0 rate auto
Oct 17 02:47:51 ereader daemon.info cardmgr[234]: + /sbin/iwconfig wlan0 essid "any"
Oct 17 02:47:54 ereader daemon.info cardmgr[234]: + Error for wireless request "Set ESSID" (8B1A) :
Oct 17 02:47:54 ereader daemon.info cardmgr[234]: + SET failed on device wlan0 ; Network is down.
Oct 17 02:47:54 ereader daemon.info cardmgr[234]: + Sample private network setup
Oct 17 02:47:58 ereader user.info kernel: hal_pxa250.c: 1362-hal Initialization Success
Oct 17 02:47:59 ereader user.warn kernel: td_cache = c02f59f0
Oct 17 02:47:59 ereader user.warn kernel: ed_cache = c02f5a60
Oct 17 02:47:59 ereader user.info kernel: usb.c: new USB bus registered, assigned bus number 1
Oct 17 02:47:59 ereader user.info kernel: hub.c: USB hub found
Oct 17 02:47:59 ereader user.info kernel: hub.c: 2 ports detected
Oct 17 02:47:59 ereader user.warn kernel: USB HAL: HC suspend
Oct 17 02:47:59 ereader user.info kernel: usb_phci.c: usb-phci Initialization Success
Oct 17 02:47:59 ereader user.info kernel: SCSI subsystem driver Revision: 1.00
Oct 17 02:47:59 ereader user.info kernel: Initializing USB Mass Storage driver...
Oct 17 02:47:59 ereader user.info kernel: usb.c: registered new driver usb-storage
Oct 17 02:47:59 ereader user.info kernel: USB Mass Storage support registered.
Oct 17 02:48:01 ereader user.warn kernel: VFS: busy inodes on changed media.
Oct 17 02:48:03 ereader user.warn kernel: MMC:Configured GPIO 07 (SDD) as input.
Oct 17 02:48:03 ereader user.warn kernel: MMC:Configured GPIO 73 (SDWP) as input.
Oct 17 02:48:03 ereader user.warn kernel: MMC:Configured GPIO 06 (SDCLK) to alternate function 1.
Oct 17 02:48:03 ereader user.warn kernel: MMC:Configured GPIO 08 (CS) as output.
Oct 17 02:48:03 ereader user.info kernel: mmca1
Oct 17 02:48:03 ereader user.warn kernel: MSDOS FS: IO charset utf8
Oct 17 02:48:04 ereader user.warn kernel: USB HAL: DC suspend
Oct 17 02:48:04 ereader user.info kernel: usb_pdc.c: usb-pdc Initialization Success
Oct 17 02:48:04 ereader user.info kernel: pdc_bus.c: Registered Driver devmscd
Oct 17 02:48:04 ereader user.info kernel: devmscd.c: devmscd Initialization Success
Oct 17 02:48:04 ereader user.err kernel: wlan0 (WE) : Buffer for request SIOCGIW
PRIV too small (16<75)
Oct 17 02:48:04 ereader user.err kernel: wlan0 (WE) : Buffer for request SIOCGIW
PRIV too small (32<75)
Oct 17 02:48:04 ereader user.err kernel: wlan0 (WE) : Buffer for request SIOCGIW
PRIV too small (64<75)
Oct 17 02:48:04 ereader user.warn kernel: Before calling wlan_remove function
Oct 17 02:48:04 ereader user.warn kernel: After calling wlan_remove function
Oct 17 02:48:05 ereader user.notice net.agent[688]: unregister event not handled
Oct 17 02:48:13 ereader user.warn kernel: einkfb: einkfb_ioctl enter[code]

The above log covers the time for the below code in the /home/root/start.sh to execute.

Code:
/sbin/syslogd
export DISPLAY=:0
export LD_LIBRARY_PATH=/usr/lib/mozilla-minimo
export MOZILLA_FIVE_HOME=/usr/lib/mozilla-minimo
export HOME=/home/root
export MBPIXBUF_FORCE_32BPP_INTERNAL=1
/usr/bin/displayMgr -p -w /var/waveform.bin&
/usr/bin/erbusyd &
/usr/bin/Xfbdev -screen 768x1024x8 -3button -dpi 160 -ac &
/usr/bin/matchbox-window-manager -use_titlebar no -use_cursor no &
/usr/bin/pageBar&

# start toolbar and wait till it runs
/usr/bin/matchbox-panel --size 39 --no-menu --bgcolor White --no-session --default-apps mb-applet-icon-container &
app=mb-applet-icon-container
echo "Waiting for $app ..."
rip=10
while [ $rip -gt 0 ]
do
    sleep 1
    n=`ps | awk "BEGIN              { n = 0   }
                 \\$5 == \\"$app\\" { n++     }
                 END                { print n }"`
    if [ $n -eq 0 ]
    then
        rip=$((rip-1))
    else
        rip=0
    fi
    echo -n .
done
echo "... wait done"

/usr/bin/contentLister --sync &
/usr/bin/powerMgr&
modprobe phci
modprobe usb-storage
/etc/init.d/hotplug start
modprobe mscd
msdisk &

# Temporary fix to show the WiFi mac address to the user
if [ ! -e /mnt/free/wlan_mac.txt ]
then
    echo "WiFi card MAC address:" > /mnt/free/wlan_mac.txt
    ifconfig wlan0 | awk '$4 ~ /HWaddr/ { mac = $5; gsub(/:/, "-", mac); print mac }' >> /mnt/free/wlan_mac.txt
fi

/usr/bin/wireless.sh stop
Total time roughly 25 seconds.

Out of that 25 seconds they spend at least 9 seconds powering up and shutting down the WLAN.

I don't know about all of you, but I'd like those 9 seconds back.
scotty1024 is offline   Reply With Quote
Old 11-03-2006, 07:47 PM   #11
NatCh
Gizmologist
NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.
 
NatCh's Avatar
 
Posts: 11,615
Karma: 929550
Join Date: Jan 2006
Location: Republic of Texas Embassy at Jackson, TN
Device: Pocketbook Touch HD3
Quote:
Originally Posted by scotty1024
Out of that 25 seconds they spend at least 9 seconds powering up and shutting down the WLAN.
Wouldn't that pretty much garauntee that the FAA will never approve the thing for use on planes? Or am I mis-interpreting?
NatCh is offline   Reply With Quote
Old 11-03-2006, 11:14 PM   #12
scotty1024
Banned
scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.
 
Posts: 1,300
Karma: 1479
Join Date: Jul 2006
Location: Peoples Republic of Washington
Device: Reader / iPhone / Librie / Kindle
Just don't turn it on during take off.

Actually I think we can get this fixed, I don't see any reason why the radio has to be turned on. Or the card be disturbed at all for that matter.

BUt I have other fish to fry the next two days.
scotty1024 is offline   Reply With Quote
Old 11-03-2006, 11:20 PM   #13
NatCh
Gizmologist
NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.NatCh ought to be getting tired of karma fortunes by now.
 
NatCh's Avatar
 
Posts: 11,615
Karma: 929550
Join Date: Jan 2006
Location: Republic of Texas Embassy at Jackson, TN
Device: Pocketbook Touch HD3
I thought they'd be upset having a wifi blaring at any point in the flight ....
NatCh is offline   Reply With Quote
Old 11-03-2006, 11:32 PM   #14
scotty1024
Banned
scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.scotty1024 is no ebook tyro.
 
Posts: 1,300
Karma: 1479
Join Date: Jul 2006
Location: Peoples Republic of Washington
Device: Reader / iPhone / Librie / Kindle
I'll admit I was a bit surprised when they told me it got turned on during the boot up and they then had to turn it back off.
scotty1024 is offline   Reply With Quote
Old 11-05-2006, 02:16 AM   #15
RibRdb2
Member
RibRdb2 began at the beginning.
 
Posts: 18
Karma: 10
Join Date: Jun 2006
They're loading modules? Wouldn't it be faster to compile it in to the kernel? Or is that some proprietary binary only driver?
RibRdb2 is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
iPad The Evolution of Time Magazine’s iPad App: Here’s What’s Next kjk Apple Devices 4 06-11-2010 07:43 PM
Any idea what time on Friday the IPAD goes on preorder krighton Apple Devices 7 03-12-2010 09:52 AM
Opus Opus Boot time Crusader Bookeen 2 12-26-2009 02:41 AM
PRS-600 cold boot and shutdown time kampang Sony Reader 0 08-28-2009 09:53 AM
Thoughts on Cybook freezing at boot time Ned Bookeen 16 05-07-2009 08:54 AM


All times are GMT -4. The time now is 04:31 PM.


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