Skip to content

Commit

Permalink
bump module version for 1.4.2 (v1404)
Browse files Browse the repository at this point in the history
- updates CHANGELOG.md
- updates upgrade-downgrade script
- updates release scripts
- bumps Gen 3 bootloader dependency to 501 (1.4.2)
- bumps SoftDevice bootloader dependency to 501 (1.4.2)
  • Loading branch information
avtolstoy committed Oct 18, 2019
1 parent 75ddda6 commit f01a75e
Show file tree
Hide file tree
Showing 8 changed files with 49 additions and 35 deletions.
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
## 1.4.2

>**Note:** If your Gen 2 Photon/P1 or Gen 3 device does not have a Cloud connection, it is recommended to update system firmware, and then the bootloader via CLI with `particle flash --serial bootloader.bin` (bootloaders found in Github release).
>**Note:** If your Gen 3 device does not have a Cloud connection, this release will also require manually updating the SoftDevice via CLI. The instructions are available in the release notes and the SoftDevice binaries are available in the Github release.
>
>This release contains v501 bootloaders.
### BUGFIXES

- [Gen 3] Fixes a boot/crash-loop due to a `POWER_CLOCK_IRQn` firing in between the jump into the system firmware from the bootloader [#1948](https://github.com/particle-iot/device-os/pull/1948)

## 1.4.1

>**Note:** If your Gen 2 Photon/P1 or Gen 3 device does not have a Cloud connection, it is recommended to update system firmware, and then the bootloader via CLI with `particle flash --serial bootloader.bin` (bootloaders found in Github release).
Expand Down
2 changes: 1 addition & 1 deletion build/create_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ def parse_dependency(dep):
GEN3_RADIO_STACK_MBR_OFFSET = 0x1000
GEN3_RADIO_STACK_FLAGS = ModuleFlags.DROP_MODULE_INFO
# A bootloader and system-part1 supporting SoftDevice updates are required for radio stack modules generate for Gen 3 platforms
GEN3_RADIO_STACK_DEPENDENCY = ModuleDependency(ModuleFunction.BOOTLOADER, 401)
GEN3_RADIO_STACK_DEPENDENCY = ModuleDependency(ModuleFunction.BOOTLOADER, 501)
GEN3_RADIO_STACK_DEPENDENCY2 = ModuleDependency(ModuleFunction.SYSTEM_PART, 1321, 1)

def main():
Expand Down
2 changes: 1 addition & 1 deletion build/release.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
set -o errexit -o pipefail -o noclobber -o nounset

VERSION="1.4.1"
VERSION="1.4.2"

function display_help ()
{
Expand Down
4 changes: 2 additions & 2 deletions build/version.mk
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
VERSION_STRING = 1.4.1
VERSION_STRING = 1.4.2

# PRODUCT_FIRMWARE_VERSION reported by default
# FIXME: Unclear if this is used, PRODUCT_FIRMWARE_VERSION defaults to 65535 every release
VERSION = 1403
VERSION = 1404

CFLAGS += -DSYSTEM_VERSION_STRING=$(VERSION_STRING)
6 changes: 3 additions & 3 deletions modules/shared/system_module_version.mk
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Skip to next 100 every v0.x.0 release (e.g. 108 for v0.6.2 to 200 for v0.7.0-rc.1)
# Bump by 1 for every prerelease or release with the same v0.x.* base.
COMMON_MODULE_VERSION ?= 1403
COMMON_MODULE_VERSION ?= 1404
SYSTEM_PART1_MODULE_VERSION ?= $(COMMON_MODULE_VERSION)
SYSTEM_PART2_MODULE_VERSION ?= $(COMMON_MODULE_VERSION)
SYSTEM_PART3_MODULE_VERSION ?= $(COMMON_MODULE_VERSION)
Expand Down Expand Up @@ -32,15 +32,15 @@ endif
# Skip to next 100 every v0.x.0 release (e.g. 11 for v0.6.2 to 100 for v0.7.0-rc.1),
# but only if the bootloader has changed since the last v0.x.0 release.
# Bump by 1 for every updated bootloader image for a release with the same v0.x.* base.
BOOTLOADER_VERSION ?= 500
BOOTLOADER_VERSION ?= 501

# The version of the bootloader that the system firmware requires
# NOTE: this will force the device into safe mode until this dependency is met, which is why
# this version usually lags behind the current bootloader version, to avoid non-mandatory updates.
ifeq ($(PLATFORM_GEN),2)
BOOTLOADER_DEPENDENCY = 400
else ifeq ($(PLATFORM_GEN),3)
BOOTLOADER_DEPENDENCY = 401
BOOTLOADER_DEPENDENCY = 501
else
# Some sensible default
BOOTLOADER_DEPENDENCY = 0
Expand Down
4 changes: 3 additions & 1 deletion system/inc/system_version.h
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,8 @@ extern "C" {
#define SYSTEM_VERSION_v140 SYSTEM_VERSION_DEFAULT(1, 4, 0)
#define SYSTEM_VERSION_v141RC1 SYSTEM_VERSION_RC(1, 4, 1, 1)
#define SYSTEM_VERSION_v141 SYSTEM_VERSION_DEFAULT(1, 4, 1)
#define SYSTEM_VERSION SYSTEM_VERSION_v141
#define SYSTEM_VERSION_v142 SYSTEM_VERSION_DEFAULT(1, 4, 2)
#define SYSTEM_VERSION SYSTEM_VERSION_v142

/**
* Previously we would set the least significant byte to 0 for the final release, but to make
Expand Down Expand Up @@ -241,6 +242,7 @@ extern "C" {
#define SYSTEM_VERSION_140
#define SYSTEM_VERSION_141RC1
#define SYSTEM_VERSION_141
#define SYSTEM_VERSION_142

typedef struct __attribute__((packed)) SystemVersionInfo
{
Expand Down
1 change: 1 addition & 0 deletions system/system-versions.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@
| 500 | 1401 | 1.4.0 | Core, Photon, P1, Electron, Xenon, Argon, Boron, X SoM, A SoM, B SoM |
| 500 | 1402 | 1.4.1-rc.1 | Core, Photon, P1, Electron, Xenon, Argon, Boron, X SoM, A SoM, B SoM |
| 500 | 1403 | 1.4.1 | Core, Photon, P1, Electron, Xenon, Argon, Boron, X SoM, A SoM, B SoM |
| 501 | 1404 | 1.4.2 | Core, Photon, P1, Electron, Xenon, Argon, Boron, X SoM, A SoM, B SoM |

[1] For 0.8.0-rc.1, The v101 bootloader was also released in the Github releases as v200. Thus the next released bootloader in the 0.8.x line should be v201. As of 4/5/2018: 22 device had v200 bootloaders.

Expand Down
54 changes: 27 additions & 27 deletions user/tests/scripts/upgrade-downgrade/upgrade-downgrade.sh
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,10 @@ export PHOTON_SP1_121="https://github.com/particle-iot/device-os/releases/downlo
export PHOTON_SP2_121="https://github.com/particle-iot/device-os/releases/download/v1.2.1/[email protected]"
export PHOTON_SP1_121_MOD=1213
export PHOTON_SP2_121_MOD=1213
export PHOTON_SP1_141="https://github.com/particle-iot/device-os/releases/download/v1.4.1/[email protected].1.bin"
export PHOTON_SP2_141="https://github.com/particle-iot/device-os/releases/download/v1.4.1/[email protected].1.bin"
export PHOTON_SP1_141_MOD=1403
export PHOTON_SP2_141_MOD=1403
export PHOTON_SP1_142="https://github.com/particle-iot/device-os/releases/download/v1.4.2/[email protected].2.bin"
export PHOTON_SP2_142="https://github.com/particle-iot/device-os/releases/download/v1.4.2/[email protected].2.bin"
export PHOTON_SP1_142_MOD=1404
export PHOTON_SP2_142_MOD=1404

# instead of these set options,
# set script options
Expand Down Expand Up @@ -418,11 +418,11 @@ set_country() {
# | 61 | photon | 0.6.3 | 0.7.0 | part1, part2 | yes | ok |
# | 62 | photon | 0.7.0 | 1.2.1 | part2, part1 | no, part2 rejected | ok |
# | 63 | photon | 0.7.0 | 1.2.1 | part1, part2 | yes | ok |
# | 64 | photon | 1.2.1 | 1.4.1 | part2, part1 | no, part2 rejected | ok |
# | 65 | photon | 1.2.1 | 1.4.1 | part1, part2 | yes | ok |
# | 64 | photon | 1.2.1 | 1.4.2 | part2, part1 | no, part2 rejected | ok |
# | 65 | photon | 1.2.1 | 1.4.2 | part1, part2 | yes | ok |
# ------------------------ downgrade -------------------------------------------------------------+
# | 65 | photon | 1.4.1 | 1.2.1 | part1, part2 | no, part1 rejected | ok |
# | 66 | photon | 1.4.1 | 1.2.1 | part2, part1 | yes | ok |
# | 65 | photon | 1.4.2 | 1.2.1 | part1, part2 | no, part1 rejected | ok |
# | 66 | photon | 1.4.2 | 1.2.1 | part2, part1 | yes | ok |
# | 67 | photon | 1.2.1 | 0.7.0 | part1, part2 | no, part1 rejected | ok |
# | 68 | photon | 1.2.1 | 0.7.0 | part2, part1 | yes | ok |
# | 69 | photon | 0.7.0 | 0.6.3 | part1, part2 | no, part1 rejected | ok |
Expand Down Expand Up @@ -1698,10 +1698,10 @@ if true; then

heading
echo "+----+--------+------------+----------------------+--------------+--------------------+--------+"
echo "| 64 | photon | 1.2.1 | 1.4.1 | part2, part1 | no, part2 rejected | ok |"
echo "| 64 | photon | 1.2.1 | 1.4.2 | part2, part1 | no, part2 rejected | ok |"
echo "+----+--------+------------+----------------------+--------------+--------------------+--------+"
enter_ymodem
ymodem_part 2 1.4.1 photon
ymodem_part 2 1.4.2 photon
enter_dfu_mode
try exit_dfu_mode

Expand All @@ -1713,27 +1713,27 @@ if true; then

heading
echo "+----+--------+------------+----------------------+--------------+--------------------+--------+"
echo "| 65 | photon | 1.2.1 | 1.4.1 | part1, part2 | yes | ok |"
echo "| 65 | photon | 1.2.1 | 1.4.2 | part1, part2 | yes | ok |"
echo "+----+--------+------------+----------------------+--------------+--------------------+--------+"
enter_ymodem
try ymodem_part 1 1.4.1 photon
try ymodem_part 1 1.4.2 photon
try run_cli_list_subcommand_and_confirm_device_shows_up_as_online
enter_ymodem
try serial_inspect
try compare_system_version 1 ${PHOTON_SP1_141_MOD}
try compare_system_version 1 ${PHOTON_SP1_142_MOD}
try compare_system_version 2 ${PHOTON_SP2_121_MOD}

enter_ymodem
try ymodem_part 2 1.4.1 photon
# wait for 1.4.1 bootloader from SMH
particle flash --serial bootloader-1.4.1-photon.bin
try ymodem_part 2 1.4.2 photon
# wait for 1.4.2 bootloader from SMH
particle flash --serial bootloader-1.4.2-photon.bin
sleep 30

try run_cli_list_subcommand_and_confirm_device_shows_up_as_online
enter_ymodem
try serial_inspect
try compare_system_version 1 ${PHOTON_SP1_141_MOD}
try compare_system_version 2 ${PHOTON_SP2_141_MOD}
try compare_system_version 1 ${PHOTON_SP1_142_MOD}
try compare_system_version 2 ${PHOTON_SP2_142_MOD}
pass

# ------------------------ downgrade -------------------------------------------------------------
Expand All @@ -1742,7 +1742,7 @@ if true; then

heading
echo "+----+--------+------------+----------------------+--------------+--------------------+--------+"
echo "| 66 | photon | 1.4.1 | 1.2.1 | part1, part2 | no, part1 rejected | ok |"
echo "| 66 | photon | 1.4.2 | 1.2.1 | part1, part2 | no, part1 rejected | ok |"
echo "+----+--------+------------+----------------------+--------------+--------------------+--------+"
enter_ymodem
ymodem_part 1 1.2.1 photon
Expand All @@ -1752,20 +1752,20 @@ if true; then
try run_cli_list_subcommand_and_confirm_device_shows_up_as_online
enter_ymodem
try serial_inspect
try compare_system_version 1 ${PHOTON_SP1_141_MOD}
try compare_system_version 2 ${PHOTON_SP2_141_MOD}
try compare_system_version 1 ${PHOTON_SP1_142_MOD}
try compare_system_version 2 ${PHOTON_SP2_142_MOD}
pass

heading
echo "+----+--------+------------+----------------------+--------------+--------------------+--------+"
echo "| 67 | photon | 1.4.1 | 1.2.1 | part2, part1 | yes | ok |"
echo "| 67 | photon | 1.4.2 | 1.2.1 | part2, part1 | yes | ok |"
echo "+----+--------+------------+----------------------+--------------+--------------------+--------+"
enter_ymodem
try ymodem_part 2 1.2.1 photon
try run_cli_list_subcommand_and_confirm_device_shows_up_as_online
enter_ymodem
try serial_inspect
try compare_system_version 1 ${PHOTON_SP1_141_MOD}
try compare_system_version 1 ${PHOTON_SP1_142_MOD}
try compare_system_version 2 ${PHOTON_SP2_121_MOD}

enter_ymodem
Expand Down Expand Up @@ -2135,11 +2135,11 @@ curl_all_required_system_parts() {
curl -L "$PHOTON_SP2_121" -o "system-part2-1.2.1-photon.bin"; if [[ "$?" -ne 0 ]]; then return 1; fi
fi

if [ ! -e "system-part1-1.4.1-photon.bin" ]; then
curl -L "$PHOTON_SP1_141" -o "system-part1-1.4.1-photon.bin"; if [[ "$?" -ne 0 ]]; then return 1; fi
if [ ! -e "system-part1-1.4.2-photon.bin" ]; then
curl -L "$PHOTON_SP1_142" -o "system-part1-1.4.2-photon.bin"; if [[ "$?" -ne 0 ]]; then return 1; fi
fi
if [ ! -e "system-part2-1.4.1-photon.bin" ]; then
curl -L "$PHOTON_SP2_141" -o "system-part2-1.4.1-photon.bin"; if [[ "$?" -ne 0 ]]; then return 1; fi
if [ ! -e "system-part2-1.4.2-photon.bin" ]; then
curl -L "$PHOTON_SP2_142" -o "system-part2-1.4.2-photon.bin"; if [[ "$?" -ne 0 ]]; then return 1; fi
fi

if [ ! -e "tinker-v0.4.9-photon.bin" ]; then
Expand Down

0 comments on commit f01a75e

Please sign in to comment.