Re: Making a custom root FS
On Jun 23, 2008, at 3:36 AM, Frantisek Dufka wrote: > D. Scott Brown wrote: >> 3. extract the rootfs from the retail image, mount it, and tar it. >> If I mount the JFFS2 using kernel memory emulating a MTD, I get >> "error inserting mtdram - cannot allocate memory". If I mount the >> JFFS2 using block device emulating MTD, the tar fails with tons of >> read errors at byte 0. > > Check script and folowup posts here > http://www.internettablettalk.com/forums/showthread.php?p=192475#post192475 Thanks! I actually just needed to upgrade my linux kernel so that JFFS2 LZO compression was enabled. Once I switched to Edgy, it worked perfectly. Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
Making a custom root FS
I'm trying to create a custom flashable root fs, and the three documented approaches have not worked. I'm running out of ideas, and have emailed the list as a last resort. Here's what I've tried: 1. modify the developer rootfs. The last developer rootfs released was back at 3.1, and does not contain working wifi drivers for use on the N800 or N810. 2. create my own developer rootfs from scratchbox. The scripts for doing this were last updated back in maemo 2.x, and it's difficult to tell what the right way to go about this would be with the current sdk. 3. extract the rootfs from the retail image, mount it, and tar it. If I mount the JFFS2 using kernel memory emulating a MTD, I get "error inserting mtdram - cannot allocate memory". If I mount the JFFS2 using block device emulating MTD, the tar fails with tons of read errors at byte 0. I've tried the above on multiple versions of Ubuntu and computers, and errors are the same every time. Can you offer any guidance? Hopeful thanks, Scott References: http://maemo.org/development/documentation/how-tos/2-x/howto_use_flasher_rootfs.html http://maemo.org/community/wiki/modifyingrootimage/ https://wiki.maemo.org/Modifying_the_root_image ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
Developer rootfs for v3.1?
I checked http://tablets-dev.nokia.com/d1.php, but it doesn't look like a link to the 3.1 rootfs is up yet. Anyone know when / if this is coming? Many thanks, Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers
PIL and camera.py
The Python Bora tutorial indicates that JPEG saving was omitted from Elvis Pfutzenreuter's camera.py due to the absence of PIL. Thanks to the excellent efforts of Matt Croydon and the PyMaemo team, it looks like we now have PIL and thus JPEG support in Python 2.5.1. In camera.py example app, here's the spot to put code for saving the video buffer to a file: def buffer_cb(pad, buffer): # Here you have a chance to do something with the image buffer return True I can write the buffer directly to a file, and get something Photoshop can import as 16 bit RAW, but I'm having trouble getting PIL to work with it. I've tried lots of different arguments for Image.frombuffer(mode, size, data, "raw", mode, 0, 1), but most of what comes out is noise. Any suggestions? With hopeful thanks, Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://maemo.org/mailman/listinfo/maemo-developers
Re: maemo-developers Digest, Vol 24, Issue 41
The Camera API Example [1] states that JPEG's cannot be captured using Python because the N800 is lacking jpeglib bindings. Is this still true? What would be required to make them available? (Is Matt Croydon's porting of the Python Imaging Library [2] in any way related?) Any help would be appreciated. Thanks. I haven't seen the jpeglib bindings either, but I'd love to have them too. Is this a planned part of a future release of Python for Maemo? Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://maemo.org/mailman/listinfo/maemo-developers
Could not open the requested SVN filesystem
I'm trying to build a custom rootfs, and it looks like your SVN has died: https://stage.maemo.org/svn/integration/trunk/rootfs/ The tutorial I'm following (http://maemo.org/platform/docs/howtos/howto_use_flasher_rootfs.html) indicates that I need: make_rootimage.sh dlocate.sh droot.sh conf.sh strip.sh tar2jffs2.sh releasenotes.sh gconftool-wrapper ... in order to proceed. Is there a different place I should be looking for those files, or a more updated tutorial on how to proceed? Many thanks, Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://maemo.org/mailman/listinfo/maemo-developers
[maemo-developers] N800 / Python 2.5 / pygame performance regression
Python 2.5 with pygame is very choppy on my N800, compared to my 770 running the old Python 2.4 version. Here's a quick test application: http://dscottbrown.com/etc/animtest2.zip Tap the screen repeatedly to scroll the image. The difference is especially jarring if you set your 770 next to your N800, and tap both at once. Any ideas on this? Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://maemo.org/mailman/listinfo/maemo-developers
Re: [maemo-developers] Update on command line wifi connections
On Oct 11, 2006, at 1:47 AM, Patrik Flykt wrote: On Tue, 2006-10-10 at 16:21 -0400, ext D. Scott Brown wrote: Hmmm... then could we use gconf to write our own IAP configuration files from the command line, and then use the osso_iap_connect function to invisibly connect to the network we've created outside of the dialog? Yes, you could do exactly that. And if you want icd to automatically clean up the settings from gconf after disconnect, name it starting with '[EasyWLAN'. As an example select a new unsaved wlan SSID from the 'Select connection' dialog and do not let the UI save it. Watch the the gconf settings. I tried using the gconf bindings in Python, but it looks like they're not updated yet. Instead, I used the command line gconftool with -- dump and --load to set up new IAPs. The problem I'm hitting is EAP_wpa_preshared_key. I haven't been able to find anything online about converting a string password into the 32 byte int list in the gconf entry. It looks like some kind of encryption process happens between when a user types a WPA password in the dialog, and what's written into the gconf entry. Is there a command line tool or API for converting password strings into the preshared_key list format? Many thanks, Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://maemo.org/mailman/listinfo/maemo-developers
Re: [maemo-developers] Update on command line wifi connections
On Oct 10, 2006, at 8:34 AM, Patrik Flykt wrote: On Sat, 2006-10-07 at 15:17 -0400, ext D. Scott Brown wrote: As I understand it, you can connect to any arbitrary wifi network using this function from osso-ic.h: gint osso_iap_connect(const char *iap, dbus_uint32_t flags, void *arg); Unfortunately not. With the above function you can establish an internet connection using the name of the saved settings as the first argument. It is also possible to use any available connection by using the #define OSSO_IAP_ANY "[ANY]" from osso-ic.h. The settings are created either by selecting a WLAN network from the 'Select connection' dialog or the connectivity control panel applet. Settings are stored under '/system/osso/connectivit/IAP/' in gconf. See the end of the connectivity guide for gconf details. Hmmm... then could we use gconf to write our own IAP configuration files from the command line, and then use the osso_iap_connect function to invisibly connect to the network we've created outside of the dialog? Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://maemo.org/mailman/listinfo/maemo-developers
Re: [maemo-developers] Update on command line wifi connections
On Oct 8, 2006, at 6:22 AM, Matt Clark wrote: D. Scott Brown wrote: I've tried four methods limited or no success (see below for source and results), and I'm down to one last possibility. I don't have access to a linux box to test the real C API in osso-ic.h, and I would be happy to compensate any willing developer for his time if he can get this to work. There's probably a good reason why you haven't tried it, but ISTM that if you have an windows PC then you can have a linux box for $0: just download VMWare Server (it's completely free of charge), and install your favourite distro on it (Can't go far wrong with Ubuntu). For intel macs there's Parallels (not free but cheap). Alas, I'm on a pre-intel mac. One of my partners has an x86 machine and is setting up the environment now - I'll let the list know what we figure out. Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://maemo.org/mailman/listinfo/maemo-developers
[maemo-developers] Update on command line wifi connections
Here's what I'm trying to achieve: http://fuel5.com/connect.png I've tried four methods limited or no success (see below for source and results), and I'm down to one last possibility. I don't have access to a linux box to test the real C API in osso-ic.h, and I would be happy to compensate any willing developer for his time if he can get this to work. As I understand it, you can connect to any arbitrary wifi network using this function from osso-ic.h: gint osso_iap_connect(const char *iap, dbus_uint32_t flags, void *arg); Described here: http://www.maemo.org/platform/docs/howtos/ howto_connectivity_guide.html#InternetConnectivityAPI Can someone try writing a simple command line program that connects to the wifi network in a string parameter? Here's what I've tried on my own: I tried using dbus directly, but it fails for everything but get_statistics: #file: dbus_tester.py_ import dbus bus = dbus.SystemBus() obj = bus.get_object('com.nokia.icd', '/com/nokia/icd') iface = dbus.Interface(obj, 'com.nokia.icd') print iface.get_statistics() #below doesn't work #iface.connect('linksys',1) After re-reading the docs for the tenth time I noticed this sentence: "Applications should use the ICd D-BUS API only for statistics querying (get_statistics) and receiving IAP state change information (status_changed)." This might explain why the dbus calls won't, except that using osso fails the same way: #file: osso_tester.py_ import osso osso_c = osso.Context("osso_tester","0.0.1",False) print osso_c.rpc_run("com.nokia.icd", "/com/nokia/icd", "com.nokia.icd", 'get_statistics', wait_reply=True, use_system_bus=True) #below doesn't work: #print osso_c.rpc_run("com.nokia.icd", "/com/nokia/icd", "com.nokia.icd", 'connect', ('linksys',1), wait_reply=True, use_system_bus=True) I also tried using the linux wireless tools, but this doesn't appear to connect to anything: #___file: wifi_connect.sh_ sudo gainroot < /usr/sbin/iwconfig wlan0 essid $1 /usr/sbin/iwconfig wlan0 key $2 /usr/sbin/iwconfig wlan0 commit The only thing I've been able to get working is to use the connectivity_preload hack, but that pops up a system modal dialog with tiny fonts and the wrong orientation. #file: sock_tester.py_ import socket, os os.system('source /usr/bin/connectivity_preload.sh') s = socket.socket ( socket.AF_INET, socket.SOCK_STREAM ) s.connect(("www.google.com", 80)) My last ditch solution is to try creating a custom theme that makes the connect dialog full screen, with big fonts, and images that roughly match the link at the beginning of this message. It would be ugly and suck, but I'm out of ideas. Hope one of you can help, Scott ___ maemo-developers mailing list maemo-developers@maemo.org https://maemo.org/mailman/listinfo/maemo-developers
[maemo-developers] Initiating connections programatically
My team is developing an application that will be used by tech- clueless consumers. All data is displayed in a portrait screen orientation, and our application is intended to run directly from startup in place of the default Hildon launcher. Because of this, we need to provide our own UI for selecting a WLAN connection. We've tried using both LIBOSSO and Linux wireless tools without success. #libosso using python import osso osso_c=osso.Context("wifi","0.0.1",False) ret=osso_c.rpc_run("com.nokia.icd","/com/nokia/ icd","com.nokia.icd","get_ipinfo",wait_reply=True,use_system_bus=True) #lend python It always seems to complain about an interface not found (or something similar like that). We've tried many variants of this without success: ret=osso_c.rpc_run("com.nokia.icd","/com/nokia/ icd","com.nokia.icd","connect",rpc_args=[name, 1],wait_reply=True,use_system_bus=True) Our second approach was to write code that will bring up the wlan network and then scan for hotspots: #file wifi_scan.sh sudo gainroot < /sbin/ifconfig wlan0 down /sbin/ifconfig wlan0 up /usr/sbin/iwlist wlan0 scanning END Here's the code that will connect to the network (at least partially): #file wifi_connect.sh sudo gainroot < /usr/sbin/iwconfig wlan0 essid $1 /usr/sbin/iwconfig wlan0 key $2 /usr/sbin/iwconfig wlan0 commit END Running it as ./wifi_connect.sh MyNetworkSid MyWEPpassword works, except that when geting the wifi info (using /usr/sbin/iwconfig or / sbin/ifconfig) it doesn't seem to assign an IP address to the network interface (or at least something is preventing the internet from working). Assuming that the problem with the wifi_connect.sh script is that the DHCP isn't working, then there may be extra logic needed to link to dhcp server on the router…. There is code under /etc/udhcpc/ that appears to drive the assignment of ip addresses to the Nokia via DHCP from the network you become connected to. We haven't been able to get it to do anything useful. There is some vague info on this directory at http:// stefans.datenbruch.de/nokia770/. The only other last-ditch idea we've thought about (and we have no idea if this is even remotely feasible) was to use the built-in Connection Manager, but hide it behind our application's window and somehow send stylus click events to it. Right now, this mailing list is all that stands between us and dropping support for wifi connectivity in our application (ouch). Your wise counsel is humbly sought, Scott___ maemo-developers mailing list maemo-developers@maemo.org https://maemo.org/mailman/listinfo/maemo-developers