[SOLVED] Cloud Issues after a reformat and recompile

Hey Guys,

Forgive me if I’m posting frequently requested threads.

After I’ve completely wiped all sectors (0 - 11) and compiled everything from scratch, then loaded everything in via DFU, I can’t seem to ‘Verify Product Ownership’

I’ve successfully used the Doctor on the keys to generate a new keypair:

dfu-util: Invalid DFU suffix signature
dfu-util: A valid DFU suffix will be required in a future dfu-util release!!!
Opening DFU capable USB device…
ID 2b04:d006
Run-time device DFU version 011a
Claiming USB DFU Interface…
Setting Alternate Setting #1
Determining device status: state = dfuIDLE, status = 0
dfuIDLE, continuing
DFU mode device DFU version 011a
Device returned transfer size 4096
DfuSe interface name: "DCT Flash "
Downloading to address = 0x00000022, size = 608
Download [=========================] 100% 608 bytes
Download done.
File downloaded successfully
attempting to add a new public key for device 2f003000034734##########
submitting public key succeeded!
Okay! New keys in place, your device should restart.

The LEDs seem to flash (Quite Quickly) a blueish green, then a quick flash of red, then back to the blueish green.

If anyone could shed some light on this that would be great!

Cheers guys!

Setup via CLI still seems to be unsuccessful:

You can see the name is “Photon-/” this looks a little dodgy

ddaly at JESSICA-HYDE in ~ [20:43:51]
→ particle setup

Cool ASCII Art Here

Setup is easy! Let’s get started…
It appears as though you are already logged in as #
? Would you like to log in with a different account? No

! PROTIP: Hold the MODE/SETUP button on your device until it blinks blue!
! PROTIP: Please make sure you are connected to the internet.

I have detected a Photon connected via USB.
? Would you like to continue with this one? Yes
! The Photon supports secure Wi-Fi setup. We’ll try that first.

! PROTIP: Wireless setup of Photons works like a wizard!
! PROTIP: We will automagically change the Wi-Fi network to which your computer is connected.
! PROTIP: You will lose your connection to the internet periodically.

? Found “Photon-/”. Would you like to perform setup on this one now? Yes

! PROTIP: You will need to know the password for your Wi-Fi network (if any) to proceed.
! PROTIP: You can press ctrl + C to quit setup at any time.

Obtained magical secure claim code.

! Woops. Something went wrong connecting to Photon-/. Please manually re-connect to your Wi-Fi network.

Could you try doing particle update followed by particle flash --usb tinker, both in DFU mode. See if it connects succesfully, and if not, try clearing the credentials. Then, set them with particle serial wifi. If it then connects, put it in listening mode and issue particle identify, note the deviceID, and have it reconnect. Then issue particle device add [ID].

Give the above a shot and let us know it that worked?

Hmm, that fixed the Device Name, but still doesn’t seem to want to ‘Verify Ownership’

Thanks for your help!

What happens with particle device add [ID]?

No change in LED status, but I get:

Failed to claim device, server said: Device is not connected

I’ve tried configuring it via App and particle serial wifi

Probably asking the obvious thing here, but… was the device connected? As in, breathing cyan?

I think that could be the problem, its flashing Cyan, its not my network, seems to be a firmware issue?

How are you so sure of that?

Any other colors visible while it’s doing so?

I’ve used 2 separate independent network connections and confirmed Wireless Connectivity.

Flashing Cyan, Gets faster, Quickly flashes Red, goes back to start.

Seems to be a firmware issue?

With what did you confirm that, as it seems the Photon wont connect ;)?

That’s why I suggested the Particle update & Tinker, since they’re known good firmware. If you haven’t yet done so, could you give those commands a shot? Make sure you’ve updated your CLI to the latest version prior to doing so to ensure you get the latest system firmware.

Sophos UTM DHCP Server reports a device active (6C:0B:84 …) Shes connecting successfully via wireless

Yeah I tried both commands, still no dice here’s my particle version:

→ particle --version

You are definetly not behind a captive portal there?
You have confirmed that the CoAP Port 5683 is open?

particle keys doctor <deviceID> would only work when your device actually could talk to the internet.

Try this simple sketch to confirm WiFi and iNet connection


void setup()
  pinMode(D7, OUTPUT);
  digitalWrite(D7, HIGH);
  IPAddress ipTest = WiFi.resolve("www.example.com");
1 Like

Hmm, I don’t think its a firewall or network issue, I’ve tried using a mobile’s 4G connection and still have no dice, plus logs don’t show any outbound issues.

Hmm I think I’m gonna have to hook gdb up over SWD and step thru the cloud connect code.

Oooo were should I compile this snippet?

Particle Build or Particle Dev or CLI

You can build with any tool and you can flash using CLI or dfu-util via USB

If you’re seeing the device flash cyan with brief periods of red flashes, it’s generally an indicator that the device has connected to your Wi-Fi network, has reached out to the Cloud, and is attempting to complete a handshake with the server.

This should be resolved by running particle keys doctor <device_ID> with your device in DFU mode. Can you confirm that you’ve tried that after running the particle update command from before?

I’ve tried erasing sectors 1 - 11 and starting again with particle update and I still seem to get the same flashing cyan then red.

Hmm very strange, running the doctor command works successfully. However I still get the same issue.

Can you PM me your device ID? We’ll take a look at the permissions in our database.

Sure, I’ve just messaged you

Solved! I hadn’t added Particle’s Server’s pubkey: https://docs.particle.io/support/troubleshooting/common-issues/photon/#public-key-reset