Pixl.js - dead? no surely not :-(

Posted on
Page
of 2
/ 2
Next
  • Hi, I've had my code running on my Pixl.js none stop for a couple of days and it's been working fine for a couple of weeks. It is connected to 2 ina226 and has been merrily monitoring voltage of 2x 12v Campervan batteries.

    I've got web page that pulls data from the Pixl when I click a button and draws a graph. Everything has been hunky dory.

    But, I just flashed a tiny tweak to the board (changing the interval variable). I wasn't sat next to my Pixl but couldn't connect. I looked at the board and nothing was being displayed.
    I've checked the power leads etc but I'm not getting anything out of my board. I've tried disconnecting the ina226 boards, still nothing.

    I haven't cooked it I am convinced.
    As you can guess I'm a bit gutted at the moment.

    Any help will be gratefully received. I've got a Puck on order as I love these devices..

    Thanks


    4 Attachments

  • Sun 2020.09.27

    'merrily monitoring voltage of 2x 12v Campervan batteries'
    'I haven't cooked it I am convinced'
    'I've checked the power leads'

    While it isn't detailed, and the Pixl was running, just for confirmation as there could be many wiring variants, Is the board powered by just one 12V and not by both? ref: '2x 12v'

    Some ideas: As the WebIDE shows green connected then amber dis-connected, Is there any additional detail shown in the WebIDE log?
    WebIDE >> Settings >> Console

    What PC OS is in use? I've had issues after flashing on Windows10 requiring closing, detaching, re-powering, re-pairing and re-launching the WebIDE.

    Any chance a fresh CR2032 could be used to test away from the van?

    Upload a simple .js test code snippet to illuminate the backlight.

  • Hi, the board is powered by the van's USB outlet so the 12v is only on each ina226.

    I've attached the IDE log. The only thing that I can see is the end of my code, some control characters then a log error.

    console.log(btoa(output.substr(i,384)));­\\n}\",3072);\n\u0010\u001b[5dload()\n\n­"
    Splitting for reset(), delay 250
    BT> SEND ERROR: NotSupportedError: GATT operation failed for unknown reason.
    

    I'm using Windows 10. I've tried the Pixl using a number of USB outlets/plugs. When it is plugged in nothing appears on the screen (at all). I've tried using my phone to see if BLE is running but the screen isn't displaying anything, again nothing being detected.

    Thanks


    1 Attachment

  • I've just tried powering my Pixl with a brand new CR2032.
    No sign of life on the screen and no sign of Bluetooth either.

  • .

  • Hi @saj42 and thank you for providing that detail.

    I haven't a development PC nearby, so doing this from memory. Your hunch appears proven as; It appears the Pixl is running as the log indicates, confirmed by matching WebIDE image in #1 post.

    Have the steps in #2 post been tried to see if the disconnect message disappears on subsequent re-tries? Or, does the same sequence result?

    If connection is successful, not sure if the backlight is independent of the LCD itself, but a quick test wouldn't hurt. If memory serves, typing the following (below), the WebIDE should echo the typed content by viewing the same console output, as we are updating via B.T. This would loosely confirm that the PC and WebIDE are working together and the issue is pointing to the LCD itself.

    Type LED.set() into WebIDE and see if the backlight illuminates.

    https://www.espruino.com/Pixl.js#onboard­
    https://github.com/espruino/EspruinoBoar­d/blob/master/Pixl.js/pdf/pixljs_sch.pdf­



    Any chance the LCD ribbon cable has come loose?

  • Hi @Robin. I'm not entirely sure I got your last post, sorry if I got the wrong end of the stick.

    The Pixl was running fine, I sent a tweak of the code over the the Pixl and it then failed to connect using the WebIDE. I checked the physical device and nothing was being displayed on the LCD (I've checked the LCD ribbon).
    I've tried different power supplies / batteries without success.
    The WebIDE doesn't display my specific device when I attempt to connect.
    Web Bluetooth doesn't find my device when the dialog appears and I've tried on a couple of devices just in case it is a problem with my laptop.

    Thanks

  • What happens if you plug the Pixl.js into power while holding BTN1 down? That should enter the bootloader and display something on the screen unless there's an issue with the hardware. If you keep holding (until the ==== have gone across the screen) it'll also boot back into Espruino and do a self test (and if you keep holding even when it tells you to release the button it'll boot without loading any code, then you can flash your code to it again).

    Another thing to look out for is if the backlight flashes at boot. That's normal, but if the backlight is flashing but the screen isn't displaying anything it might be an issue with the screen?

  • Doh, I forgot to mention I'd tried that. Thanks

  • Hi, I cannot get the screen to show any sign of life, either powering up normally or via the hard reset.
    The backlight also doesn't show any signs of life.

    Thanks

  • Hmm, that doesn't sound good. And you have completely unplugged it from everything now?

    Do you have a volt meter? Maybe you could check the voltage on the 3.3v wire and see if it has anything on it. If not I guess there could be a short somewhere?

  • Hi as follows. Hopefully I checked the pins you meant.
    Pins annotated on the image.

    1/5 = 3.3v
    1/4 = millivolts
    2/5 = millivolts
    2/4 = 0v
    3/5 = 0v
    3/4 = millivolts


    1 Attachment

    • Annotation 2020-09-28 155143.jpg
  • Ok, thanks - well that's not a great sign then I'm afraid.

    If there's power, and no flash of the backlight or activity on the LCD I think it might be dead. There's a small possibility that the bootloader/espruino firmware on the chip has got erased somehow but that is very unlikely - I haven't heard of that happening to date and there are some failsafes in there to stop Espruino accidentally overwriting the bootloader.

    If you had an SWD dongle you could try connecting to the SWD pins (you can see them shown top-left of the image you included) and see if you have any success re-flashing the firmware, but I don't hold out much hope.

    You mentioned you were powering it from a 5v USB adaptor - is there any possibility that you could have got 12v onto the IO pins at any point?

    The INA226 have to measure everything relative to GND so if you connected each one to GND of each battery, then connected the batteries in series for 24v, one of the INA226 could have been at 12v relative to the Pixl. Does that seem possible?

    Looks like you're in the UK though? You could send it back here and I can have a go at re-flashing?

  • Hi @Gordon

    is there any possibility that you could have got 12v onto the IO pins
    at any point?

    I can't see how that could have happened.

    I've drawn a schematic. The van is a campervan with all appropriate fixtures and fittings.
    The electrics (USB/ leisure battery/charger etc) was fitted as part of the conversion done by athe company that did the conversion.

    I pulled all grounds together on my breadboard ie
    1 from Pixl
    1 from each ina226
    1 from the van

    I've not put the lines in for SCL/SDA as it just clutters the drawing.

    The INA226 have to measure everything relative to GND so if you
    connected each one to GND of each battery, then connected the
    batteries in series for 24v, one of the INA226 could have been at 12v
    relative to the Pixl. Does that seem possible?
    Not that I can see.

    What confuses me is that the setup had been working for days without issue. I'd stopped / started it a number of times.
    Is it possible the reboot (due to revised code) caused the problem?

    The DS300 is the CBE distribution box. +B1 and +B2 are the leisure and normal van battery.
    Thanks


    1 Attachment

    • PixlSchematic.jpg
  • It does seem odd - so -B2 in the junction box is definitely GND, and is also -B1?

    There's a chance that changing the code caused a problem but if so it wouldn't be a hardware issue. I've shipped over 10,000 devices with nRF52 and this kind of bootloader and this would be the first issue I've had though...

    I'll send you an email about returns and I'll have a go with it. I'm not sure there's much you could do at this point (apart from wiring up an SWD adaptor) - but if it's not obviously fried from 12v it's something I'd repair for free.

  • Hi, thanks @Gordon I've got he email so I'll arrange to send it back.

    so -B2 in the junction box is definitely GND, and is also -B1

    It's -B1 and +B1 and +B2

    Thanks. Problem tracing is part fun part patience....

    Steve


    1 Attachment

    • PixlSchematic1.jpg
  • Just got your Pixl back here today - there's good and bad news :)

    I reflashed the software and it comes right back up and works - however the MAC address shows ff:ff:ff:ff:ff:ff. That actually comes from a place in the chip called FICR - the manual says:

    Factory information configuration registers (FICR) are pre-programmed in factory and cannot be erased by the user. These registers contain chip-specific information and configuration.

    So somehow, something has caused the chip to get completely erased, even the bits that should never be allowed to get erased! Honestly I'm a bit stumped because I'd have thought that if it were related to a high voltage it'd have fried the chip.

    I've never seen anything like it before - I'll get a new one out to you now, but when you re-add it to the campervan please can you check the voltages on all the IO pins before you plug them in, just in case the issue was caused by an out of range voltage?

  • Wow thanks @Gordon.

    Erasing unerasable data.... Interesting.

    I'm pretty convinced it wasn't out of range voltage as the device had been running for days, unless a reflash somehow directed voltage in an unusual direction

    I'll make sure I flash the device when the Pixl.js is not connected to any sensors.

    Thanks for the support and I'm semi glad it stumped you because it fuddled my brain.

  • Would be nice to have a BT Mac address of FFxFF :D Wouldn't that be unique?

    Also, if this is a campervan and probably would be out and about the weather, maybe you can try getting the MDBT42Q breakout board for a permanent installation?

    What I personally do is to try things out on my Pixl and when the code / connections are ready I use an MDBT42Q breakout instead. It's cheaper (so I won't feel as bad if/when it crashes and burns) and smaller, so it's easier to get it in an enclosure for waterproofing. Maybe even bathe it in some hot glue or epoxy/resin with some terminals sticking out for the ultimate in weather protection.

    Glad to know the Pixl survived. I'm quite surprised at how resilient these boards are (I had a post here where I plugged in the lipo backwards on an MDBT42Q breakout and it only killed the voltage regulator, preventing damage to the actual chip).

  • Dealing with various power circuits poses the danger of over voltages. To be safe, a particular connect / disconnect sequence has to be followed as well as grounds have to be solidly shared and connected first and disconnected last.

  • :-) yes a unique ff:ff:.. Mac address @parasquid....

    It's going within the cabin of the vehicle so no issue with waterproofing and a screen is why I purchased it.
    The screen shows normal vehicle battery voltage and also the voltage of the leisure battery so that's really useful when I'm using the fridge, lights etc especially when 'off grid' for a few days. I may find that I prefer my web page display of the data anyway.

    It's all a bit of plotting and playing at the moment as I'm also looking to switch some internal lights.
    I've just purchased a Puck and also a Mirco:bit.

    Thanks
    Steve

  • Thanks @allObjects
    :-) it was up and running when the issue occurred and had been for days. The connects had been in place for a number of days.

  • For quite some time I wanted to control the charging and discharging of battery/ies of stationary and mobile photovoltaic system to gain some insight. Most recent I looked into the Maxim MAX17261, which is even better than a good coulomb counter, and coulomb counters already deliver pretty good information about the charge state.

    For a long time I was looking for measuring on the hight side, and there are sensors that can measure current on the hight side. With the prevalence of LiIon. and LiFePO4 - which need a much tighter control to prevent meltdowns and explosions and discharge and charge - any device includes full control and protections regarding voltage and current with sensing on the low-side. Will see how far I'll get when done. Attached schema shows the battery pack and sensor part. The powering of and from Pixl.js is not drawn yet... but I'm thinking of a simple 5V buck DC DC converter, because that will also drive the PWM driven Micro Fan to have active temperature control.

    For a cheap pre-solution for both charging and discharging for a 24V medical device from a 12.8V 10Ah LiFePO protected battery pack, I use a readily available smart buck/boost DC-DC converter. For the currents I need it works perfect (after making the thermal contact better and - planned increase the size of the heatsink for higher charge current.

    The device is a DC-DC 5V 12V 24V Step Up Down Power Supply CVCC Adjustable Converter LCD Display - for example at https://www.ebay.com/itm/DC-DC-5V-12V-24­V-Step-Up-Down-Power-Supply-CVCC-Adjusta­ble-Converter-LCD-Display/164345548755 .

    Unfortunately, it is only manually programmable - afaik- and not mc programmable over some serial or i2c / spc connection. But nice is the ConstantCurrent (CC) function for bulk charging and ConstantVoltage (CV) for balancing / finishing, all without intervention. What I have not tested yet is feeding the charging from a solar panel. So far I used a plain power supply for (stationary) charing and testing. With the MAX17261 circuitry I want to validate its accuracy.


    3 Attachments

  • Thanks.... Interesting read. I want to record some data so the DCDC ... LCD screen isn't quite right for me.
    If anyone knows of something better than an ina226 then that would be brilliant to hear about.

    Thanks

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

Pixl.js - dead? no surely not :-(

Posted by Avatar for saj42 @saj42

Actions