A possessed Photon šŸ˜±

I've got a possessed Photon. My student put some firmware on it that displays interesting colors with the RGB LED, but we can't replace it with anything else. I put it into dfu-util mode and then used

particle flash --usb photon_firmware_1567703188561.bin

It says Flash success! and I see the RGB go white, flashing green, and then ... back to my student's firmware.

I don't know if this is related, but I tried doing particle update (figuring I'd update to the latest deviceOS), and get

! An error occurred while attempting to update the system firmware of your device:

dfu-util:
File too short for DFU suffix
dfu-util: A valid DFU suffix will be required in a future dfu-util release!!!
dfu-util: Error during download get_status

Please visit our community forums for help with this error:
https://community.particle.io/
Cannot read property 'code' of undefined

particle device doctor also errors out, with the Cannot read property 'code' of undefined error.

Help!

1 Like

@mprogers, which version of the Particle CLI are you running (check with particle --version)?

The studentā€™s firmware may be ā€œchokingā€ the DeviceOS so you could simply flash Tinker back onto the device using DFU mode and particle flash --usb tinker. If Tinker runs as expected, then put the device back into DFU mode and try particle update again.

Thanks for your reply, peekay123! Iā€™m running version 1.45.0.

I tried to flash tinker as I was thrashing about trying to solve this, but I get a light display that I believe is still my studentā€™s code ā€“ a variety of colors, that ends up in a slow and infinitely repeating transition between blue/cyan and green.

@mprogers, the only ā€œParticleā€ pattern that is similar is the ā€œsignalā€ pattern. However, what happens when you do particle update while in DFU mode?

OK, so it's not flashing Tinker. When I run particle update, I get this:

particle update

Your device is ready for a system update.
This process should take about 30 seconds. Here it goes!
! An error occurred while attempting to update the system firmware of your device:
dfu-util: File too short for DFU suffix
dfu-util: A valid DFU suffix will be required in a future dfu-util release!!!
dfu-util: Error during download get_status
Please visit our community forums for help with this error:
https://community.particle.io/
Cannot read property 'code' of undefined

@mprogers, are you on Windows or Linux? If Windows, did you install CLI using the Windows installer? Are you running particle from a system directory (ie no write permissions)?

Iā€™m on macOS Catalina, and I was running it from /Users/me/Desktop/aFolder, so Iā€™m pretty sure I have write permissions there.

Hey @mprogers, can you confirm whether or not the Photon is currently in a product? If the device is in a productā€“whenever it reconnects to the cloud, the cloud will instruct it to download the latest firmware in its productā€“which is likely your studentā€™s firmware.

Removing it from a Product should allow USB flashed firmware to persist.

1 Like

I reclaimed it from my student, and I donā€™t have it in a product ā€“ so I guess the answerā€™s no.

Have you tried putting it into safe mode then flashing tinker OTA?

Hi @mprogers

Would you be able to direct message me the device ID so that I may look into it a bit further? Thanks.

I did. And this AM when I got back to work, itā€™s flashing red, which is a change.

Did you check and see if the signal Is turned on ā€¦Safe mode should disable anything your students have done

I am having the same issue and I did a few things including flashing tinker (particle flash --usb tinker), bootloader (particle flash --serial bootloader-0.7.0-photon.bin), etc. but the device still has the same old program running!
Any update on this issue?

When I do update I get an error:

particle update

> Your device is ready for a system update.
> This process should take about 30 seconds. Here it goes!


! An error occurred while attempting to update the system firmware of your device:

File too short for DFU suffix
A valid DFU suffix will be required in a future dfu-util release!!!
Error during download get_status


> Please visit our community forums for help with this error:
https://community.particle.io/
Cannot read property 'code' of undefined

mstanley investigated, and as a result decided to send me out a new Photon. I guess my students killed it :scream:

1 Like

Is there anyway to factory reset the board?

When I use doctor it throws an error.

particle device doctor
The Device Doctor will put your device back into a healthy state
It will:
  - Upgrade system firmware
  - Flash the default Tinker app
  - Reset the device and server keys
  - Clear the Wi-Fi settings

The Doctor will operate on your Photon connected over USB

PLEASE DISCONNECT ALL OTHER DEVICES BEFORE PROCEEDING

You'll be asked to put your device in DFU mode several times to reset different settings.

Updating system firmware

Put the device in DFU mode
Tap RESET/RST while holding MODE/SETUP until the device blinks yellow.
? Select Continue when ready Continue

> Your device is ready for a system update.
> This process should take about 30 seconds. Here it goes!


! An error occurred while attempting to update the system firmware of your device:

File too short for DFU suffix
A valid DFU suffix will be required in a future dfu-util release!!!
Error during download get_status


> Please visit our community forums for help with this error:
https://community.particle.io/
The Doctor didn't complete successfully. Cannot read property 'code' of undefined
> Please visit our community forums for help with this error:
https://community.particle.io/