Skip to contentSkip to conversation

Mathematics operation on uboot variables

U-Boot Eran Y 2 participants 2 messages Nov 23, 2010 – Nov 25, 2010

lore
Share & tools
lore

Eran Y

author
#0 lore raw

Hi

Is there any way to use mathematics operation on uboot environment or uboot local variables?
since $varA+$varB and $(varA+varB) just save the string.

Signature · 2 lines
View this message in context: http://old.nabble.com/Mathematics-operation-on-uboot-variables-tp30283797p30283797.html
Sent from the Uboot - Users mailing list archive at Nabble.com.
#1 lore raw

Hi Eran,

Quoted 3 lines

Is there any way to use mathematics operation on uboot environment or uboot local variables?
since $varA+$varB and $(varA+varB) just save the string.

You need to include CONFIG_CMD_SETEXPR in your configuration for such a functionality. See common/cmd_setexpr.c.

Cheers
Detlev

Signature · 7 lines
Q: What is a compact city?
A: It's a city that can be guarded by finitely many near-sighted
   policemen.
--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de