# things i discoverd about touchpad



## rainlake (Aug 26, 2011)

1. press and hold volume up + power will enter bootloader/recovery
2. novacom -t open tty://0 will connect to bootloader/recovery 
3.printenv in this mode will print some boot args
4.chainboot will boot to normal mode from mmc0p7
5. /usr/local/sbin/recovery/data_restore.sh is webos doctor used to restore a image file.
6. mmc0p14 should be rootfs
7.webos should have 14 partitions.
8. downloaded android have 17 partitions?
questions:
1.can we just restore mmc0p7 and mmc0p14 to get android running?
2.if I try to restore all the partitions, will this brick my touchpad?


----------



## rainlake (Aug 26, 2011)

/usr/bin/PmFirmwareUpdater is another command webosdoctor will execute. 
cat /usr/bin/PmFirmwareUpdater
#!/bin/sh

mkdir -p /tmp/boot-genesis
cd /tmp/boot-genesis
tar xzvf /boot/boot-genesis.tar.gz
/usr/bin/genesis-update.sh /tmp/boot-genesis/sbl1.mbn /dev/mmcblk0p2
/usr/bin/genesis-update.sh /tmp/boot-genesis/sbl2.mbn /dev/mmcblk0p3
/usr/bin/genesis-update.sh /tmp/boot-genesis/rpm.mbn /dev/mmcblk0p5
/usr/bin/genesis-update.sh /tmp/boot-genesis/sbl3.mbn /dev/mmcblk0p6
/usr/bin/genesis-update.sh /tmp/boot-genesis/emmc_appsboot.mbn /dev/mmcblk0p7
/usr/bin/genesis-update.sh /tmp/boot-genesis/tz.mbn /dev/mmcblk0p9
cd /
rm -rf /tmp/boot-genesis

echo "\$ Your device is ready for use"

so these partitions is firmware?


----------



## rainlake (Aug 26, 2011)

I might be wrong.

printenv

? = -1
framebuffer = 0x7f600000
installer = trenchcoat
checkbatt = 1
chargebypass = 1
klog_len = 0x100000
klog_addr = 0x7ff00000
tablet_wod_support = 0x0
extended_timeout = 0x0
chainbootdevice = mmc0
bootaddress = 0x41000000
bootdevice = mmc0p12
bootfile = uImage
bootfs = ext2
bootargs-ramdisk = root=/dev/ram0 rw
bootargs = root=/dev/mmcblk0p13 rootwait ro
bootconsole = ttyS0,115200n8
autoboot = fsboot
boardtype = topaz-Wifi-pvt


----------



## damageless (Aug 25, 2011)

Absolutely perfect! Thanks rainlake, this is the kind of dev we need.


----------



## rainlake (Aug 26, 2011)

while in recovery mode. 
telnet localhost 6968, you will get the devices list connected. first parameter is a number,
use a tool connect to that port. send boot mem://\n to it. then send file "nova-installer-image-topaz.uImage" will boot into ram mode.
to send each packet of that file. you must send a 16 bytes header. the header contains 4 integers, the first is -557122643, the second is 1, the third is the package size, the forth is 0. 
array[(offset + 0)] = (byte)(val >> 0 & 0xFF);
array[(offset + 1)] = (byte)(val >> 8 & 0xFF);
array[(offset + 2)] = (byte)(val >> 16 & 0xFF);
array[(offset + 3)] = (byte)(val >> 24 & 0xFF);
I'm not sure it's BE or LE.

you might choose 64K as package size.


----------



## rainlake (Aug 26, 2011)

I send 16.img to touchpad, it show a hp logo with no further information. 
and novacom is not connectable


----------



## Pai (Aug 24, 2011)

rainlake said:


> *1. press and hold volume up + power will enter bootloader/recovery*
> 2. novacom -t open tty://0 will connect to bootloader/recovery
> 3.printenv in this mode will print some boot args
> 4.chainboot will boot to normal mode from mmc0p7
> ...


How do you exit this?


----------



## Nth (Aug 26, 2011)

hold down power and the button on the front for 15 seconds.


----------

