Fancy blink pattern = never gets online (but is apparently always online?)

Hi,
I have a Photon that is really funky. It basically seems like it’s out of sync with the cloud. It turns on as normal, but when it connects to wifi (fast white blinks) it does not go online. Instead it gives a quick red blink and then goes back to blinking quickly white and this then repeats forever.

There’s two very peculiar observations I have that can be relevant:

  • In my Devices on build.particle.io this Photon seems to always be online (cyan dot) even when it’s not powered.
  • As opposed to ALL my other Photon’s, this one CAN be setup via the Android app (ref this thread). Setup actually works every time, so this could be what the Android developers need to know to fix the bug.

This looks like there’s a server bug that prevents this device (Device ID 24005a000a51353335323535) from submitting it’s online/offline status. This in turn makes it possible to set it up via the Android app. In other words, the Android app problem could basically be a simple true/false issue in code?

The device has the latest 0.6.0 firmware.

Fast white is not connecting to the WiFi. That would be green.
AFAIK that's more like a Core color code that shouldn't exist on the Photon as there is no Factory Reset for Photons
https://docs.particle.io/support/troubleshooting/common-issues

Have you confirmed 0.6.0 via particle serial inspect?
Can you post the output?

So from the looks of the list of color codes, fast white blinks should be “Flashing code from factory reset memory”. The online IDE reports the device to have 0.6.0 and here’s the output:

>particle serial inspect
Platform: 6 - Photon
Modules
  Bootloader module #0 - version 7, main location, 16384 bytes max size
    Integrity: PASS
    Address Range: PASS
    Platform: PASS
    Dependencies: PASS
  System module #1 - version 102, main location, 262144 bytes max size
    Integrity: PASS
    Address Range: PASS
    Platform: PASS
    Dependencies: PASS
  System module #2 - version 102, main location, 262144 bytes max size
    Integrity: PASS
    Address Range: PASS
    Platform: PASS
    Dependencies: PASS
      System module #1 - version 102
  User module #1 - version 4, main location, 131072 bytes max size
    UUID: 5B625BA38A776688E2CCDA30414AD61C59846B02AB28F1F717C9E7DC15BCE1A5
    Integrity: PASS
    Address Range: PASS
    Platform: PASS
    Dependencies: PASS
      System module #2 - version 102
  empty - factory location, 131072 bytes max size

I’m not sure how I can see the firmware version from here? A former fix for Photons that appear to be in limbo state has been to put them in DFU mode and use “particle update”. The update appears to go well. The device restarts, but goes back to blinking fast white and then red again.

That 102 matches up with 0.6.0 - although there is no easy way to translate one into the other AFAIK.
But the point is all system parts do share the same number and your app firmware doesn’t have a conflict.
You can also try particle identify or particle serial identify

How does the device behave in Safe Mode?
How about erasing and reentering the WiFi creds?

So, when I try to enter Safe Mode, the device just goes straight into the fast whit/red blink mode. I hold both buttons, release reset, release setup after maybe 2 seconds and as opposed to my other Photon’s it goes straight to this mode.

Like I mentioned above - this is the ONLY Photon that I can connect successfully to using the Android app. All others will fail, but this one will manage to do the full setup every time. The Photon will never go online though, but the cloud service still thinks it’s online so it says that the wifi setup procedure went well.

Setting up credentials over CLI also works.

I think we may need to call in additional support in the form of @BDub and/or @Dave.

This might provide useful info in the form of binary dumps, so perhaps it's better to wait for either of the above-mentioned guys to chime in before meddling with it further.
The cloud shouldn't see it as online if it's not, so there's probably something strange going on. I wouldn't use that as an indication to determine the Android setup was successful.

1 Like

Ok. I’ll wait for them. What I mean regarding Android is that since many months back (ref the thread above) neither I or my students have been able to set up ANY Photon using the Android app. They are simply never showing up.

This Photon is different in some way since it is instantly visible in the Android app and I can go through the entire process without a problem. All I’m saying is that this could indicate what kind of bug that is causing the Android app to fail.

My understanding is that the Android app also checks to see if the Photon is online after setting up. Given that this Photon always appears to be online (when it clearly is not) then that could give incorrect feedback to the app.

1 Like

@jenschr could you PM me your device ID so I can take a look? Also a video of the white blinking would be helpful for me to verify what I’m hearing :smile:

4 Likes

Sure. It's at the top of the thread, but here for your convenience :wink:

Video here: https://www.youtube.com/watch?v=H1CVT_q4i6I

1 Like

Thanks for the video that really helps. I haven’t dug into the ID yet, and why it appears online all of the time… but the other behavior seems logical I think.

  1. It boots, WHITE, then GREEN (connecting to Wi-Fi), then starts blinking CYAN (connecting to cloud) but blinks fast RED which indicates some kind of handshake error. Could be that it doesn’t have a Public Server key… or the Device Keys are corrupt.

  2. It won’t enter safe mode because of #1, it won’t turn breathing magenta until it connects to the Cloud.

Would you please backup your Photon Flash and email it to me:

Put it in DFU mode and run:

dfu-util -d 2b04:d006 -a 0 -s 0x8000000:0x100000 -U photon_24005a000a51353335323535.bin

Then afterwards try to restore the keys with the CLI and these two commands (device in DFU mode):

particle keys server
particle keys doctor 24005a000a51353335323535

Then reset it.

5 Likes

Also the Photon is currently showing as disconnected/offline. Can you show me where it appears online?

Just to be awkward, that blink pattern is widely known as cyan with red/orange burst and if it was not called “fast white blinks” we could have given you the hint about the keys issue a lot earlier.

There is a wealth of threads about that particular blink pattern
https://community.particle.io/search?q=burst

1 Like

Restoring the keys did the trick. It’s now alive again :smile:
It was showing as always being online in build.particle.io (cyan dot next to the device name)

I presume this can this happen to any device? I better make sure to add a USB port to all my P1 designs then, so I have a way of saving them. Or could I do the same via OpenOCD/GDB so it would be sufficient to just have SWDIO and SWCLK broken out?

Hard to see the difference between white/cyan though. I asked another for advice and she also said it looked white :wink:

Maybe there’s a trick to it? Putting a piece of white paper on top maybe makes it easier to see?

I see :sunglasses:

The very first blink when you power your device is white (all three sub LEDs R, G & B) and cyan (after green) is only made up by the blue and green sub LEDs (no red).

2 Likes

Good to hear!

Thanks for sending the binary dump first. It appears your Public Server Key was missing. This has happened infrequently in the past. We're not sure yet what causes it yet but you are adding to the data. Because your Photon had a lot of frequent use I wonder if you know the exact circumstances of when it was last online (If you don't I do, Jan 9th 1:34:32 pm CST), and what happened just before the blinking patterns?

I suppose it can, and that's probably a good idea along with JTAG/SWD. SWD should be ok by itself if you make sure to not clobber the I/O's or add jumpers if you have to.