Pixl.js 2v09 Pixl.js Menus Submenu freezing

Posted on
  • Hi
    i am new with a pixl.js firmware 2v09.
    I'm just trying around a bit and came across a problem that I don't understand.
    I just used the demo code for menu.
    https://www.espruino.com/Pixl.js+menu#so­urce-code

    When I transfer this code to my Pixl.js and go into the submenu ("Second Menu"),
    it doesn't react anymore when I press a button.
    I can neither go up and down the items nor select the item.

    Is there something I need to be aware of here?

  • Wow, thanks for letting me know about this.

    I'm just looking into it - it seems like clearWatch in 2v09 started clearing the pin pullup state. You can add the following code to your program to fix this, but I'll get to work on a fix and pushing a version 2v10 out now.

    _clearWatch = global.clearWatch;
    global.clearWatch = function(w) {
      if (w===undefined) return _clearWatch();
      var pin = global["\xff"].watches[w].pin;
      var s = getPinMode(pin);
      _clearWatch(w);
      pinMode(pin,s);
    };
    
  • Ok, just fixed - the latest build from https://www.espruino.com/binaries/travis­/master/ should have the fix in now, and I'll work on getting a 2v10 release out later today. I'm honestly surprised this hasn't hit more people.

  • Thanks for the quick reply.
    I would have expected more people to notice such a problem, too.

    After I updated to 2v10, it also works as expected :)

About

Pixl.js 2v09 Pixl.js Menus Submenu freezing

Posted by Avatar for Roxas @Roxas

Actions