Electron `getStrength()` and `getQuality()` both return `-1`

Extract of the code:

CellularSignal sig = Cellular.RSSI();
float strength = sig.getStrength();
float quality = sig.getQuality();

The problem is that getStrength() and getQuality() returns -1 often, but not always.

Setup description: I have (8) electrons that

  1. First turns on, waits 2 minutes (non-blocking).
  2. Precedes to publish an event using particle publish, that uses the code above.
  3. Device goes into deep sleep.

When I examine the documentation, I don’t find explanation of -1 output.

Notice, that the electron is able to complete the particle.publish() successfully, even though signal strength and quality are -1.

I hope you can help me resolve the issue. It really bugs me.

Can you clarify what kind of Electrons (2G, 3G US, 3G international, LTE)?
Are you using Particle SIM or 3rd party?
What is the chronological context of the signal info acquisition?

They are Electron 3G-U270. GSM 900/1800/2100 Mhz.
I use the sim card provided by Particle.
I dont understand what you mean by chronological context of the signal info acquisition?
The device use deep sleep. When it wakes up it will start normally and wait for 2 minutes before reading signal strength. (The system mode is automatic)

That's exactly what I meant with that question :slight_smile:

Do you have any clues as to what might be the issue?

Not exactly, but I’d usually whip together a minimal test program that only does that one thing and see how that works out.
If the issue still persists with such a minimal test case I’d test with different device OS and application target versions.
Armed with that I’d either work forward to reincorporate the stripped down parts or file an issue report.

Thanks.