Photon Not responding

One of my photon boards (I’ve got 5, 20more on the way) is not responding to anything, seems like it’s dead but blue LED is always on (D7). Reset doesn’t do anything (by pressing button or RST pin). Mode button doesn’t work either, tried using JTAG/DFU both are not detecting the device.

When connected to USB I’m getting 1.6 VDC on 3.3v pin but vbat showing 0.05 VDC.

Any thoughts?

Did it work and then suddenly fail?

Great that you have jtag, so if it’s a firmware issue we can recover it.

Can you put the photon in DFU mode? Once in that mode it should be more responsive to connecting via JTAG.

I’ve been updating all my photon to latest firmware (in modules/ do make … program-dfu). It successfully flashed it but after reset it went to this dead mode.

It’s not responding to reset signal so I cannot get it into DFU or factory reset or anything. JTAG is not recognizing it either.

If it’s connected to any other components, please disconnect them so only the USB connector is plugged in. Also be sure to remove from the conductive packaging foam.

If you hold reset then attempt to connect via JTAG. Which JTAG programmer are you using?

Also disconnect power and remove from the JTAG programmer. Holding the setup button reconnect power and continue to hold the setup button.

Did all of above. But nothing happening. Blue LED constantly on (half dimmed) and that’s it.

BTW, This forum blocks me from posting reply/new issue every single day. Is there anyway to increase the limit?
Or Is there any slack channel I can join instead of posting here?

This is very strange. Can you try again and be sure to push on the setup button hard, say with the blunt end of a pencil. I’ve had cases of folks not pushing it hard enough.

Regarding the forum blocking you, let’s cc: @christine

1 Like

@mojtabacazi, just upped your trust level. You should be good to post more often

1 Like

Thank you @harrisonhjones.

@mdma No luck. Seems it’s burned out.

I suppose there's a vanishingly small possibility of that but it seems highly unlikely. Was the device connected to something else while you were updating it?

Attached to a breadboard alone. Like I said I did the same for all 5 of them, And this one didn’t make it.

I just can’t see how flashing the photon would cause it to be irretrievable, specifically as the bootloader is write protected. Did the photon suffer any power outages while flashing? Possibilities of overcurrent/overvoltage?

Are you able to connect your JTAG programmer to the other units?

I don’t believe your device is truly fried - but I need more info to try to help you find the route to reviving it.

Another thing to try is to hold RESET and then attempt to connect your JTAG programmer. Which programmer are you using?

Here is what I got after attempting to flash using st-flash. Using ST-LinkV2

Device state is like before, not responding to anything.

$ make USE_SWD_JTAG=y PLATFORM=photon clean all st-flash

32+0 records in
32+0 records out
32 bytes transferred in 0.104768 secs (305 bytes/sec)
4+0 records in
4+0 records out
4 bytes transferred in 0.141141 secs (28 bytes/sec)
rm: ../../../build/target/system-part1/platform-6-m/system-part1.bin: No such file or directory
   text	   data	    bss	    dec	    hex	filename
 248560	    184	    132	 248876	  3cc2c	../../../build/target/system-part1/platform-6-m/system-part1.elf
Flashing ../../../build/target/system-part1/platform-6-m/system-part1.bin using st-flash to address 0x8020000
2015-06-11T17:18:45 INFO src/stlink-common.c: Loading device parameters....
2015-06-11T17:18:45 INFO src/stlink-common.c: Device connected is: F2 device, id 0x20036411
2015-06-11T17:18:45 INFO src/stlink-common.c: SRAM size: 0x20000 bytes (128 KiB), Flash: 0x100000 bytes (1024 KiB) in pages of 131072 bytes
2015-06-11T17:18:45 INFO src/stlink-common.c: Attempting to write 248748 (0x3cbac) bytes to stm32 address: 134348800 (0x8020000)
EraseFlash - Sector:0x5 Size:0x20000
Flash page at addr: 0x08020000 erasedEraseFlash - Sector:0x6 Size:0x20000
Flash page at addr: 0x08040000 erased
2015-06-11T17:18:45 INFO src/stlink-common.c: Finished erasing 2 pages of 131072 (0x20000) bytes
2015-06-11T17:18:45 INFO src/stlink-common.c: Starting Flash write for F2/F4
2015-06-11T17:18:45 INFO src/stlink-common.c: Successfully loaded flash loader in sram
size: 32768
2015-06-11T17:18:49 ERROR src/stlink-common.c: flash loader run error
2015-06-11T17:18:49 ERROR src/stlink-common.c: run_flash_loader(0x8020000) failed! == -1
stlink_fwrite_flash() == -1
make[1]: *** [st-flash] Error 255
make: *** [/modules/photon/system-part1/makefile] Error 2

Thanks for the detail. So it is connecting with JTAG, so the device isn’t dead.

You can’t st-flash the system modules or the bootloader without clearing the page option bytes first, otherwise the memory regions will be write protected.

To flash the system modules, I suggest you use program-dfu instead since DFU internally manages the write protect bits.

Well, I cannot get the device to DFU mode

can you try building the bootloader and flashing that:

cd bootloader
make PLATFORM=photon all st-flash

If the bootloader has been erased then the write protect bits have been cleared.

Did you clear the option bytes yourself? If not, please send me the ID of your device so I can check the manufacturing logs.

Here

Flashing ../build/target/bootloader/platform-6-lto/bootloader.bin using st-flash to address 0x8000000
st-flash --reset write ../build/target/bootloader/platform-6-lto/bootloader.bin 0x8000000
2015-06-11T18:46:55 INFO src/stlink-common.c: Loading device parameters....
2015-06-11T18:46:55 INFO src/stlink-common.c: Device connected is: F2 device, id 0x20036411
2015-06-11T18:46:55 INFO src/stlink-common.c: SRAM size: 0x20000 bytes (128 KiB), Flash: 0x100000 bytes (1024 KiB) in pages of 131072 bytes
2015-06-11T18:46:55 INFO src/stlink-common.c: Attempting to write 13640 (0x3548) bytes to stm32 address: 134217728 (0x8000000)
EraseFlash - Sector:0x0 Size:0x4000
Flash page at addr: 0x08000000 erased
2015-06-11T18:46:56 INFO src/stlink-common.c: Finished erasing 1 pages of 16384 (0x4000) bytes
2015-06-11T18:46:56 INFO src/stlink-common.c: Starting Flash write for F2/F4
2015-06-11T18:46:56 INFO src/stlink-common.c: Successfully loaded flash loader in sram
size: 13640
2015-06-11T18:46:59 ERROR src/stlink-common.c: flash loader run error
2015-06-11T18:46:59 ERROR src/stlink-common.c: run_flash_loader(0x8000000) failed! == -1
stlink_fwrite_flash() == -1
make: *** [st-flash] Error 255

Which ID are you talking about? Spark.deviceID() ? How do I get that ?

Can you please send me your bootloader image by running

st-flash read bootloader.bin 0x8000000 0x4000

Are you running Windows? If so, please download the ST-Link Utility (GUI) from http://www.st.com/web/en/catalog/tools/PF258168.

Then use the menu “Target | Option Bytes…”, to bring up the options dialog. Select “Clear All” then “Apply.” Then it should be possible to flash the bootloader.

But this is strange - if the page is write-protected the bootloader must still be intact. I will check that when I recieve the bootloader image.

I have to find a windows machine then. I’ll try and let you know. Should I upload bootloader here or email?