Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. Breakthrough!

Breakthrough!

Scheduled Pinned Locked Moved The Lounge
graphicsdesignlinuxhardwareworkspace
8 Posts 6 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    honey the codewitch
    wrote on last edited by
    #1

    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

    J G G pkfoxP N 5 Replies Last reply
    0
    • H honey the codewitch

      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

      J Offline
      J Offline
      jmaida
      wrote on last edited by
      #2

      Excellent work and play mixed together I'm envious

      "A little time, a little trouble, your better day" Badfinger

      1 Reply Last reply
      0
      • H honey the codewitch

        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

        G Offline
        G Offline
        glennPattonWork3
        wrote on last edited by
        #3

        When 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

        1 Reply Last reply
        0
        • H honey the codewitch

          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

          G Offline
          G Offline
          Gary Stachelski 2021
          wrote on last edited by
          #4

          Congrats! That is so cool. It requires a 3A power supply?

          H 1 Reply Last reply
          0
          • G Gary Stachelski 2021

            Congrats! That is so cool. It requires a 3A power supply?

            H Offline
            H Offline
            honey the codewitch
            wrote on last edited by
            #5

            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

            1 Reply Last reply
            0
            • H honey the codewitch

              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

              pkfoxP Offline
              pkfoxP Offline
              pkfox
              wrote on last edited by
              #6

              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

              H 1 Reply Last reply
              0
              • pkfoxP pkfox

                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

                H Offline
                H Offline
                honey the codewitch
                wrote on last edited by
                #7

                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

                1 Reply Last reply
                0
                • H honey the codewitch

                  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

                  N Offline
                  N Offline
                  Nelek
                  wrote on last edited by
                  #8

                  Any 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.

                  1 Reply Last reply
                  0
                  Reply
                  • Reply as topic
                  Log in to reply
                  • Oldest to Newest
                  • Newest to Oldest
                  • Most Votes


                  • Login

                  • Don't have an account? Register

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • World
                  • Users
                  • Groups