UPDATE:
This guide is outdated, please do not use it anymore! There is a new and updated procedure that is easy to follow and integrates g_serial debugging. The files linked to in this guide will be no longer available.
I’ve been talking about this idea for a while now, but today I finally had the right mood to work on it and I think I’ve found a sufficiently flexible solution for now.
I’m loading the kernel modules (musb_hdrc and g_serial) in the initramfs. Fortunately there was enough space left for that.
I’ve created 3 separate serial interfaces using g_serial.
- /dev/ttyGS0 – unused (root shell on Archos Android firmware)
- /dev/ttyGS1 – unused
- /dev/ttyGS2 – kernel messages. this is simply ‘cat /proc/kmsg’
You can now attach terminals or logs to this in your images. Usually by editing /etc/inittab and adding a line like:
s2:235:respawn:/sbin/mingetty --autologin root ttyGS0
If you need to disable this you can just kill the ‘cat’ process and if running stop the getty’s. After doing that you can remove the g_serial and then the musb_hdrc module. You can then e.g. reload musb_hdrc to have it act as a host controller again.
The important changes are in the initramfs. The zImage is only needed if you want the root shell for Android. Get the files here.
Enjoy your easy debugging! No need for serial dongles anymore!
Cheers
Thomas, your friendly neighborhood ArchDruid
PS: As a bonus this zImage will boot Archos 2.0.x firmwares. There will be some problems with transparencies though. We’re going to fix that in the long run though.
PPS: If there is demand I can generate a set for gen6 too.



