BrewPi Spark v2 upgrade Firmware issues

I have a BrewPi Spark v2 and it has run solid for a couple years. I had some time to work on bringing it up to date and have ran into issues. I have spent several hours looking through the forum and have been able to get things working but am unable to fix a couple issues.

  1. I am unable to update the Brewpi firmware from version 0.4.2 to version 0.5.4 (described below)
  2. The error log repeatedly is getting the following error: Error: Received invalid message on socket: lcd

I am most concerned with getting the BrewPi all up-to-date and then maybe that will fix my second issue.

When I try to manually update my BrewPi using the following commands over SSH connection

cd brewpi-tools/
sudo python updater.py --ask

My Script Repository has been updated

*** Updating BrewPi script repository ***

Stopping running instances of BrewPi
Quit message sent to BrewPi instance with pid 3219!
You are on branch release/0.5.0

My BrewPi Web Interface repository has been updated to the Master Release.

*** Updating BrewPi web interface repository ***
The path ‘/var/www/html’ does not seem to be a valid git repository
What path did you install the BrewPi web interface scripts to? /var/www
You are on branch master

Available branches on the remote ‘origin’ for /var/www:
[0] develop
[1] feature/chart-export
[2] feature/notifications
[3] legacy
[4] master
[5] Skip updating this repository
Enter the number of the branch you wish to update [master]:5

No changes were made, skipping runAfterUpdate.sh.
If you encounter problems, you can start it manually with:
sudo /home/brewpi/utils/runAfterUpdate.sh

I run into issues here when I try to upgrade my firmware

Checking current firmware version…
Apr 15 2018 13:07:37 Opening serial port
Found BrewPi v0.4.2 build 0.4.2-0-g446b226, running on a Particle Photon with a V2 shield on port /dev/ttyACM0

Current firmware version on controller: 0.4.2

Checking GitHub for available release…

Available releases:

[0] 0.5.4
[1] 0.5.3-rc.3
[2] 0.5.3-rc.2
[3] 0.5.3-rc.1
[4] 0.5.2
[5] 0.5.1
[6] 0.5.0
[7] 0.5.0-rc.3
[8] 0.5.0-rc.2
[9] 0.5.0-rc.1
[10] 0.4.4
[11] 0.4.3
[12] 0.4.3beta3
[13] 0.4.2
[14] 0.4.1
[15] 0.4.0
[16] 0.3.0a
[17] 0.2.11
[18] Cancel firmware update
Enter the number [0-18] of the version you want to program [default = 4 (0.5.2)]: 11
Would you like me to try to restore you settings after programming? [Y/n]:
y
Would you like me to try to restore your configured devices after programming? [Y/n]:
y
Downloading firmware…
downloading https://github.com/BrewPi/firmware/releases/download/0.4.3/brewpi-photon-0.4.3.bin
Traceback (most recent call last):
File “/home/brewpi/utils/updateFirmware.py”, line 268, in
result = updateFromGitHub(userInput=userInput, beta=beta, useDfu=useDfu)
File “/home/brewpi/utils/updateFirmware.py”, line 215, in updateFromGitHub
latestSystemTag = releases.getLatestTagForSystem(prerelease=beta, since=oldVersion)
TypeError: getLatestTagForSystem() takes at least 3 arguments (3 given)

*** Done updating BrewPi! ***

Please refresh your browser with ctrl-F5 to make sure it is not showing an old cached version.

It doesn’t matter which upgrade firmware option I pick I get the same error?

In the BrewPi Error log through the Web interface I get the following compatibility error.

Apr 15 2018 13:09:03 Connecting to controller…
Apr 15 2018 13:09:03 Opening serial port
Apr 15 2018 13:09:03 Checking software version on controller…
Apr 15 2018 13:09:03 Found BrewPi v0.4.2 build 0.4.2-0-g446b226, running on a Particle Photon with a V2 shield on port /dev/ttyACM0

Apr 15 2018 13:09:03 Warning: minimum BrewPi version compatible with this script is 0.5.0 but version number received is 0.4.2
Apr 15 2018 13:09:03 Warning: version number of local copy of logMessages.h does not match log version number received from controller.controller version = 2, local copy version = 3

Please Help! How do I get the Firmware updated to version 0.5.4?

Kyle

Why did you choose 11?

If you run ‘git log’ in /home/brewpi, does it show recent commits?
You can try to run a ‘git pull’ instead of running the update script.

Thanks for the quick reply Elco.

I chose 11 because I thought I might need to upgrade in order. I had tried 0.5.4 and 0.5.2 and had the same issue. So I tried 0.4.3 on this attempt. That is the only reason why I chose 11.

I tried the ‘git log’ and doesn’t seem to have anything recent.

pi@raspberrypi ~ $ cd /home/brewpi
pi@raspberrypi /home/brewpi $ git log
commit 64d3636395e91078a4c6bf004373d067138331cd
Author: Elco Jacobs elcojacobs@gmail.com
Date: Tue Jul 18 17:47:14 2017 +0200

I tried ‘git pull’ and it return this.

pi@raspberrypi /home/brewpi $ git pull
Already up-to-date.

Kyle

The last commit on master is from March 18:

