Hi Mattijs,
Am 17.02.2017 um 02:51 schrieb Matthijs van Duin matthijsvanduin@gmail.com:
On 15 February 2017 at 13:07, H. Nikolaus Schaller hns@goldelico.com wrote: I have done a quick test:
- console connected
- no SD cards inserted
- battery inserted
- plug in µUSB cable on USB3 port
- powered on (so that BootROM starts searching for an OS)
Result is that my host reports a device called "OMAP5430".
And now I can get it to work too,
great!
and I even managed to boot from eMMC sometimes.
What does and doesn't work seems heavily dependent on what is connected, the configuration/state of charger (and perhaps palmas), probably the state of charge of the battery...
I had also tried with booting from µSD (with empty eMMC) and also did not yet find a pattern when it works and when it doesn't.
Maybe the RTC or the barometer chip also has an influence.
Also, I just powered on with no SD card inserted and holding down LSH-TOP to bypass eMMC boot... except it booted from eMMC anyway!
Oops. Hm. Only the 4 lower bits are switched and the eMMC is 8 bit. Well, ECC is probably not that good to read the eMMC correctly in this case...
And manually throwing the switch in u-boot and doing a mmc info shows only either one.
Weird stuff is going on. Will need to explore more...
Indeed. It is one of the last mysterious things.
Another one is that the board version detection sometimes reports V5.5 for my mainboard in MLO which then makes the gpio numbers setup for the µSD/eMMC switch fail.
This is difficult to explain. It just reads out some gpios...
Maybe a timing issue? Do we have to add a delay after switching pinmux before we read the gpio values?
Then, I am not sure if the BootROM assumes that there is a Palmas chip at all!
No, it does not interact with the PMIC on the omap5.
Ok, good to know. This means it is doing USB-boot without any assumptions about VBUS.
So if there is something (broken) in eMMC it might not even try USB.
And as I showed above, the shoulder button doesn't seem to work?
Also, USB is not considered a "permanent boot device", which means it is *only* considered at cold boot and ignored at warm boot.
Interesting to know!
Is the shoulder button not working for card selection a similar issue? Did you do a warm reset or cold reset?
Maybe the OMAP5 keeps the switch state of the last attempt during a warm reset. This completely disables the shoulder button for card selection completely until we do a cold reset.
I forgot about this, and probably tried to get it to boot a few times by resetting or rebooting.
Asking palmas to power-cycle the system (i2c mw 48 a0 3) does work of course.
For the GTA04 we have a poweroff command doing a similar thing for the twl4030.
Afaik there could also be some generic u-boot command, or not? Anyways an u-boot command to completely power off from the u-boot command line would be nice.
Additionally I have cherry-picked some more of your patches and manually picked some defconfig changes. Now, I can also use the ums command.
I hope my patches do not raise too many rebase conflicts.
BR and thanks, Nikolaus