Need help resetting some photons [Solved]

Hi All,

I have a couple of alpha photons that I am trying to bring to life. When you plug them in to the usb cable they go to blinking yellow, They show in the device manager (windows) as a dfu device, but the dfu-util program cannot find them. I figure they are missing some fundamental code. I see at [release binaries] some instructions but need more help.

I have been able to connect to the devices no problem with the st-link and STs utility I have programmed system_pad_BM-09.bin @ 0x8020000 but this does not solve my problem.

Any suggestions? There are a few other bins there reset.bin and unlocker.bin but no instructions on where to program them or what they do.

I also saw a contradictory thread where @kennethlimcp said spark_tinker.bin should be programmed at 0x8020000 on the photon.

It is actually stated here:

What do you actually mean by does not solve your problem?

Once you flash the system_pad_BM-09.bin, perform a factory reset and send in wifi credentials again.

2 Likes

Hi @kennethlimcp

Thanks for the quick reply. I am able to program and verify that code at 0X8020000 with the st-link device, but when I remove the photon from the jtag programmer and connect to the usb cable alone I still only get blinking yellow and dfu-util still cannot find the device. My assumption is that these early photons and they are missing more than just system_pad_BM-09.bin

Regarding factory reset the reset & mode buttons are not able to get the device into any other state. It is always blinking yellow (just to be super clear when reset is pressed it does turn off the rgb led but not d7).

Why are they in the blinking yellow state actually? Did the alpha photons not worked for you before?

Since you have a stlinkV2, what i would do it to:

  • unlock the device
  • erase the entire device
  • load the factory images
  • load the updated system image
  • try it!

If you are keen to do the above, let me know :wink:

@kennethlimcp Yes I am keen. Please any help you could offer would be appreciated.

These photons have been in this state ever since I got them. A couple of months ago. They were never useful to me in this state, but because I have yet to get any newer photons I finally have broken down and installed what was needed to get the ST-Link up and running.

Weird. You should have reached out to the team and get it fixed in the first place… Anyways!

Do you have access to the firmware-private repo?

@kennethlimcp Made some real progress but not quite there. I installed the unlocker.bin did the erase and then installed the system_pad_BM-09.bin. I had to use the ST-Link programmer for all step as the device could still not be found by dfu-util.

Okay so now when the device is plugged into usb the rgb goes from solid white to blinking blue. The device is now seen in device manager as Photon with Wifi. Dfu-Util still cannot find the device it asks if it is blinking blue which it is.

I cannot get the device to do a factory reset any other ideas?

Regarding reaching out to the team When the devices were sent we were told these are very early units and not to expect much help, when they were unusable it seemed in line with those low expectations that were set.

@HardWater,

Did you mean you did a st-flash write combined_BM-09.bin 0x08000000 followed by dfu-util -d 2b04:d006 -a 0 -s 0x8020000:leave -D system_pad_BM-09.bin

Not sure how well you know the basics of the setup. Listening mode is blinking blue. That’s not DFU mode. If you want it to be displayed as a DFU device, you need to place it in blinking yellow mode.

Now that it is blinking blue, can you send in the Wifi credentials as see if it connects to the :cloud:?

No what I did is use ST-LINK to do the following

Program unlocker.bin @ 0x80A0000

Then erase entire chip with ST-LINK Link Utility

Then program combined_BM-09.bin @ 0x8000000

Then program system_pad_BM-09.bin @ 0x8020000

On the second photon I can get the device to step through the magenta, yellow, green, white sequence I am guessing that maybe I used a wrong address at some point when programming the first unit.

But still not quite there. When I release mode/setup when the rgd is yellow it shows in device manager as Spark Photon DFU Mode if I try the following command while it is continuing to blink yellow (as a test)

dfu-util -d 2b04:d006 -a 0 -s 0x8020000:leave -D system_pad_BM-09.bin

I get

Invalid DFU suffix signature
A valid DFU suffix will be required in a future dfu-util release!!!
Cannot open DFU device 2b04:d006
No DFU capable USB device available

