Electron in the Field Disconnecting Every 10-15 min or so

Did you run the same hw config in your lab (ie with recharger)? If not, any possibility it jolts the power to the unit from time to time? (Although the strict regularity of the reset leads me to believe it is not PSU related). Any big machinery out there that might do the same? Just trying to remove the environment as a factor…

1 Like

Do you have this remote Electron under Products in the Particle Console webpage as shown below?

I left it running in safe mode for over an hour before I tried a soft rested using the reset button. It stayed in safe mode. I had to cut the power completely and restart the unit. Once I did this it came right out of safemode and booted right up.

I now downgraded back to the tinker app, did a particle update. Then flashed my code via usb to bring it back up to rc.4.

I then wanted to check and see if doing it over the air would work. So I selected version rc.10 tested the code again, and hit flash OTA. Unfortunately it timing out. I tried 2 times and it keeps getting the “Request Timed Out”. Third time it took and flashed.

Now that I was able to successfully do an OTA with the new code and Version 10 of the OS I am comfortable trying to flash the unit in the field. I have a small window of 5 min so I will have to wait for it to check in and smash the flash button and cross my fingers and toes.

I will keep posting updates.

1 Like

Morning Ryan.
I do not have it under the products tab. Should I move them there in the future?

Hi Joost.
Yup I am using the exact same setup in the filed that was in the office. Ship that unit as is to the client for install and testing. I will have to ask the client about any possible interference and report back. This is a large electronics manufacture. Most of the equipment there should be wave solder, selective solder, and reflow ovens. They should also be a good distance from the location the unit is installed but I will know more on Monday after I talk with the client.

If it’s under the product area you can just pick the OS and your new code and flash it OTA and the Electron will update both.

I think Scruff says above that you can do this via the CLI with the correct commands even if the Electron is not under a product umbrella but I’ve never tried that before

1 Like

Now that sounds handy. Now if the dang thing would stay connected long enough I could flash it… only connects once every 10 min. :joy:

It’s like watching grass grow waiting for my window of opportunity.

In that case I'd go a safer route.
Wait till the device comes online and then flash a tiny dummy application firmware that's targeted at the current device OS and will keep the device permanently online.
Once that code is running, you can proceede with the Device OS update without having to fear loss of connection during the process caused by your standard application.

1 Like

Thats a fantastic idea. Do you have a suggestion for a dummy app that is in the library?

The simplest dummy app would be

void setup() {}
void loop() {}

This will use default AUTOMATIC mode, won’t ever cut the connection and is as small as it gets which will reduce the time required for the flash to succeede :wink:
If you were using 3rd party SIM you’d of course need to set the cellular credentials and keep alive.

2 Likes

Awesome. Thank you very much for all the help. I will try it. I am using Particle SIM so I can at least rule that out. lol.

Update.
Well, we are back in business. As it turns out the client had disconnected the battery so the unit was running off the power supply connected to VIN. The problem is the power supply is only capable of keeping the battery topped off and will not provide the 1.8 amps needed to run the electron during publishing. The power supply that comes with the meters is rated at 0.75 amps at 24 volts. I bring that down to 12 volts using a Traco TSR-2-24120. I am surprised the unit was able to connect at all and did not grenade. The new version of these will have both the VIN and Battery hardwired to a switch, but I think I need to add some kind of monitor to warn if the unit is only supplied by VIN and not battery… is that possible? I am confused as to why the device vitals showed the battery charge at 96% or above. After downloading the device diagnostics I now notice the under the “device.power.battery.state” it states “charging”, or now “charged” on the history. If I go back to when we had problems it says “unknown” so now I know I can look there and see if I am not connected to the battery.

Screen Shot of device diag. for others to reference.

I did go with @ScruffR suggestion and once the unit was back online I flash a dummy app and the new code that you all helped me with. Thank you again for working with me and helping me out. I really appreciate it. Thank you very much @RWB @ScruffR @Rftop @joost

Need to add more code to make sure everything is connected properly and make some hardware changes so that this won’t happen again. But that’s why we test and hope some things can go wrong so we can make it better.

You guys are the best.

Cheers,
Tom

3 Likes

Glad it was, in the end, an easy to fix problem.

Now you know how to make it better :slight_smile:

1 Like

Ha, so not the security guard :wink: (I've got some great troubleshooting stories involving security guards) - Good your world returned to sanity...

2 Likes

That's because the fuel gauge does "guess" the state of charge from the voltage it reads from the line where the battery is supposed to be. If the power supply provides the voltage, that voltage will trick the fuel gauge into reporting a SoC.