Electron jumps to Listening Mode (frequent blue LED blinking)

Hello,

My Electron goes into a Listening Mode some seconds after “Breathing White”.

The device is not claimed, without SIM (never inserted the SIM).
No battery or antenna connected.

system firmware version: 0.6.2
CLI: particle --version gives 1.25.0

There is no difference if the user code running is mine (see below) or the Tinker.

Odd thing is - it worked well for some days. I have been developing and testing my software successfully using the device.

The code I am flashing is:

#include "application.h"

SYSTEM_MODE(SEMI_AUTOMATIC);
//SYSTEM_MODE(MANUAL);

void setup() {
   Cellular.off();
   Serial.begin( 9600);
   Serial.print( "Setting up the device ...");
   Serial.println( "OK");
}

void loop() {
   Serial.println("Test");
   delay( 100);
}

Not only there is nothing on the terminal, but as I mentioned - the device drops into a Listening Mode.

I am aware about the tons of topics with the similar subject - tried all of them that seemed relevant.

My question is - what else can I try before deciding that “mode” button is broken and replacing it.

Thanks in advance!

Not knowing which topics you've deemed relevant, it might be a good idea to tell us what you've tried, rather than have us guessing, or telling you things 5 times over :wink:

Hello,

Here is what I have tried so far:

  1. In the code: SYSTEM_MODE(AUTOMATIC / SEMI_AUTOMATIC / MANUAL);
  2. In the code: Cellular.off();
  3. CLI: particle update
  4. CLI: particle flash --usb tinker
  5. CLI: particle device doctor

Is there any way to figure out the exact reason why did the device go to Listening Mode? Some log level increase for serial terminal output, or something similar. I mean, was the “Mode” button pressed for certain interval of time or the timeout while connecting to the cellular tower/cloud or an inaccessible/faulty SIM?
These I believe are the possible reasons why the device can go to “Listening Mode” in the first place.

Regards

It should work, but you could try putting Cellular.off() in the STARTUP() macro.

One possible cause for unexpeted LM might be a faulty SETUP/MODE switch, or some kind of bridge pulling the respective pin low.
Also if you are connected via USB to your computer, you might have your system set up to set the Electrons USB Serial port to 28800 baud, which is a way to trigger LM from outside. Try powering the device by battery or a USB charger only, to cross this off the list.

2 Likes

Hello @ScruffR,
Thanks for joining - the hope to figure this issue out is back :slight_smile:

I have tried the STARTUP() macro (see code below) - didn’t work. The device still blinks blue frequently, after breathing white for some 3-4 sec.

I have also tried the USB charger instead of USB port - didn’t work either.

About the possibly broken button - that much I know myself (see the original post). I was asking for the trick to diagnose this without soldering it out.

I was hoping to switch some logs On (or increasing the debug level) and see something like:

"INFO: Switching to Listening Mode (reason - button press) ...",

or something similar.

Digging through the sources of Particle I have already figured out that there is nothing like that (the logging system). Will keep this thread updated if I find something useful.

Thanks once again for spending the time and responding.

Current code:

#include "application.h"

SYSTEM_MODE(SEMI_AUTOMATIC);
//SYSTEM_MODE(MANUAL);

void onStartup() {
   Cellular.off();
}

STARTUP( onStartup() );

void setup() {
   Serial.begin( 9600);

   Serial.print( "Setting up the device ...");

   Serial.println( "OK");
}

void loop() {
   Serial.println("Test");
   delay( 100);
}

To all interested in this issue,

Actually, if it was broken “Mode” button, it would mean that the button is “pressed” all the time. Therefore, after the reset I should see the device eventually end up in DFU mode, not Listening Mode.

What I observe is - that the device after the reset breathes white and then - blinks blue (not going to DFU mode). So, Mode button is not pressed (broken).

Just to answer possible question: I am able to bring the device to DFU mode by holding Mode and pressing Reset button. Then LED turns magenta and yellow and flashing takes place correctly.

I think, what brings the device into a Listening Mode is System Software (the one that calls loop() and setup(), the code of which is under system/src/main.cpp int he source tree), and what allows me to jump to DFU is the bootloader. Which makes me thinking that there is something wrong with the System Software.

I will appreciate any relevant and thoughtful comment.

Regards

@opalapps, you may want to run Particle device doctor to reset the Electron. Check out this documentation:

https://docs.particle.io/support/troubleshooting/common-issues/electron/#device-doctor

I did - check my second replay with the things I have tried already.

Quick update. I have un-soldered the “Mode” press button - did not help. Same blinking pattern. The button seems to be working ok.