Bootloader for Omega2S and Omega2S+

Hi guys, sorry if this question was already asked, but I couldn't find any.

In the Onion's repo (http://repo.onion.io/omega2/) there are no bootloader or OS images available for Omaga2 S (the surface mount version). Where can I find any of these? Can you confirm that Omega2 images will not work (at least different pinout)?

All of the docs suggest using filesystem overlay on SD/eMMC and palcing ROM on the build-in flash storage. Is there any uboot config available with the ability to perform a full boot from eMMC/SD card? I do not want to use overlays.

Good to know that I can use source repo for building working bootloader. Thank you!

We'd like to put rootfs and kernel on eMMC storage and boot from it. This requires loading kernel from eMMC - which implies changes in u-boot. In the next step, we would like to implement A/B update strategy using mender (https://mender.io/product/how-it-works).

I was rather wondering how to unbrick device after I flash broken u-boot image. Is unsoldering and flashing in external hardware the only way to unbrick?

As I mentioned earlier, we'd like to boot from eMMC. I've already seen the "How to Boot from External Storage", but actually, it is overlay mechanism - rootfs and kernel is still on the 32M flash.

@Douglas-Kryder
Yup, that's what I found as well, and while those touch on building and using the bootloader, they don't cover anything related to flashing one. If Onion are publishing links to bootloader binaries and suggest that users flash them, I'd have thought there was a user friendly doc to go along with that.

I did manage to achieve my goal, so for my own purposes I'm good, but it was a process and a half, so I was hoping for something less complicated (and officially endorsed) to refer forum users to in future.

@Arek-Z I modified the bootloader on an omega2s+, based on the github repo of onion. This went fine without problems. For flashing, I use a FTDI SPI cable in combination with the most recent version of flashrom, which works out of the box. You can freely write the flash as long as you keep the processor in reset, so unbricking is not a problem and all required HW signals are available on the omega2s. Just make sure that you don't erase the second partition, I don't think you can restore that one.

In practical terms, I added a programming header that contains the SPI signals as well as ground, 3V3 and reset. When the programming header is inserted, a short keeps the processor in reset, so that the flash can be safely programmed. This method only works with the s/s+ version of the omega.

There is actually a simplier way to flash the bootloader: by using the Bootloader web recovery mode. Please follow the instructions provided in our docs on how to flash the firmware via web recovery modebut when you get to the 192.168.8.8, you'll be presented with the page where you need to load the firmware or load a UBoot file.
You'll want to click uBoot Update and load the bootloader binary. This will start the bootloader installation process. You can get the officail Omega2 binaries from our us.

If you flash a broken bootloader, you need to physically desolder and reprogram the flash memory.

If you modify the bootloader and/or make any physical modifications (e.g. remove the flash and etc), Onion Corporation is not responsible for any damage to your device and the warranty will be voided. Proceed at your own risk.

@Pavel-Metrokhin Thank you Pavel, we know this. However, web recovery is not available when u-boot is damaged. User wdu confirmed that it is possible to flash with SPI when you are unable to use web recovery.

If you damaged u-boot - You do not have to unsolder memory for flashing with external hardware. You are able to flash the bootloader with SPI (not a trivial thing, however). To be able to flash the memory, you need to keep Omega's processor in reset state.

@wdu , hi! Can you share with us the details? Did you just write the binary to the raw flash memory? Starting at which address? I imagine at least some part of the 32MB of flash must be partitioned with a FS (jffs2?), so we must be careful not to overwrite it, right?

Can someone point me to or share the flash's map / partitioning scheme?