lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Just a brief note to say that I've successfully ported Lua 5.3 (work1) to the LEGO MINDSTORMS NXT platform, an extremely memory constrained ARM7 based device with only soft float support.

<http://www.hempeldesigngroup.com/lego/pblua>

I set up Lua to use int and float as the basic numeric types, and after a bit of struggle with my custom vfprintf() and getting bitten by the difference between fmodf() and modff() things worked pretty well.

On a simple loop iteration, I found that floats took about 3 times as long as ints, which is decent for soft floats.

The whole thing (including the NXT drivers and a binding to Lua) runs in about 138K of FLASH and I have 58K of the 64K of RAM available.

I do have to run the gc pretty aggressively because it's impossible to double the requested RAM more than once or twice after startup :-)

Thanks again to the three amigos for making one of the only tiny languages that will fill this niche. The alternatives (I tried them) were Forth and Scheme :-)

I'll go so far as to say it's the only tiny infix language I have found that's supported by a fantastic reference manual, book (PiL), and relatively noise free community mailing list.

Cheers, Ralph