so if i add an init.lua to the rom filesystem that one will run ?
i want to make a small self starting lua script that checks for the presence of a flash memory on spi or i2c. if the memory is found and it contains a specific signature it will create a new file in the write once filesystem and copy the data from the eeprom over. this then becomes a new lua program that is called and launched.
Think of it as a small LUA bootloader.
lua starts and then launches my loader. this loader checks for the existence of an eeprom. if it exists : read signature. then : check eif app.lua exists in internal worm. if it does : compare signatures. if they match :run app.lua. if they dont match : cope eeprom contents in new app.lua and then launch app.lua
the idea is to have the control program for a sensor reside in the sensor. if i plug it into the system (lua based) this will detect the sensor and automatically install the driver for it.