You are reading a single comment by @fanoush and its replies. Click here to read the full conversation.
  • Thanks @Gordon for your suggestions. I will try it for sure. Since there is already Arduino library available, will it be worth to try to add the C code in Espruino src as a lib and compile it locally? As you are doing with microbit, hexbadge and BangleJS as a same way add my C code in lib folder and compile?

    Another question, what will happen if there is an un-handled exception in Espruino? A restart/reset?

    To get some ideas, look at the Espruino event object.

    @allObjects, As I am exploring all available option, I would like to know where I can fine re information about is Espruino event object?

  • Since there is already Arduino library available, will it be worth to try to add the C code in Espruino src as a lib and compile it locally?

    If it is worth to you then go on. However arduino (C++) code and Espruino C code can be quite different so it may not be trivial to port arduino library to espruino. C module is necessity if you cannot do it in JS (no JS api exposed) or for performance reasons. However you lose the modularity. Anyone using same sensor would need to build own espruino version. If you do it as JS module the code can be put here https://www.espruino.com/modules/ and people can use it without custom Espruino build.

About

Avatar for fanoush @fanoush started