I think you have the release/0.5.0 branch checked out. The last commit on that is from that date.

Please run git checkout master and then do a git pull.

If that doesn’t help, what does git remote -v show? Do you have the right github repository as remote (BrewPi/brewpi-script)?

Here is my results from running the commands you requested.

I have already installed the latest Master Script. I am looking upgrade my firmware. Does the ‘git pull’ command pull Brewpi firmware updates too?

Thanks for your help Elco! I really appreciate it. I have been very impressed with the BrewPi and feel it has been a vital part of my success in winning many awards for the beers I developed and fermented in my controlled fermentation chamber. With all the success it has lead me to an opportunity to partner with a couple guys and open a Brewery in my home town. I absolutely love the ability to keep an eye on fermentation remotely at all times and make adjustments if needed. The BrewPi is an excellent product!

pi@raspberrypi ~ $ cd /home/brewpi
pi@raspberrypi /home/brewpi $ git checkout master
M settings/tempProfile.csv
Switched to branch ‘master’
pi@raspberrypi /home/brewpi $ git pull
Already up-to-date.
pi@raspberrypi /home/brewpi $ git remote -v
origin https://github.com/BrewPi/brewpi-script (fetch)
origin https://github.com/BrewPi/brewpi-script (push)

Try running git log again. I think you’ll have a newer version now.

Hi Elco,
I want to use my BrewPi Spark v2 for controlling my existing fermentation chamber, and to control mash temperature. I got a few questions on this

  1. If you reprogram the Particle Photon, does this mean changing the device configuration?
  2. Where do you save a device configuration?
  3. How many temperatures can be controlled?
  4. Sometimes my BrewPI Spark looses it’s IP address. There is app. 10 m between my WIFI router to my BrewPI, but through a brick wall and a few inner walls?

BR Ken

Here is my out put from the git log now. I only posted items from 2018 that now show up.

Thank you,

Kyle

Last login: Mon Apr 16 19:46:25 2018 from
pi@raspberrypi ~ $ cd /home/brewpi
pi@raspberrypi /home/brewpi $ git log
commit 00957ff58df74a82e0d25420d006c26c08cb3950
Author: Elco Jacobs elco@brewpi.com
Date: Sun Mar 18 15:03:27 2018 +0100

print errors once when opening serial

commit 72dbd015338350d61ebbade909c6b975c50ea744
Author: Elco Jacobs elcojacobs@gmail.com
Date: Mon Mar 12 16:15:00 2018 +0100

fetch version again when unknown (if serial connected after start)

commit 9f5de9e914101a69a8fba7fdfd34926bc83bf10f
Author: Elco Jacobs elco@brewpi.com
Date: Sun Mar 11 21:15:30 2018 +0100

Allow script to run when conneciton to BrewPi Spark is interrupted

commit db799923fb1c3720455d1a5d6ae93860300a3eed
Merge: 231e9b8 65c9fa7
Author: Elco Jacobs elco@brewpi.com
Date: Sun Mar 11 13:25:57 2018 +0100

Merge branch 'feature/flashing-fixes' into develop

commit 65c9fa77d0c646c188dffa0ae339525e2acdc5b3
Author: Elco Jacobs elco@brewpi.com
Date: Sat Mar 10 22:12:09 2018 +0100

fixed delay in restoring settings

commit 1a3b13d5957319e74b2e0200286a7333d987a8da
Author: Elco Jacobs elco@brewpi.com
Date: Sat Mar 10 21:59:53 2018 +0100

print "sending packet x" on same line in ymodem

commit a42bb6409ff8b96c40e8ca09ce6a99a9c2615d7c
Author: Elco Jacobs elco@brewpi.com
Date: Sat Mar 10 21:36:19 2018 +0100

Many fixes to serial background thread and flashing firmware

Do not exit script when serial is lost, better handling of disconnects and f

commit cdf5b97ddfb55daa04c3519a1dcd9ced23fdf78c
Author: Elco Jacobs elco@brewpi.com
Date: Sat Mar 10 15:02:27 2018 +0100

Added flashDFU cli option to only trigger dfu mode

commit 8adc662cc9ff061924812bf05d8d4e93b8bf5949
Author: Elco Jacobs elcojacobs@gmail.com
Date: Fri Mar 9 20:37:13 2018 +0100

fix for releases not defined when used as to downloading dfu-util

commit bc9fe09316b5ece182336e98b9a90653375a7584
Author: Elco Jacobs elcojacobs@gmail.com
Date: Fri Mar 9 20:31:18 2018 +0100

reliability updates for ymodem

I would like to upgrade my spark v2 brewpi to the latest docker-based version. Is there an upgrade guide somehwere? Not sure how I should go about “tearing down” the current installation and moving to the current one. I would appreciate any pointers! thx.

We’ll be releasing the beta of the Big Upgrade soon, so unless you are planning to brew this weekend I would postpone to avoid double work.

1 Like

Thanks for the heads-up! Then I will wait for the upgrade. If you would like me to test the beta, I’d be happy to. Is there any way I can be informed when the release is ready - is there a newsletter or something?

Cheers

For the very first beta release, I won’t do a big announcement just yet. I will just post it here on the forum for our most adventurous users to try.

3 Likes