Avatar for DBovey

DBovey

Member since Sep 2019 • Last active Nov 2019
  • 2 conversations
  • 9 comments

First name is Dominique.
Electronics engineer (mostly analog), researcher and wanna-be maker.
Trying to learn JS, which is some work for me, as my only programming mindset is C language on small microcontrollers. Purely procedural-minded, and object-oriented + event-drive is not natural for me.
Interesting in using pixl and other devices for house automation (OpenHAB)
I start with the Pixl+multi badge as learning platform as there are nice LEDs etc.

Most recent activity

  • in Puck.js, Pixl.js and MDBT42
    Avatar for DBovey

    Thank you for your answers! I hadn't found the 2018 badge on github, only the 2017 one (which wasn't marked 2017).
    I have now downloaded the zips of both projects to my PC, with the aim of making pdfs of the 2018 one. I dont use Eagle, but I'll import them to Altium, which I know how to use.
    Do you think I could then upload the pdfs to GitHub?

    • 7 comments
    • 440 views
  • in Puck.js, Pixl.js and MDBT42
    Avatar for DBovey

    Update: Problem partially solved! The "save" code at the end was the culprit, I commented it out and it seems to store the code on flash. Does the IDE have a setting for that?
    BUT: after saving, the BT link is gone. I cannot connect any more to the Pixl-multi, unless I erase the project code from it. Actually if I switch the device on (with the application code) while trying to connect, the communication link is visible for a couple seconds, then no more.

  • in Puck.js, Pixl.js and MDBT42
    Avatar for DBovey

    *> @DBovey would you mind posting the link to the original official badge.js code please so that we may follow along with that source which originally worked.

    Writing an effective forum post*
    

    Thanks for the advice, I'm a noob in the forums etc and maker universe

    @Robin I took badge.js from git, downloaded to my pc, changed NAME variable and recopied to https://github.com/dbovey/espruino/blob/­master/Badge_original.js but cannot for the universe's sake find where it was originally on git or somewhere else (it was between 2 and 3AM)...
    (I'm really new to all the git stuff, I will have to ask to my colleague to get an understanding of the whys and hows of git. Bit more used to svn but I'm basically a HW guy)
    What are the results of process.env
    process.env
    ={
    VERSION: "2v04",
    GIT_COMMIT: "3956264e",
    BOARD: "PIXLJS",
    FLASH: 524288, RAM: 65536,
    SERIAL: "88eb467e-a9e672fe",
    CONSOLE: "Bluetooth",
    MODULES: "Flash,Storage,hea" ... "el,graphical_menu",
    EXPTR: 536882408 }

    Could this - Cube Badge be the source?
    no
    I did a dump() and the result is interesting:

    dump();
    Graphics.prototype.setFont8x16 = function () {this.setFontCustom(a,32,b,16)};
    var NAME = [
    "First Last",
    "Organisation"
    ];
    var cityscape = { "width": 128, "height": 16, "bpp": 1,
    "buffer": new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 2, 0, 0, 32, 0, 0, 4, 0, 0, 0, 0, 0, 252, 0, 128, 0, 7, 0, 0, 112, 0, 0, 4, 0, 0, 0, 0, 0, 252, 0, 128, 0, 7, 0, 0, 248, 0, 0, 12, 0, 0, 0, 0, 0, 252, 0, 128, 0, 7, 0, 0, 248, 0, 0, 12, 0, 0, 0, 7, 0, 252, 0, 128, 0, 7, 0, 0, 248, 0, 16, 12, 0, 0, 0, 7, 8, 252, 1, 192, 3, 199, 0, 0, 248, 0, 56, 12, 0, 0, 0, 7, 28, 252, 1, 192, 3, 199, 62, 0, 249, 224, 124, 12, 1, 224, 0, 7, 62, 255, 195, 224, 3, 199, 62, 0, 249, 224, 254, 13, 249, 224, 24, 31, 62, 255, 195, 224, 3, 199, 62, 0, 255, 224, 254, 13, 249, 224, 126, 31, 62, 255, 199, 247, 195, 199, 62, 62, 255, 224, 254, 13, 249, 225, 255, 159, 62, 255, 199, 247, 255, 199, 62, 62, 255, 248, 255, 205, 249, 227, 255, 223, 62, 255, 199, 255, 255, 199, 62, 62, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255]).buffer
    };
    var ctlogo = { "width": 31, "height": 15, "bpp": 1,
    "buffer": new Uint8Array([7, 224, 15, 254, 48, 48, 0, 0, 143, 0, 63, 250, 97, 128, 5, 5, 0, 0, 10, 18, 0, 0, 20, 40, 0, 0, 40, 80, 0, 0, 80, 160, 0, 0, 161, 32, 0, 1, 65, 64, 0, 2, 130, 97, 128, 5, 2, 60, 0, 10, 3, 3, 24, 20, 1, 248, 48, 40, 0]).buffer
    };
    var n = 0;
    function draw() {?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255]}
    function onInit() {?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255]}
    =undefined

    I opened the badge_original with notepad++ and I cannot see the issue at function draw() at L41 of the code. the issue is exactly the same in my badge_simple.js which has just a couple of graphical changes to center the displayed NAME.

  • in Puck.js, Pixl.js and MDBT42
    Avatar for DBovey

    Sorry @AkosLukacs for my incomplete post :-(
    > Just to clarify, you have this badge, right?
    @AkosLukacs Yes the pixl multicoloUr from the espruino shop

    > First thing to try would be to reset(1) to remove everything from flash, possibly you had too much in memory, or remains of a previous experiment mess up something.
    reset(1) says it erases the flash, but does not solve
    > And do some basic sanity check - do the basics work?
    entering this on left hand side and to the RH side as a JS file:
    var l;setInterval("digitalWrite(LED1,l=!l);"­,200);
    blinks the LED

    > Or try the Returning to Standard instructions on the docs page.
    I reflashed the espruino v2.04 code anew and then erased the flash using the BTN1 manipulation. (maybe should I have done that in reverse?)
    Did not solve.
    Thanks for your help!

  • in Puck.js, Pixl.js and MDBT42
    Avatar for DBovey

    And after playing with the badge extensively, it doesn't execute the code official badge.js code any more. Although some variables are set, see left-hand window log below.
    The code is at:
    https://github.com/dbovey/espruino/blob/­master/Badge_simple.js
    It is just the badge.js code with minor modifications.
    Running onInit()...
    Uncaught SyntaxError: Got ?[255] expected EOF
    at line 1 col 4808
    ...?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255]...

                                                                                                                                                                                                                                                                                                                                                                                                     ^
    

    at line 1 col 1
    ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255] ?[255]...

                                                                                                                                                                                                                                                                                                                                                                       ^
    

    in function called from system

    NAME
    =[
    "Hello",
    "World"
    ]
    cityscape
    ={ width: 128, height: 16, bpp: 1,
    buffer: new Uint8Array([0, 0, 0, 0, 0, ... 255, 255, 255, 255, 255]).buffer
    }

  • in Puck.js, Pixl.js and MDBT42
    Avatar for DBovey

    Working on a pixl+multi for a first project to learn JS: a universal conference badge, as geeky as possible. I'm not used AT ALL to the object and event-driven aspects of JS (my only programming experience is C on micro-controllers).
    I often tinker on the train so I changed Web IDE to offline.

    @Gordon: would it be possible to opensource the pixl+multi, including HW? Obviously the schematic is quite different from the nodeconf badge and I'm a bit lost.

  • in Other Boards
    Avatar for DBovey

    Thanks. As this is quite involved, I'll get back to it later.

  • in Other Boards
    Avatar for DBovey

    Hi all, when doing a readAnalog on a NucleoF411RE Espruino, how is the ADC configured? I tried to find that in the espruino doc, then in the espruino github, did not find.
    Thanks all!

Actions