[U-Boot-Users] ability to do simple math in u-boot shell?

I can't seem to find anything that says we can do thus, but wondering if there was any way to get simple math (addition) out of the u-boot shell? Was looking for something like 'expr'.
- k

On Tue, 12 Feb 2008 23:45:35 -0600 Kumar Gala galak@kernel.crashing.org wrote:
I can't seem to find anything that says we can do thus, but wondering if there was any way to get simple math (addition) out of the u-boot shell? Was looking for something like 'expr'.
hush doesn't do expressions - everything's a string - you need to import something like shell/ash.c from the busybox package into u-boot. If you have an extremely limited amount of math, it can be done with trivial comparison logic already available in hush.
btw, u-boot users and developers should start prepending new hex values with "0x", btw.
Kim

In message 20080213005605.9e6d9a3d.kim.phillips@freescale.com you wrote:
btw, u-boot users and developers should start prepending new hex values with "0x", btw.
Nope. Please don't. U-Boot standard input base is hex. Has always been that way. 0x is just a waste of key presses and memory footprint.
Best regards,
Wolfgang Denk
participants (3)
-
Kim Phillips
-
Kumar Gala
-
Wolfgang Denk