• I've got 2 pucks.

    1. I've replaced their batteries and updated to firmware v97.
    2. I've uploaded same code via Web IDE.
    3. One puck is happy and working all the time.
    4. The other puck, after ~2-3h, will start blinking red.
    5. It advertises as "Puck js XXX" instead of my name (which means it's reset itself and not running my code)
    6. When trying to connect via Web IDE, it shows up on the list but then "error connecting" pops up.
    7. Nail-reset doesn't help.
    8. Taking out battery and reinserting after 1min allows to connect again, re-upload code.
    9. After ~2-3h, it will start blinking red again.

    What can I do?

  • Are you sure it's not just a dead battery? I know you said you replaced them but occasionally you do get bad ones. You could check Puck.getBatteryPercentage() when you are able to connect via the IDE.

    You can also try doing a full reset - hold the button down while flicking the coin cell so the green LED comes on, then keep holding through all 3 LEDs lighting, and the red LED blinking multiple times - then keep holding an extra second. Anything that was then saved to nonvolatile memory would be wiped out.

  • Ok, so the same puck, problems again.
    It went AWOL from BL on may 27...

    Take a look at the attachment - two puck.js, one had battery 100% for months, the other one got fresh battery, was near 100%, then started fluctuating weirdly and then drained itself to 0% within 2 weeks. Both run the same code.

    I gave it a fresh battery yesterday. Today it started flashing red again. I did a full reset moments ago - waited through the last few red blinks. After that - dead. No bluetooth advertisement, soft-restarting does nothing, holding the button while restarting doesn't even show the green LED.

    I'm puzzled as to what is happening with it :-(

    1 Attachment

    • Screen Shot 2018-06-11 at 8.06.17 PM.png
  • What happened after my last reply 1 month ago? Did it turn out just to be a dead battery?

    What worries me is there's a pretty regular dip on battery voltage (twice a day?) that makes it seem like some code is running that's using up the battery. Of course it could just be the temperature of the cell affecting it, but if so you'd expect it to repeat once a day, not twice.

    The overall shape of the graph is what you'd expect - the percentage from getBatteryPercentage is pretty crude and is based off the battery voltage. It varies depending on manufacturer so it's not accurate, but when the battery gets mostly flat the voltage tends to drop off a cliff (google images for 'cr2032 discharge curve') and Puck.js doesn't take account of that in the calculations.

    Is it possible that you have some PC or phone that is attempting to connect to the device? if you have no code on there then that is one option - having a connection open wakes the device up ~25 times a second which really hurts the power consumption, and can run it down in a matter of days.

    There's some info on stopping unwanted connections here: http://www.espruino.com/Puck.js+Security­

    But if it's not responding at all - given the troubles so far - I'd suggest trying another battery. Maybe the batch of replacement batteries you got are a bit dodgy. Doing the 5 blink reset will erase flash which uses a lot of battery power, so if it was low on battery than that could have pushed it over the edge.

  • Ok, checked that no other devices are trying to connect to it. Even having an open browser tab wouldn't work because the browser kills those web bl connections.

    After you message last month, I've given the pug a fresh battery - unsure if the old one was dead or not (didn't measure).

    I went to bed after reading your last reply, the puck was "dead". In the middle of the night it started flashing red again, then stopped. It's doing that now every few hours, so the battery is not dead.

    Just tried hard-resetting it again few moments ago -- puck is dead again, not responding to more resets, not advertising, nothing. I've also inspected the reported battery levels right after changing the battery on June 10th (see attachment). Started fluctuating 2h after replacing the battery, went down to 80% and stayed there until it stopped advertising and began to blink red.

    I'll buy new set of batteries tomorrow, from a different place (to have a chance of different batch). Maybe the current ones are super dodgy, although it wouldn't explain the second puck which is happy with its cell :

    1 Attachment

    • Screen Shot 2018-06-12 at 12.53.49 PM.png
  • Assuming you can connect you could try:

    NRF.on('connect', function(addr) { LED3.set(); });
    NRF.on('disconnect', function(addr) { LED3.reset(); });

    Just to rule it out - it'll light the blue LED if some other device tries to connect to it after the code is uploaded.

    If this continues with new batteries then you can send it back if you want and I'll take a look at it?

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview

Is my puck dead? (blinking red, cannot connect)

Posted by Avatar for Thinkscape @Thinkscape