Breakthrough!
-
I did it. I got the STM32MP157-DK evaluation board running on bare metal, no operating system. Boot time is pretty fast, but could be faster if I move away from using U-Boot, which thinks my code is a linux kernel. :laugh: I think I managed to get SPI code in place too but I have yet to wire up a logic analyzer to test with. This is crazy. It also required me to install linux on my laptop. The VMs just hated me. I even got both cores working, and I have a codebase that has my graphics library integrated, which by the way, I made a design decision a year ago with it that saved my bacon on this project. The library isn't fundamentally thread-safe BUT you can isolate different screens, and each handles its own rendering, so you can run them on different cores without synchronization between them. Trouble is I still need synchronization anyway, and I may have to make some spinlocks and such with std::atomic if that works or LDREX and STREX asm instructions if it doesn't. Lovely. Everything I'm doing I haven't done since maybe the 1980s. Messing with boot loader code, writing OS level system interaction, etc, and that was 8 and 16 bit processors which were far simpler than even this little embedded monsters. It's an adventure The screen below is proof of life. It came from the serial port of my device.
U-Boot 2020.01-stm32mp-r1 (Feb 16 2024 - 16:44:10 -0800)
CPU: STM32MP157DAC Rev.Z
Model: STMicroelectronics STM32MP157D-DK1 Discovery Board
Board: stm32mp1 in basic mode (st,stm32mp157d-dk1)
Board: MB1272 Var3.0 Rev.C-03
DRAM: 512 MiB
Clocks:- MPU : 800 MHz
- MCU : 208.878 MHz
- AXI : 266.500 MHz
- PER : 24 MHz
- DDR : 533 MHz
NAND: 0 MiB
MMC: STM32 SD/MMC: 0
Loading Environment from MMC... *** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
****************************************************
* WARNING 500mA power supply detected *
* Current too low, use a 3A power supply! *
****************************************************Net: eth0: ethernet@5800a000
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
15272 bytes read in 30 ms (497.1 KiB/s)Booting kernel from Legacy Image at c2000040 ...
Image Name: stm32mp1-baremetal image
Created: 2024-02-17 0:54:04 UTC
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 15208 Bytes = 14.9 KiB
Load Address: c2000040
Entry Point: c2000040
Verifyi -
I did it. I got the STM32MP157-DK evaluation board running on bare metal, no operating system. Boot time is pretty fast, but could be faster if I move away from using U-Boot, which thinks my code is a linux kernel. :laugh: I think I managed to get SPI code in place too but I have yet to wire up a logic analyzer to test with. This is crazy. It also required me to install linux on my laptop. The VMs just hated me. I even got both cores working, and I have a codebase that has my graphics library integrated, which by the way, I made a design decision a year ago with it that saved my bacon on this project. The library isn't fundamentally thread-safe BUT you can isolate different screens, and each handles its own rendering, so you can run them on different cores without synchronization between them. Trouble is I still need synchronization anyway, and I may have to make some spinlocks and such with std::atomic if that works or LDREX and STREX asm instructions if it doesn't. Lovely. Everything I'm doing I haven't done since maybe the 1980s. Messing with boot loader code, writing OS level system interaction, etc, and that was 8 and 16 bit processors which were far simpler than even this little embedded monsters. It's an adventure The screen below is proof of life. It came from the serial port of my device.
U-Boot 2020.01-stm32mp-r1 (Feb 16 2024 - 16:44:10 -0800)
CPU: STM32MP157DAC Rev.Z
Model: STMicroelectronics STM32MP157D-DK1 Discovery Board
Board: stm32mp1 in basic mode (st,stm32mp157d-dk1)
Board: MB1272 Var3.0 Rev.C-03
DRAM: 512 MiB
Clocks:- MPU : 800 MHz
- MCU : 208.878 MHz
- AXI : 266.500 MHz
- PER : 24 MHz
- DDR : 533 MHz
NAND: 0 MiB
MMC: STM32 SD/MMC: 0
Loading Environment from MMC... *** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
****************************************************
* WARNING 500mA power supply detected *
* Current too low, use a 3A power supply! *
****************************************************Net: eth0: ethernet@5800a000
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
15272 bytes read in 30 ms (497.1 KiB/s)Booting kernel from Legacy Image at c2000040 ...
Image Name: stm32mp1-baremetal image
Created: 2024-02-17 0:54:04 UTC
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 15208 Bytes = 14.9 KiB
Load Address: c2000040
Entry Point: c2000040
Verifyi -
I did it. I got the STM32MP157-DK evaluation board running on bare metal, no operating system. Boot time is pretty fast, but could be faster if I move away from using U-Boot, which thinks my code is a linux kernel. :laugh: I think I managed to get SPI code in place too but I have yet to wire up a logic analyzer to test with. This is crazy. It also required me to install linux on my laptop. The VMs just hated me. I even got both cores working, and I have a codebase that has my graphics library integrated, which by the way, I made a design decision a year ago with it that saved my bacon on this project. The library isn't fundamentally thread-safe BUT you can isolate different screens, and each handles its own rendering, so you can run them on different cores without synchronization between them. Trouble is I still need synchronization anyway, and I may have to make some spinlocks and such with std::atomic if that works or LDREX and STREX asm instructions if it doesn't. Lovely. Everything I'm doing I haven't done since maybe the 1980s. Messing with boot loader code, writing OS level system interaction, etc, and that was 8 and 16 bit processors which were far simpler than even this little embedded monsters. It's an adventure The screen below is proof of life. It came from the serial port of my device.
U-Boot 2020.01-stm32mp-r1 (Feb 16 2024 - 16:44:10 -0800)
CPU: STM32MP157DAC Rev.Z
Model: STMicroelectronics STM32MP157D-DK1 Discovery Board
Board: stm32mp1 in basic mode (st,stm32mp157d-dk1)
Board: MB1272 Var3.0 Rev.C-03
DRAM: 512 MiB
Clocks:- MPU : 800 MHz
- MCU : 208.878 MHz
- AXI : 266.500 MHz
- PER : 24 MHz
- DDR : 533 MHz
NAND: 0 MiB
MMC: STM32 SD/MMC: 0
Loading Environment from MMC... *** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
****************************************************
* WARNING 500mA power supply detected *
* Current too low, use a 3A power supply! *
****************************************************Net: eth0: ethernet@5800a000
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
15272 bytes read in 30 ms (497.1 KiB/s)Booting kernel from Legacy Image at c2000040 ...
Image Name: stm32mp1-baremetal image
Created: 2024-02-17 0:54:04 UTC
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 15208 Bytes = 14.9 KiB
Load Address: c2000040
Entry Point: c2000040
VerifyiWhen something like that happens to me the cry of 'It's alive, alive I tell you, they said I was mad but it's alive, alive I tell you' comes from my desk. :-O
-
I did it. I got the STM32MP157-DK evaluation board running on bare metal, no operating system. Boot time is pretty fast, but could be faster if I move away from using U-Boot, which thinks my code is a linux kernel. :laugh: I think I managed to get SPI code in place too but I have yet to wire up a logic analyzer to test with. This is crazy. It also required me to install linux on my laptop. The VMs just hated me. I even got both cores working, and I have a codebase that has my graphics library integrated, which by the way, I made a design decision a year ago with it that saved my bacon on this project. The library isn't fundamentally thread-safe BUT you can isolate different screens, and each handles its own rendering, so you can run them on different cores without synchronization between them. Trouble is I still need synchronization anyway, and I may have to make some spinlocks and such with std::atomic if that works or LDREX and STREX asm instructions if it doesn't. Lovely. Everything I'm doing I haven't done since maybe the 1980s. Messing with boot loader code, writing OS level system interaction, etc, and that was 8 and 16 bit processors which were far simpler than even this little embedded monsters. It's an adventure The screen below is proof of life. It came from the serial port of my device.
U-Boot 2020.01-stm32mp-r1 (Feb 16 2024 - 16:44:10 -0800)
CPU: STM32MP157DAC Rev.Z
Model: STMicroelectronics STM32MP157D-DK1 Discovery Board
Board: stm32mp1 in basic mode (st,stm32mp157d-dk1)
Board: MB1272 Var3.0 Rev.C-03
DRAM: 512 MiB
Clocks:- MPU : 800 MHz
- MCU : 208.878 MHz
- AXI : 266.500 MHz
- PER : 24 MHz
- DDR : 533 MHz
NAND: 0 MiB
MMC: STM32 SD/MMC: 0
Loading Environment from MMC... *** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
****************************************************
* WARNING 500mA power supply detected *
* Current too low, use a 3A power supply! *
****************************************************Net: eth0: ethernet@5800a000
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
15272 bytes read in 30 ms (497.1 KiB/s)Booting kernel from Legacy Image at c2000040 ...
Image Name: stm32mp1-baremetal image
Created: 2024-02-17 0:54:04 UTC
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 15208 Bytes = 14.9 KiB
Load Address: c2000040
Entry Point: c2000040
VerifyiCongrats! That is so cool. It requires a 3A power supply?
-
Congrats! That is so cool. It requires a 3A power supply?
Yeah - USB C, and it's actually connected to one but for some reason it's saying otherwise.
Check out my IoT graphics library here: https://honeythecodewitch.com/gfx And my IoT UI/User Experience library here: https://honeythecodewitch.com/uix
-
I did it. I got the STM32MP157-DK evaluation board running on bare metal, no operating system. Boot time is pretty fast, but could be faster if I move away from using U-Boot, which thinks my code is a linux kernel. :laugh: I think I managed to get SPI code in place too but I have yet to wire up a logic analyzer to test with. This is crazy. It also required me to install linux on my laptop. The VMs just hated me. I even got both cores working, and I have a codebase that has my graphics library integrated, which by the way, I made a design decision a year ago with it that saved my bacon on this project. The library isn't fundamentally thread-safe BUT you can isolate different screens, and each handles its own rendering, so you can run them on different cores without synchronization between them. Trouble is I still need synchronization anyway, and I may have to make some spinlocks and such with std::atomic if that works or LDREX and STREX asm instructions if it doesn't. Lovely. Everything I'm doing I haven't done since maybe the 1980s. Messing with boot loader code, writing OS level system interaction, etc, and that was 8 and 16 bit processors which were far simpler than even this little embedded monsters. It's an adventure The screen below is proof of life. It came from the serial port of my device.
U-Boot 2020.01-stm32mp-r1 (Feb 16 2024 - 16:44:10 -0800)
CPU: STM32MP157DAC Rev.Z
Model: STMicroelectronics STM32MP157D-DK1 Discovery Board
Board: stm32mp1 in basic mode (st,stm32mp157d-dk1)
Board: MB1272 Var3.0 Rev.C-03
DRAM: 512 MiB
Clocks:- MPU : 800 MHz
- MCU : 208.878 MHz
- AXI : 266.500 MHz
- PER : 24 MHz
- DDR : 533 MHz
NAND: 0 MiB
MMC: STM32 SD/MMC: 0
Loading Environment from MMC... *** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
****************************************************
* WARNING 500mA power supply detected *
* Current too low, use a 3A power supply! *
****************************************************Net: eth0: ethernet@5800a000
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
15272 bytes read in 30 ms (497.1 KiB/s)Booting kernel from Legacy Image at c2000040 ...
Image Name: stm32mp1-baremetal image
Created: 2024-02-17 0:54:04 UTC
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 15208 Bytes = 14.9 KiB
Load Address: c2000040
Entry Point: c2000040
Verifyi -
Have you written your own bootloader ?
In a closed society where everybody's guilty, the only crime is getting caught. In a world of thieves, the only final sin is stupidity. - Hunter S Thompson - RIP
I started to, but then I realized I could get U-Boot working on it. However, I may go back to my own because U-Boot takes a bit more time than I think it should.
Check out my IoT graphics library here: https://honeythecodewitch.com/gfx And my IoT UI/User Experience library here: https://honeythecodewitch.com/uix
-
I did it. I got the STM32MP157-DK evaluation board running on bare metal, no operating system. Boot time is pretty fast, but could be faster if I move away from using U-Boot, which thinks my code is a linux kernel. :laugh: I think I managed to get SPI code in place too but I have yet to wire up a logic analyzer to test with. This is crazy. It also required me to install linux on my laptop. The VMs just hated me. I even got both cores working, and I have a codebase that has my graphics library integrated, which by the way, I made a design decision a year ago with it that saved my bacon on this project. The library isn't fundamentally thread-safe BUT you can isolate different screens, and each handles its own rendering, so you can run them on different cores without synchronization between them. Trouble is I still need synchronization anyway, and I may have to make some spinlocks and such with std::atomic if that works or LDREX and STREX asm instructions if it doesn't. Lovely. Everything I'm doing I haven't done since maybe the 1980s. Messing with boot loader code, writing OS level system interaction, etc, and that was 8 and 16 bit processors which were far simpler than even this little embedded monsters. It's an adventure The screen below is proof of life. It came from the serial port of my device.
U-Boot 2020.01-stm32mp-r1 (Feb 16 2024 - 16:44:10 -0800)
CPU: STM32MP157DAC Rev.Z
Model: STMicroelectronics STM32MP157D-DK1 Discovery Board
Board: stm32mp1 in basic mode (st,stm32mp157d-dk1)
Board: MB1272 Var3.0 Rev.C-03
DRAM: 512 MiB
Clocks:- MPU : 800 MHz
- MCU : 208.878 MHz
- AXI : 266.500 MHz
- PER : 24 MHz
- DDR : 533 MHz
NAND: 0 MiB
MMC: STM32 SD/MMC: 0
Loading Environment from MMC... *** Warning - bad CRC, using default environment
In: serial
Out: serial
Err: serial
****************************************************
* WARNING 500mA power supply detected *
* Current too low, use a 3A power supply! *
****************************************************Net: eth0: ethernet@5800a000
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
15272 bytes read in 30 ms (497.1 KiB/s)Booting kernel from Legacy Image at c2000040 ...
Image Name: stm32mp1-baremetal image
Created: 2024-02-17 0:54:04 UTC
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 15208 Bytes = 14.9 KiB
Load Address: c2000040
Entry Point: c2000040
VerifyiAny time I think you can't surprise me anymore... you come with your next crazy success. Congratulations :thumbsup:
M.D.V. ;) If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about? Help me to understand what I'm saying, and I'll explain it better to you Rating helpful answers is nice, but saying thanks can be even nicer.