Bootloader, MLO, u-boot and boot button

Dear all,
I have some problems trying to understand how the boot procedure is in the Beaglebone Black.
I saw several posts around but it is quite hard for me to fully understand how it works. So, sorry if I am repeating something that most of you already know.
What I’ve understood so far (I hope…) is:

  1. if I just power my BBB, the boot procedure is based on the flash placed on the BBB. It means that the ROM Bootloader of the AM335xx loads the MLO from the flash, the u-boot.img from the flash and then “all the rest” starts.
  2. if I power my BBB and I push the Boot-button, the ROM Bootloader of the AM335xx loads the MLO and the u-boot.img and “all the rest” from the SD card. The AM335xx does not talk at all with the flash during all the boot procedure.
  3. if I try to modify the uEnv.txt in the SD card in such a way to force the OS to be loaded form the SD card, wich means
mmc dev 1
mmc rstn 1
gpio set 52
optargs=capemgr.disable_partno=BB-BONELT-HDMI,BB-BONELT-HDMIN,BB-BONE-EMMC-2G
etc..etc

and I do not push the boot button, the AM335xx loads the MLO and the u-boot.img from the flash and “only after that” it will loads the uEnv.txt file from the SD card. It means that the bootloader will search a MLO and u-boot.img in the flash → they will talk for a while and after that the AM335xx will loads the uEnv.txt from the SD.

Now, I would like to have the point number two without to push the boot button: I do not want the AM335xx to talk with the flash at all and I am not pretty sure it is possible. In my opinion there are two ways:
the former is to set the resistor on the BBB in such a way to have the same configuration as the boot-button pressed (hardware way). The latter is to erase completely the flash in such a way to have no MLO and u-boot.img in it. However, the second way could not work because the AM335xx will talk with the flash trying to find MLO and the u-boot.img, while I do not want them to talk each other.

Is it all correct?

Thanks a lot.

Alberto

Dear all,
I have some problems trying to understand how the boot procedure is in the Beaglebone Black.
I saw several posts around but it is quite hard for me to fully understand how it works. So, sorry if I am repeating something that most of you already know.
What I’ve understood so far (I hope…) is:

  1. if I just power my BBB, the boot procedure is based on the flash placed on the BBB. It means that the ROM Bootloader of the AM335xx loads the MLO from the flash, the u-boot.img from the flash and then “all the rest” starts.
  2. if I power my BBB and I push the Boot-button, the ROM Bootloader of the AM335xx loads the MLO and the u-boot.img and “all the rest” from the SD card. The AM335xx does not talk at all with the flash during all the boot procedure.
  3. if I try to modify the uEnv.txt in the SD card in such a way to force the OS to be loaded form the SD card, wich means
mmc dev 1
mmc rstn 1
gpio set 52
optargs=capemgr.disable_partno=BB-BONELT-HDMI,BB-BONELT-HDMIN,BB-BONE-EMMC-2G
etc..etc

and I do not push the boot button, the AM335xx loads the MLO and the u-boot.img from the flash and “only after that” it will loads the uEnv.txt file from the SD card. It means that the bootloader will search a MLO and u-boot.img in the flash → they will talk for a while and after that the AM335xx will loads the uEnv.txt from the SD.

Now, I would like to have the point number two without to push the boot button: I do not want the AM335xx to talk with the flash at all and I am not pretty sure it is possible. In my opinion there are two ways:
the former is to set the resistor on the BBB in such a way to have the same configuration as the boot-button pressed (hardware way). The latter is to erase completely the flash in such a way to have no MLO and u-boot.img in it. However, the second way could not work because the AM335xx will talk with the flash trying to find MLO and the u-boot.img, while I do not want them to talk each other.

Is it all correct?

Your understanding is correct. The bootloader looks for MLO with a specific header on the eMMC and if it does not find one, it looks for an MLO on the SDCard. If you look at sheet 6 in the BBB schematics, there is a table which shows the boot order given the SYSBOOT settings. If you don’t want the BBB to access the eMMC at boot time, you must move resistors on the board as you indicated.

Regards,
John

SYS_BOOT2 is present on P8-43. I would try to place a resistor between this point and ground first. The Pull-up is pretty weak (100kOhm), so something like 10 k would probably do the job. Off course this pin is also used as LCD_DATA2, but if you can live with it, it is a lot better than moving R93-R68 on the board

SYS_BOOT2 is present on P8-43. I would try to place a resistor between this point and ground first. The Pull-up is pretty weak (100kOhm), so something like 10 k would probably do the job. Off course this pin is also used as LCD_DATA2, but if you can live with it, it is a lot better than moving R93-R68 on the board

If you don’t have the correct tools to move 0402 components then your solution might be better. Try it and see if it works. How do you plan to see which MLO (eMMC or SDCard) is loaded at boot time?

Regards,
John

If OP can’t tell the difference I wonder why it is an issue at all.

Dear all,

thanks for your answer: maybe move resistors is the better solution for me.

Thanks again.

Alberto

Yes, changing the boot sequence with the simple hardware hack will work, but is there some reason you can’t do the even simpler thing of just not making the eMMC bootable? If it’s erased, or does not contain an MLO, then the board will boot from the SD card.