Espruino – JavaScript interpreter for micros

We usually program microcontrollers with some language like C, ASM, then compile it in to binary and upload to execute. But this is not the only way to do this. We can have a piece of code running inside MCU and execute new commands sent to them. If you put these commands in to single file – you get script. One good example is BASIC where we used to write programs for PC based interpreters.

JavaSript is high level language with lots of handy features compared to BASIC. It has map, object, garbage collection. JavaSript is still intensively used in webpages for dynamic content. So there is plenty of code examples and tutorials. Why we would need an interpreter for MCU? Simply speaking this is great way in testing simple things on hardware. You can run single commands, run loops by simply sending those over serial terminal. It currently is designed for STM32VLDiscovery board but other hardware support should be there soon.

No Comments

Leave a reply