Avatar for Mrbbp

Mrbbp

Member since Mar 2017 • Last active May 2024
  • 34 conversations
  • 187 comments

I'm newb with espruino, not with arduino, not with js...
But i'm not a coding ninja

Most recent activity

    • 6 comments
    • 278 views
  • in Pico / Wifi / Original Espruino
    Avatar for Mrbbp

    thank you.
    i do not investigate which baud i could use.
    I've tried with 32Mbits and a delay of 50ms between each frame. It works but i take 0.4s (30 percent better) but 2.5 frame/sec.
    and with an ugly scanning refresh.

  • in Pico / Wifi / Original Espruino
    Avatar for Mrbbp

    i tried with an hardware spi, but I don't save much time. 1 tenth of a second

    SPI2.setup({mosi:B15 /* sda */, sck:B13 /* scl */, baud:integer=1000000,});
      g =require("ST7735").connect({
        palette:colorPalette,
        spi:SPI2,
        dc:A7,
        cs:B10,
        rst:B1,
        padx:2,
        pady:3
        // height : 160 // optional, default=128
        }, ecrit
      );
    
  • in Pico / Wifi / Original Espruino
    Avatar for Mrbbp

    Hello, i'm back from a long circuitpython session...

    I'm playing with a small 128x128 SPI TFT display with a short generative prog

    const s = require("Storage");
    const largeur = 32;
    function ecrit() {
      console.log("écrit");
      g.clear();
      var start = getTime();
      for (let y = 0; y<128; y+=largeur) {
        for (let x = 0; x<128; x+=largeur) {
          if (Math.random()>0.5) {
            g.setColor(1);
            g.fillRect(x,y,x+largeur,y+largeur);
          } 
        }
      }
      print("dessine:",getTime()-start);
      g.flip(); //<--- Send to the display
      print("affiche:",getTime()-start);
    }
    
    var g;
    function onInit() {
      var colorPalette = new Uint16Array([0xFFF, 0]);
      // init spi
      var spi = new SPI();
      spi.setup({mosi:B15 /* sda */, sck:B13 /* scl */});
      g =require("ST7735").connect({
        palette:colorPalette,
        spi:spi,
        dc:A7,
        cs:B10,
        rst:B1,
        padx:2,
        pady:3
        // height : 160 // optional, default=128
        }, setInterval(ecrit, 500)
      );
      console.log("## mém. used: " + Math.round(process.memory().usage / process.memory().total * 100) + "% ##");
      s.getFree();
    }
    

    But the display take 0.65sec to screen the picture drawn in .02s
    Is there a way to send faster to the display?
    and avoid image scanning?

    regards

  • in Pico / Wifi / Original Espruino
    Avatar for Mrbbp

    hello @AdaMan82
    sometime pico have strange behavior too and crash with clean code.
    reflashing take few seconds than trying to identify uncommon behavior in code is timeconsuming.
    i downloaded last firmware to avoid low connexion :)
    regards

  • in Interfacing
    Avatar for Mrbbp

    Thanks @Gordon .
    i bought at lextronic french reseller (with more stock) sorry for that, i prefer buying on your shop)
    i bought an MDBT42Q breakout to try and some pico cause i love form factor.
    next week it's holliday and have some time to play with

    best regards
    é.

  • in Interfacing
    Avatar for Mrbbp

    ok nobody want helps?

    is the Module MDBT42Q Breakout is enough to start?
    convert it as a bluetooth HID like a keyboard?
    i read some post about that.
    if the device (the breakout) is detected as an hid bluetooth by the os, the html page doesn't have to detect an hid!? it's a keypress detected, no more.

    é.

  • in Interfacing
    Avatar for Mrbbp

    Hello,

    i'm new with bluetooth.
    i would like to connect a rotary encoder to an ipad or an android phone and use the rotation in a web app.

    i'm able to connect the rotary and a pico board to an html page trough the HID feature on my computer.
    but now i would like to communicate to a smart thing (small screen,,,) device via BT.

    Which board do i need to do that, is BT, the good solution ?
    Please advice me.

    regards

    éric

    ps: @Gordon there is only one unpinned pico board in stock in the shop! really?

Actions