I have developed some pure-Lua libraries and I'd like to check if they work correctly in eLua.
The first lib I'd like to try is inspect.lua (https://github.com/kikito/inspect.lua). I would like to adapt it to eLua's idiosincrasies (for example, I want to make it print romtables correctly).
But I have no idea about how to go about it. The embedded world is something that I have yet not delved into.
Can I install eLua in my computer? The docs I found seemed to indicate that it can must compiled against one of several targets, replacing the operative system even. What I would need is some kind of elua executable, which can be executed from the command line. Maybe I need to execute it over some kind of emulated chip?
I have a battery of automated tests which are tested against Lua5.1, Lua5.2 & LuaJIT on Travis-CI:
> There's a (very much undocummented) way to run eLua in a "simulator" environment under Linux, would that work for you?
It depends on the simulator. The automated tests are run on Travis-CI, which provides (virtualized) Linux machines. So I can install any software I need for the tests. But in order to make them work I would need the simulator to be scriptable - I would need to tell it "copy these Lua files on the emulator, run this script, and give me the results back" in a non-interactive way. And I can not depend on any external hardware at all.
> I need for the tests. But in order to make them work I would need the
> simulator to be scriptable - I would need to tell it "copy these Lua files
> on the emulator, run this script, and give me the results back" in a
> non-interactive way. And I can not depend on any external hardware at all.
The eLua simulator is an elf file you can run directly on your GNU/Linux.
You'll need i686-gcc to generate the executables. You can get the toolchain
The eLua simulator is exactly like regular eLua on an MCU but it runs in
user space. Of course, you can't access any MCU specific peripherals but
you can access term, elua, pd and cpu platform modules.
There's no way to instruct the simulator to behave in a non-interactive way.
You'll still have to launch Lua from the eLua shell and write your programs