You are reading a single comment by @Gordon and its replies. Click here to read the full conversation.
  • You would have to set the correct bits up in the arraybuffer g.buffer. Maybe:

    var Graphics = { createArrayBuffer : function(x,y,bpp,flags) {
      return { buffer : new ArrayBuffer(x*y*bpp >> 3); }
    }};
    var g = require(lcd).connect...;
    var a = new Uint8Array(g.buffer);
    a[0] = 0b01000010;
    a[1] = 0b00100100;
    a[2] = 0b00011000;
    a[3] = 0b00100100;
    a[4] = 0b01000010;
    g.flip();
    

    There is no way to 'just' draw text at the moment on ESP8266.

    If you used a proper Espruino board you wouldn't have that problem as there's a Graphics class with lines, text, etc built-in.

    But until someone manages to compile that into ESP8266 you're out of luck.

About

Avatar for Gordon @Gordon started