If I do a factory reset ie release mode/setup when flashing white the rgb transitions to blinking blue.
It then shows in device manager as Photon with Wifi. If I try to run spark setup from the command line I get

Finding your core id

I didn t find any cores available via serial
Press and hold the MODE button until your core blinks solid blue

 - Is your core blinking blue?  Then press ENTER - Potentially unhandled rejection [2] No serial port identified (WARNING: non-Error used)

Hey @HardWater, looks like you're still using the Spark CLI, which we've since upgraded to be the Particle CLI. Please follow the steps here to upgrade to the Particle CLI: GitHub - particle-iot/particle-cli: Command Line Interface for Particle Cloud and devices .

Then, initialize the Photon setup process with particle setup.

Does that help?

@kennethlimcp I made a little progress. I found that I needed to open up Zadig and add the driver for Photon DFU Mode. I had assumed since my setup works fine with a core all would be good but I was wrong. So for others that have previously been working with the core you need to do this to be able to execute dfu commands with a Photon.

Regarding the use of spark setup at the command line that still does not work I always comes back as above stating the device needs to be blinking blue which it is but does not work.

I there something else that needs to be installed to make spark setup work? I confirmed that I have the latest release of dfu

from my directory I have 
09/13/2014  07:17 AM           124,040 dfu-util.exe

This makes sense - the Photon has a different USB identification so it is necessary to rerun Zadig on Windows to get DFU support.

1 Like

Unlocker.bin must go to 0x8020000. I don't think you would have done any damage flashing it to 0x80A0000 but it wouldn't have worked as expected.

1 Like

Hi @kennethlimcp, @jeiden & @mdma Thanks for the help. Okay so Now I have particle-cli up and running it can indentify a core no problem but it still cannot identify the photon (that is the good unit that I can step through the rgb colors with).

Here is what I get with the Photon

                  _   _      _        _
 _ __   __ _ _ __| |_(_) ___| | ___  (_) ___
| '_ \ / _` | '__| __| |/ __| |/ _ \ | |/ _ \
| |_) | (_| | |  | |_| | (__| |  __/_| | (_) |
| .__/ \__,_|_|   \__|_|\___|_|\___(_)_|\___/
|_|                     https://particle.io/

> Setup is easy! Let's get started...
> It appears as though you are already logged in as ----@------------.com
? 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.

> No devices detected via USB.
? Would you like to scan for nearby Photons in Wi-Fi setup mode? (Y/n)

Is there the possibility that these very early photons are not fully tested in terms of manufacturing bad solder joints etc ?

@mdma I think I probably worked around the unlocker.bin being at the wrong location by clearing the write protect bits in the option bytes,

1 Like

When you have the Photon in Listening Mode (blinking blue) what shows up in Device Manager? can you upload a screenshot?

@harrisonhjones Here you go it is a 2fer I displayed the device manager then ran particle setup

Ah ok. You need to install the Serial Driver for the Photon.

Go here: Updated Windows Driver for Core and Photon to download the new driver.

Once downloaded follow this tutorial Installing the USB Driver on Windows & Serial Debugging except use the driver you downloaded from the first link (the Photon driver, not the core driver).

Once correctly installed (the yellow exclamation mark will disappear) you should be go to do a particle setup again

[ Oops, didn’t read well enough the post above! ]
Have you installed the windows driver? http://docs.particle.io/photon/connect/#connecting-your-device-using-windows

The driver has a ? next to it meaning the device isn’t fully installed.

Thanks @harrisonhjones also @kennethlimcp @jeiden & @mdma

Making little baby steps in the right direction. You guys really need to tell users that if they had their machines setup to work with the core PLEASE delete everything and install all new to support the photon. Enough of my rant.

Okay so now I can see the com port # for the device. With PuTTY is was able to get my device id, set my ssid & password. The device then transitioned to a rapidly flashing cyan.

When I try to claim the device to my account with Particle-Dev I get device does not exist? Any ideas here?

Also particle setup still can’t see the usb device even though Putty can talk to it.

1 Like

Shoot an email to hello@particle.io with your device ID and we’ll look into it :smile: I’m willing to bet the keys aren’t in the system somehow

1 Like