RPI U-boot run s-rec application

From arrizza.org wiki

Jump to navigation Jump to search

Run the hello_world s-rec application

  • Assumes the uboot project has been setup and compiled rPI U-boot

load the application

  • start the rPI
  • at the command line
 U-Boot> loads
 ## Ready for S-Record download ...
  • in gtkterm:
 click File | Send Raw File
 navigate to ~/projects/uboot/build/examples/standalone
 select hello_world.srec
 click OK
  • the output will be
 ## First Load Addr = 0x0C100000
 ## Last  Load Addr = 0x0C100251
 ## Total Size      = 0x00000252 = 594 Bytes
 ## Start Addr      = 0x0C100000
 U-Boot>

run the application

  • U-Boot> go 0x0c100000
 ## Starting application at 0x0C100000 ...
 Example expects ABI version 6
 Actual U-Boot ABI version 6
 Hello World
 argc = 1
 argv[0] = "0x0c100000"
 argv[1] = "<NULL>"
 Hit any key to exit ... 
 <press ENTER here> 
 ## Application terminated, rc = 0x0
 U-Boot> 
  • repeat with a parameter
 U-Boot> go 0x0c100000 1234
 ## Starting application at 0x0C100000 ...
 Example expects ABI version 6
 Actual U-Boot ABI version 6
 Hello World
 argc = 2
 argv[0] = "0x0c100000"
 argv[1] = "1234"
 argv[2] = "<NULL>"
 Hit any key to exit ... 
 <press ENTER here> 
 ## Application terminated, rc = 0x0
 U-Boot> 

check out the source code

  • compare the code to the behavior
 uboot/u-boot-pi-rpi/examples/standalone/hello_world.c
Personal tools