Flashing a Spark Core you bought elsewhere or in case of emergency

That was my mistake! I have pushed a fix. If you update brewpi-script, it will work.

The bug was triggered when dfu-util was not installed. You can also run:

sudo apt-get dfu-util

That will avoid the code with the bug

Hi.

After I ran ā€œsudo apt-get install dfu-utilā€ i was able to load firmware to my Spark. My device was recognized as Particle P1 and it loads firmware version 0.5.2.

If I try to update to version 0.5.4 I get the message ā€œCannot open DFU device 2b04:d008ā€.

What do you recommend? Keep 0.5.2 or update to 0.5.4?

The first time you start the container for programming it will only put it in DFU mode. The container needs to be started again for docker to see the new device. Docker only recognizes devices available at startup. The DFU device is different from the normal serial device.

So you run the container to update. Exit with CTRL-C, then run it again.

Iā€™m still having trouble updating the firmware on my BrewPi Photon.

On my raspberry pi I decided to use Raspbian and install docker within that. I installed the BrewPi container successfully and the script is running. Iā€™m now trying to use the FlashDfu.py script from within the container to update my BrewPi Photon.

First I access the brewpi container as follows (my container is called ā€œbrewpi_fermā€ as I intend to eventually set up another one for mashing):

docker exec -it brewpi_ferm bash

I then run the flashDfu.py as follows:

sudo python flashDfu.py --autodfu --tag=0.5.2

It puts the Photon into DFU mode (flashing yellow LED seen) but says the following:

Will try to download release '0.5.2'
dfu-util version 0.9 found installed on system.
Detecting DFU devices
dfu-util: Cannot open DFU device 2b04:d006

Did not find any DFU devices.
Is your Photon or Spark Core running in DFU mode (blinking yellow)?
Waiting until a DFU device is connected...
dfu-util: Cannot open DFU device 2b04:d006

Any suggestions? I have tried rebooting the pi with BrewPi in DFU mode but the container wonā€™t start when I do this.

Did you try the process described at the bottom of the page here?

https://wiki.brewpi.com/getting-started/updating

You can also wait a few days. Iā€™m reworking the firmware update process and the docker containers this weekend. Waiting until thatā€™s released might save you some frustration.

No I didnā€™t see those instructions. Iā€™ll give it a go and if it doesnā€™t work Iā€™ll wait until the next release.

Hi Elco,
I am running version 0.5.5 on my Spark 3, and need to update to most recent version running under docker due to that Spark is loosing the IP address.
I have tried executing the scripts ā€œUpdating the firmware with DFUā€ ref. https://wiki.brewpi.com/getting-started/updating, but ran into issues with DFU. Is there something new about your work with firmware update?
The following docker images is running. How to update the firmware from docker?


Cheers Ken