Wow! You're amazing and thank you! All the flashing went smoothly. The device is automatically booting into recovery mode every time I try to reboot it. I had been doing this before the flashing. I'm using your TWRP from the other thread, as my manufacturer recovery hadn't been accessible. Any ideas about this? This constant progress has me very hopeful, at least!
Hm.. The Cosmo appears to be super temperamental about what it will boot into in my testing -- sometimes it goes straight to Android, sometimes it goes straight to recovery, sometimes it just loops on screen on/off with the CoDi doing weird things. I've not identified a pattern.
Have you tried using Reboot > System from TWRP rather than just power cycling the Cosmo? This usually seems to do the trick for me.
If that doesn't work, I'd be very interested in seeing what your 'para' partition (NOT 'boot_para'!) contains. Please run this:
xxd /dev/block/by-name/para | grep -v "0000 0000 0000 0000 0000 0000 0000 0000"
It's mostly zeroes, but appears to contain some pertinent information within the first two pages. Here is what I get from my Cosmo, split up:
00000000: 626f 6f74 6f6e 6365 2d62 6f6f 746c 6f61 bootonce-bootloa
00000010: 6465 7200 0000 0000 0000 0000 0000 0000 der.............
00020000: 454e 565f 7631 0000 6f66 662d 6d6f 6465 ENV_v1..off-mode
00020010: 2d63 6861 7267 653d 3100 756e 6c6f 636b -charge=1.unlock
00020020: 5f65 7261 7365 3d70 6173 7300 0000 0000 _erase=pass.....
00023ff0: 0000 0000 454e 565f 7631 0000 010d 0000 ....ENV_v1......
00040000: 0100 0000 34d9 63c8 aacb 3f77 e355 44f1 ....4.c...?w.UD.
00040010: 0000 0000 0000 0000 1f56 44f1 3c00 0000 .........VD.<...
00040030: 0000 0000 e355 44f1 fe5e c800 0000 0000 .....UD..^......
00040040: ea56 44f1 3500 0000 0000 0000 0200 0000 .VD.5...........
00040050: d000 0000 0000 0000 0000 0000 0000 0000 ................
At 00000000 is a text string which determines what the Cosmo will do on next boot - right now on mine (within Android) it is "bootonce-bootloader".
At 00020000 is what appears to be called the "env" data (
relevant code in Gemini LK source), mine simply contains 'off-mode-charge=1' and 'unlock_erase=pass' as you can see above.
At 00040000 is data which I believe relates to power management - my hardware-fu isn't good enough to determine precisely
what it does but I'm 100% confident it's not sensitive in any way. I don't know if it varies on different Cosmo units, and I suspect that it may be left-over data which the Cosmo doesn't actually use - the Gemini kernel
reads it in its Picachu module (same location, different format), and while the Cosmo has a
Picachu module has well, it doesn't read from the para partition. There is also a
Kconfig file in the Gemini kernel which expands Picachu to "PI CAlibration and CHaracterization Utility".
Anyway, while writing this post I've managed to once again get my Cosmo into a state where it won't boot into anything other than the Preloader. I'm going to see if I can figure out
why it's doing this and if I can come up with a solution.