[U-Boot] Variable content dump to memory

James Chargin jimccrown at gmail.com
Thu Mar 24 18:51:21 CET 2016


On 03/24/2016 03:30 AM, Nicolae Rosia wrote:
> Hello,
>
> I'm trying to write the contents of a variable to a file using ext4write
> but it requires a memory address as input.
> Is there an easy way to get the contents of a variable to a particular mem
> address?

You weren't completely specific about your needs, but assuming you are 
wanting to write a U-Boot environment variable to memory, try something like

=> # set up a test value
=> setenv var 12345678
=> printenv var
var=12345678
=>
=> # do the actual write
=> mw.l 80020000 $var 1
=>
=> # observe memory was set
=> md.l 8001fff0 c
8001fff0: 67ffedc4 dbc98df5 8e71cdd4 628fcacd    ...g......q....b
80020000: 12345678 a2fe8db5 df34c767 636dbd37    xV4.....g.4.7.mc
80020010: 375dfdcb fde86ca2 3f273cdf 1fe951f9    ..]7.l...<'?.Q..

Also, "help mw".

This was done on something similar to beaglebone x15. You will need to 
use memory addresses that are valid for your target system.

Jim

>
> Best regards,
> Nicolae
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot
>

-- 
Jim Chargin
AJA Video Systems                       jimc at aja.com
(530) 271-3334                          http://www.aja.com


More information about the U-Boot mailing list