Electron running but not publishing to console

I’ve got an electron running on solar in a remote, inaccessible location. It continues to run and report water quality and weather to Obidots every 30 - 60 minutes but is not reporting to the particle console.
Unit information:
Name: Spudnik-09
Device OS: 1.2.0-beta.1
Type: Electron
Serial Number: E26KAB816SVQZSF
Last Handshake: Oct 18th 2019, 7:52 am

The code uses Particle.publish() to report some events to the particle console when the unit wakes up from sleep every 30 or 60 minutes. It worked fine for several months but stopped reporting to the particle console on Oct. 21th 2019 (a few days after the last reported handshake).

Since the unit is inaccessible 'till spring, and is still reporting to Ubidots, I am reluctant to experiment with Over The Air updates or other things that might kill the reporting to Ubidots. Might this be related to the device OS ? or Do I simply need to force a handshake?
Any ideas would be appreciated.
thanks, john

This sounds like a timinig issue, not leaving enough time after the publish call to effectively deliver the data before the device goes back to sleep again.

Given the -beta.1 part in your your device OS I’d not trust such a version anywhere but on my desk next to me :wink:

1 Like

I don’t think it’s timing. The Particle.publish() comes both before and after I successfully send data to Ubidots. Also, I used essentially the same code on different electrons all of last year.

If it is a OS problem, I’m stuck since I can’t do an update without a connection and I’ll just leave it alone 'till spring.
If it’s a handshake problem, if I use the curl command proposed here: How to force a handshake for OTA updates , does that command interact with the electron or just with the particle console?
I don’t want to kill reporting to Ubidots, so I am trying to be very careful not to screw things up more than they already are. thanks, john

The device is connecting to the cloud. Once an hour the device is communicating with the Particle cloud. Each time the IP address changes, which is expected for a device that goes to sleep.

Since publishes are not logged anywhere, I was going to say there’s no way to determine why that’s not working, but events came through for Spudnik-09 while I was looking at it 7 minutes ago.

If you use curl to hit the disconnect endpoint it will cause a full handshake from the device the next time it wakes up from sleep. It can use up to 5K of data.

It would be difficult to OTA flash the device because you’d have to get it to start during the brief time it’s not asleep. Also, you’d have to be very careful not to force a Device OS upgrade, and also be sure you’re code won’t make the device go to sleep during the update.

But in any case, it events seem to be working now.

rickkas7,
Not sure what you did or what I did but I see that Spudnik-09 did a handshake this morning after 2 months of not handshaking. And I see the events coming in. Strange.
I didn’t send any curl commands for this device but as an experiment at about 9am (CST) I did do a curl disconnect for a different device that I have in hand, and I checked the device ID thrice to make sure I was sending to that other device. Maybe a disconnect for one device made the system check the connections for all my devices?
As far as OTA flash, now that I can see the events coming in I can time a flash with new code during the 40 seconds I leave at the end of my code for updates. That has worked in the past, but I think I will not try a OS update because that takes longer than simply flashing some new user code.
Thanks for whatever you did or did not do. Maybe Spudnik-09 just wanted some attention. It’s pretty cold (-27C this morning) and lonely up there in northern Minn. :slight_smile:
john

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.