espruino / espruino/BangleApps
[dtlaunch] Error on console and 1st page doesn display images
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 572
- Forks
- 1.3k
- Avg merge
- 17h 38m
- Merged PRs (30d)
- 17
Description
Affected hardware version
Bangle 1
Your firmware version
2v16
The bug
Scenario: After launching the app, 1st page is empty, moving with btn3, so moving to next app, then the icon for second app is displayed and so on.
Expected: 1st page show 6 icons for apps
Checking on IDE, the app start with following errors:
2v16 (c) 2021 G.Williams
Uncaught Error: Expecting first argument to be an object or a String
at line 14 col 211 in dtlaunch.app.js
...con),x+10,y+10,{scale:1.25});g.setColor(-1).setFontAlign(0,-...
^
in function "draw_icon" called from line 15 col 218 in dtlaunch.app.js
...return i;draw_icon(p,i,selected==i);}
^
in function "drawPage" called from line 22 col 11 in dtlaunch.app.js
drawPage(0);
After clicking btn3, error on console:
Uncaught Error: Expecting first argument to be an object or a String
at line 52 col 64 in dtlaunch.app.js
...con),x+10,y+10,{scale:1.25});
^
in function "draw_icon" called from line 77 col 57 in dtlaunch.app.js
if (oldselected>=0) draw_icon(page,oldselected,false);
^
in function called from system


Installed apps
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue on a Bangle 1 running firmware 2v16, then inspect dtlaunch.app.js around draw_icon and drawPage(0), as identified in the console trace. Confirm that the first page renders six app icons and that moving between pages no longer produces the reported argument error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- embedded-iot
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100