News aggregator
Quick notes
As expected my son is occupying me a lot. But I had some Innovation Time Off accumulated at work so I worked on Palms a bit.
USB client is not working well for all PXA machines, but palmtreo.c code had missing some more functionality - connection worked only once when booting with cable attached. I fixed this with following marex's patch adding this support for PalmLD, PalmTX and PalmT5. It works now better, but it stops working after suspend/resume. I'll try to dig into code. I have found that GPIO90 works same way as GPIO1 - USB detection - weird.
Support for MAX8588 and PI2C was added and it seems to work. Funny about this is, that I tried to use CPU at 416 MHz in Linux at the same voltage as it was set in PalmOS for 312 MHz. I started to use Linux on 520 MHz and it works nice.
Camera differs from the ones found in other Palms (understand - I tried to follow marex's patch for Zire72 camera but it did not work :). I disassembled my Treo680 and tried to trace GPIOs. The only one new GPIO I have found is GPIO82. You can see photos here and here. I don't know currently what type it is and I didn't even found it on I2C bus yet. Interesting is that this module has 20 pins.
I also did some tiny code cleanups but I have to create patch set and push so you can use it too.
If you want some up-to-date distribution, you can try Ångström distribution - they started to provide online builder where Palm Treo 650 can be found. You can use such image, just put there new kernel and modules. Beware of udev and CONFIG_SYSFS_DEPRECATED. I tried OPIE (didn't work), GPE (worked somehow) using mdev instead of udev.
You can also prepare Debian root filesystem using qemu. There is prepared kernel and base system here you can use as a start. If there will be time spare I'll make some automated up-to-date Debian root filesystem generator for Palms. For getting files out of qemu disk when the virtual system is off use kpartx and raw image type.
Good night!
OpenOCD: PXA3xx NAND flash driver
A quick howto on reflashing the bootloader using the NAND code in OpenOCD follows:
- run OpenOCD with the following command: openocd -s tcl -f board/colibri_pxa320.cfg -f interface/jtagkey.cfg (for Colibri/PXA3xx board and Amontec JTAGkey)
- connect to OpenOCD using telnet: telnet localhost 4444
- Issue the following commands, one after another:
- reset halt
- nand probe 0
- nand erase 0 0x0 0x20000 ; nand erase 0x20000 0x20000 (erase first two blocks)
- nand write 0 bootloader.img 0x0
- To read data from NAND, use: nand dump 0 dump.img 0x0 0x800 (0x0 is base address, 0x800 is amount of bytes)
Colibri/PXA320 meets OpenOCD, becomes free
I took a look at OpenOCD project, which is a Free Software JTAG Debugger, and figured it'd be actually quite simple to update it to support PXA3xx by looking into the PXA3xx documentation and comparing it with PXA2xx one. Apparently, the only differences there were the Instruction Length (which was 7 for PXA2xx and 11 for PXA3xx) and - the more weird change - that PXA3xx has the instruction codes shifted by 4 to the left in some cases. After fixing these, I was able to connect to the CPU using my FTDI FT2232 based fake-amontec JTAG cable and operate with it normally. The patches are available in the OpenPXA GIT.
Maybe someone would like to see a howto for loading new software into the board using the OpenOCD, so here it is. Firstly, download the OpenOCD patches from OpenPXA GIT and do:
- git clone git://openocd.git.sourceforge.net/gitroot/openocd/openocd # download OpenOCD sources
- cd openocd # enter the OpenOCD directory
- apply OpenPXA patches for OpenOCD
- ./bootstrap # prepare files necessary for OpenOCD compilation
- ./configure --enable-maintainer-mode --enable-ft2232_libftdi # the first option is necessary (dunno why), the other one enables support for the ft2232-based cables
- make # compiles OpenOCD
- ./src/openocd -s tcl -f board/colibri_pxa320.cfg -f interface/jtagkey.cfg # executes the OpenOCD debugger; tells it to search for configuration scripts in directory tcl, to use colibri_pxa320.cfg board support file and jtagkey.cfg cable support file
- telnet localhost 4444 # connect to the OpenOCD
- reset halt # reset the CPU and stop executing instructions
- fast_load_image /path/to/file 0x5c080000 bin # prepare to load binary file to address 0x5c080000 (NOTE: 0x5c080000 is valid SRAM only for PXA320, for other CPUs use 0x5c000000 or something)
- fast_load # actually upload the file
- resume 0x5c080000 # continue instruction execution at address 0x5c080000 (about the address used, see previous note)
Palm over USB - NetworkManager without ModemManager
When you attach your Palm over USB to PC with NetworkManager, ModemManager tries to open every new serial device and it causes Palm reset.
You can workaround this problem by disabling ModemManager at all:
# mv /usr/share/dbus-1/system-services/org.freedesktop.ModemManager.service ~
I'll try to make some list of USB IDs and correct serial ports, but the best would be disable ModemManager for these devices at all.
Is there any other way to use serial port of Palm Smartphone to communicate with modem than using 'USB Modem' application? It even uses some other serial device - ttyACMx...
RING again
- Centro patches finally applied
- suspend is broken on Treos, Centro, TX and probably others, probably git bisect is needed
- Centro has problem with framebuffer, I have some idea about possible fix, it has top priority now
- I still haven't found the way, how to run GSM when powered off in PalmOS, but you can power it on in PalmOS and use older cocoboot.prc from my page and get your RING again
- I added context menu symbol to Treo xkb map, useful when you miss right click with touchscreen, if you use it, you can update
- It seems that power consumption is lesser in Linux than in PalmOS even with higher clock! Photos on my facebook profile (yes, I was finally Facebookized too, resistance is futile ;)
- I'll be dad in a month so I'll have less time for this project, sorry.
- QtExtended support older brother of GSM (in Greenphone) chip residing Treos. It should be quite easy to add support! Volunteers needed.
- This blog entry was written on Treo680 using Illume on Debian. It's not as fast as good old Opie, but it's much more usable. I've even better impression than from SHR on FreeRunner!
- There are first attempts about Treo755p, but it will need more time.
Things in my TODO list now:
- fix Centro framebuffer (release kernel)
- fix GSM problem (release kernel)
- fix gsm0710muxd and FSO
- try to fix suspend (if Marex won't care)
- build kernel for TX, LD, T5
- rework install_script.sh (better rights management, support for halmount, add more options)
