Smartwatch considerations

Posted on
  • I am considering using the Espruino to power a smartwatch. I am a mediocre coder with a fair amount of experience with JavaScript. How would I go about connecting a screen to the device? I know the screen is SPI, but wherever I have used it before (arduino) I have been able to use libraries. Would I have to figure out how to communicate directly with the device, or are there some tricks I could use? If i have to just figure it out, where would some of you more experienced coders recommend I research my question further?
    Thanks!

  • What is the display device type?

    Here is an example - you will need to use the library appropriate for your device

    http://www.espruino.com/SH1106

  • The driver's IC is ST7735. its a 1.44" display 128*128 pixels. ok thats good to know that the Espruino has these kind of libraries.

  • So I have access to a working library for the screen using the Arduino's C++ code. could I use this to write my own library for the screen?

  • Searching on the esprino site for that device code comes up with

    http://www.espruino.com/ILI9163

    So looks like you could use that library

  • Great! that's helpful, thank you. One further question; In my code, I have the image processed as an SVG file. Would I be able to store an SVG on the Espruino, and, If so, How would you recommend taking this, and sending it to the screen?

  • You wouldn't be able to render an SVG directly - you'd have to get it as a bitmap first. Once you have a bitmap there's some info on loading it into Espruino on this page - including a webpage that'll create the code for you when given an image: http://www.espruino.com/Graphics

  • ok. so would I be able to take my svg, convert it to bitmap, then send it to the screen all on the board? Or would it be better to use the graphics library to recreate the design?

  • Ahh - so you have an SVG that you plan to animate? You wouldn't be able to render it straight on the board - so it'd need doing beforehand.

    You could convert all the different combinations of it to bitmaps and composite them together on the Espruino, or you could possibly export the different parts as polylines/polygons and then render those on the Espruino with the graphics lib?

    But as you suggest, in the end it might just be easier to use the Graphics lib directly

  • Yeah so it does sound like the best/easiest option might be to redo the code. *sigh. Such is the life of a programmer. Great! I think this will do what I want it to do. Or at least, something very close.

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

Smartwatch considerations

Posted by Avatar for user79029 @user79029

Actions