This should work with the latest firmware:
var list = []; list[0] = 10; list[1] = 20; list[2] = 30; list[3] = 40; list[4] = 50; list[5] = 60; list[6] = 70; var s = E.showScroller({ h : 40, c : list.length, draw : (idx, r) => { g.clearRect(r.x,r.y,r.x+r.w-1,r.y+r.h-1); g.setFont("6x8:2").drawString(list[idx],r.x+10,r.y+4); }, select : (idx) => console.log("You selected ", idx) } ); setInterval(function(){ list = list.map(i => i-1); s.draw(); }, 1000);
@rigrig started
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
This should work with the latest firmware: