Skip to content

Commit

Permalink
Merge branch 'test/v4.0.0-alpha.2' into release/v4.x
Browse files Browse the repository at this point in the history
  • Loading branch information
scott-brust committed Jun 23, 2022
2 parents 9cc70b8 + 38d4581 commit 5cfa3ec
Show file tree
Hide file tree
Showing 61 changed files with 1,435 additions and 732 deletions.
4 changes: 2 additions & 2 deletions .buildpackrc
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ export BUILDPACK_VARIATION=manifest
export RELEASE_PLATFORMS=( )

# Platforms for which this firmware is considered experimental
export PRERELEASE_PLATFORMS=( argon boron bsom b5som tracker )
export PRERELEASE_PLATFORMS=( argon boron bsom b5som tracker esomx )
# Note: a single platform should be only in release or prerelease list. If
# added to both it will be considered a prerelease

# Platforms which require modules to be prebuilt
export MODULAR_PLATFORMS=( argon boron bsom b5som tracker )
export MODULAR_PLATFORMS=( argon boron bsom b5som tracker esomx)

8 changes: 4 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ orbs:

aliases:
- &tasks ["compile:all clean:all", "compile:user clean:user", "compile:debug clean:debug"]
- &platforms ["argon", "boron", "bsom", "b5som", "tracker"]
- &platforms ["argon", "boron", "esomx", "bsom", "b5som", "tracker"]

# Define a job to be invoked later in a workflow.
# See: https://circleci.com/docs/2.0/configuration-reference/#jobs
Expand Down Expand Up @@ -300,7 +300,7 @@ commands:
- run:
name: "Install `prtcl` CLI (ubuntu)"
command: |
printf 'Acquire::http::Timeout "30";\nAcquire::ftp::Timeout "30";\nAcquire::Retries "5";\n' | sudo tee /etc/apt/apt.conf.d/99timeout > /dev/null
printf 'Acquire::http::Timeout "60";\nAcquire::ftp::Timeout "60";\nAcquire::Retries "15";\n' | sudo tee /etc/apt/apt.conf.d/99timeout > /dev/null
sudo apt-get update -q
sudo apt-get install -qy zlib1g-dev jq
sudo curl https://prtcl.s3.amazonaws.com/install-apt.sh | sh
Expand Down Expand Up @@ -340,7 +340,7 @@ commands:
steps:
- run:
name: "Test Local Compilation Tasks"
no_output_timeout: "10m"
no_output_timeout: "20m"
command: scripts/test-build-tasks.sh ~/project "<< parameters.platform >>" "<< parameters.tasks >>"
environment:
PRTCL_DISABLE_AUTOUPDATE: "1"
Expand Down Expand Up @@ -472,7 +472,7 @@ workflows:
- particle-ci-private
matrix:
parameters:
platform: ["argon", "boron", "bsom", "b5som", "tracker", "unit-test newhal gcc"]
platform: ["argon", "boron", "esomx", "bsom", "b5som", "tracker", "unit-test newhal gcc"]
- combine-binaries:
requires:
- build-and-test
Expand Down
4 changes: 2 additions & 2 deletions .workbench/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
"version": "1.0.0",
"toolchains": [
{
"platforms": [12, 13, 23, 25, 26],
"platforms": [12, 13, 15, 23, 25, 26],
"firmware": "deviceOS@source",
"compilers": "gcc-arm@10.2.1",
"tools": "buildtools@1.1.1",
"scripts": "buildscripts@1.10.0",
"debuggers": "openocd@0.11.2-adhoc6ea4372.0"
"debuggers": "openocd@0.11.0-particle.4"
}
]
}
17 changes: 17 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,20 @@
## 4.0.0-alpha.2

> ## :warning: Please note this is in internal release, do not use on production devices!
### FEATURES
- [esomx] Adds support for new platform esomx [#2443](https://github.com/particle-iot/device-os/pull/2443) [#2459](https://github.com/particle-iot/device-os/pull/2459)
- [E404X] Determine flash part at runtime [#2456](https://github.com/particle-iot/device-os/pull/2456)
- [gen3][quectel] Adds support for BG95-M1, BG95-MF, BG77, and EG91-NAX [#2458](https://github.com/particle-iot/device-os/pull/2458)

### BUGFIXES
- [gen3] hal: fix power leak on Boron [#2452](https://github.com/particle-iot/device-os/pull/2452)

### INTERNAL

- [workbench] update-device-os-workbench-manifest-json [#2457](https://github.com/particle-iot/device-os/pull/2457)
- [ci] test-build-system-tune-timeouts [#2455](https://github.com/particle-iot/device-os/pull/2455)

## 4.0.0-alpha.1

> ## :warning: Please note this is in internal release, do not use on production devices!
Expand Down
3 changes: 2 additions & 1 deletion bootloader/src/nRF52840/sources.mk
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@ CPPSRC += $(call target_files,$(BOOTLOADER_SRC_PATH)/,*.cpp)

CSRC += $(call target_files,$(BOOTLOADER_MODULE_PATH)/../hal/src/nRF52840/,flash_hal.c)
CPPSRC += $(call target_files,$(BOOTLOADER_MODULE_PATH)/../hal/shared/,flash_common.cpp)
CSRC += $(call target_files,$(BOOTLOADER_MODULE_PATH)/../hal/src/nRF52840/,exflash_hal.c)
CPPSRC += $(call target_files,$(BOOTLOADER_MODULE_PATH)/../hal/src/nRF52840/,exflash_hal.cpp)
CPPSRC += $(call target_files,$(BOOTLOADER_MODULE_PATH)/../hal/src/nRF52840/,exflash_hal_lock.cpp)
CPPSRC += $(call target_files,$(BOOTLOADER_MODULE_PATH)/../hal/src/nRF52840/,exflash_hal_params.cpp)
CSRC += $(call target_files,$(BOOTLOADER_MODULE_PATH)/../hal/src/nRF52840/,rgbled_hal.c)
CSRC += $(call target_files,$(BOOTLOADER_MODULE_PATH)/../hal/src/nRF52840/,watchdog_hal.c)
CSRC += $(call target_files,$(BOOTLOADER_MODULE_PATH)/../hal/src/nRF52840/,pinmap_hal.c)
Expand Down
2 changes: 2 additions & 0 deletions bootloader/src/nRF52840/usbd_device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,8 @@ class NrfDevice : public Device {
# define USBD_PRODUCT_NAME "Argon"
#elif PLATFORM_ID == PLATFORM_BORON
# define USBD_PRODUCT_NAME "Boron"
#elif PLATFORM_ID == PLATFORM_ESOMX
# define USBD_PRODUCT_NAME "E SoM X"
#elif PLATFORM_ID == PLATFORM_ASOM
# define USBD_PRODUCT_NAME "A SoM"
#elif PLATFORM_ID == PLATFORM_BSOM
Expand Down
2 changes: 1 addition & 1 deletion bootloader/src/nRF52840/usbd_dfu_mal.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
#define DCD_IF_STRING "@DCD Flash /0x00000000/1*016Ke";

#define EXTERNAL_FLASH_START_ADD 0x00000000
#if PLATFORM_ID == PLATFORM_B5SOM || PLATFORM_ID == PLATFORM_TRACKER
#if PLATFORM_ID == PLATFORM_B5SOM || PLATFORM_ID == PLATFORM_TRACKER || PLATFORM_ID == PLATFORM_ESOMX
#define EXTERNAL_FLASH_END_ADDR 0x00800000
#define EXTERNAL_FLASH_IF_STRING "@External Flash /0x80000000/2048*004Kg";
#else
Expand Down
1 change: 1 addition & 0 deletions build/create_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ class ModuleFunction(IntEnum):
class Platform(IntEnum):
ARGON = 12
BORON = 13
ESOMX = 15
ASOM = 22
BSOM = 23
B5SOM = 25
Expand Down
5 changes: 3 additions & 2 deletions build/make_release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ function display_help ()
usage: make_release.sh [--debug] [--help]
[--output-directory=<binary_output_directory>]
[--platform=<all|argon|asom|boron|bsom...
|b5som|tracker>]
|b5som|tracker|esomx>]
[--publish=<semantic_version_string>] [--tests]
Generate the binaries for a versioned release of the Device OS. This utility
Expand Down Expand Up @@ -129,7 +129,7 @@ function valid_platform()
platform=$1

# Validate platform (result of expression returned to caller)
[ "$platform" = "all" ] || [ "$platform" = "argon" ] || [ "$platform" = "asom" ] || [ "$platform" = "boron" ] || [ "$platform" = "bsom" ] || [ "$platform" = "b5som" ] || [ "$platform" = "tracker" ]
[ "$platform" = "all" ] || [ "$platform" = "argon" ] || [ "$platform" = "asom" ] || [ "$platform" = "boron" ] || [ "$platform" = "bsom" ] || [ "$platform" = "b5som" ] || [ "$platform" = "tracker" ] || [ "$platform" = "esomx" ]
}

if !(valid_platform $PLATFORM); then
Expand All @@ -151,6 +151,7 @@ if [ $PLATFORM = "all" ]; then
release_platform "bsom"
release_platform "b5som"
release_platform "tracker"
release_platform "esomx"
else
release_platform "$PLATFORM"
fi
Expand Down
2 changes: 1 addition & 1 deletion build/module.mk
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ SOURCE_PATH ?= $(MODULE_PATH)
include $(MODULE_PATH)/import.mk

# FIXME: find a better place for this
ifneq (,$(filter $(PLATFORM_ID),12 13 22 23 25 26))
ifneq (,$(filter $(PLATFORM_ID),12 13 15 22 23 25 26))
ifneq ("$(BOOTLOADER_MODULE)","1")
export SOFTDEVICE_PRESENT=y
CFLAGS += -DSOFTDEVICE_PRESENT=1
Expand Down
22 changes: 22 additions & 0 deletions build/platform-id.mk
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@ ifeq ("$(PLATFORM)","boron")
PLATFORM_ID=13
endif

ifeq ("$(PLATFORM)","esomx")
PLATFORM_ID=15
endif

ifeq ("$(PLATFORM)","asom")
PLATFORM_ID=22
endif
Expand Down Expand Up @@ -115,6 +119,24 @@ ARM_CPU=cortex-m4
PLATFORM_THREADING=1
endif

ifeq ("$(PLATFORM_ID)","15")
PLATFORM=esomx
PLATFORM_NAME=boron
PLATFORM_GEN=3
PLATFORM_MCU=nRF52840
PLATFORM_NET=UBLOXSARA
PLATFORM_WIZNET=W5500
MCU_DEVICE=nRF52840
PRODUCT_DESC=Production E SoM X
USBD_VID_PARTICLE=0x2B04
USBD_PID_DFU=0xD00F
USBD_PID_CDC=0xC00F
DEFAULT_PRODUCT_ID=$(PLATFORM_ID)
PLATFORM_DYNALIB_MODULES=boron
ARM_CPU=cortex-m4
PLATFORM_THREADING=1
endif

ifeq ("$(PLATFORM_ID)","22")
PLATFORM=asom
PLATFORM_NAME=argon
Expand Down
2 changes: 1 addition & 1 deletion build/release-publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ function valid_platform()
platform=$1

# Validate platform (result of expression returned to caller)
[ "$platform" = "argon" ] || [ "$platform" = "asom" ] || [ "$platform" = "boron" ] || [ "$platform" = "bsom" ] || [ "$platform" = "b5som" ] || [ "$platform" = "tracker" ]
[ "$platform" = "argon" ] || [ "$platform" = "asom" ] || [ "$platform" = "boron" ] || [ "$platform" = "bsom" ] || [ "$platform" = "b5som" ] || [ "$platform" = "tracker" ] || [ "$platform" = "esomx" ]
}

# Identify the absolute directory
Expand Down
7 changes: 5 additions & 2 deletions build/release-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ usage: release-tests.sh [--dryrun] [--help]
[--filename=<test_parameter_file.json>]
--output-directory=<binary_output_directory>
--platform=<argon|asom|boron|bsom...
|b5som|tracker>
|b5som|tracker|esomx>
--version=<semver_version_string>
Generate the testing binaries belonging to a given platform.
Expand Down Expand Up @@ -107,7 +107,7 @@ function valid_platform ()
platform=$1

# Validate platform (result of expression returned to caller)
[ "$platform" = "argon" ] || [ "$platform" = "asom" ] || [ "$platform" = "boron" ] || [ "$platform" = "bsom" ] || [ "$platform" = "b5som" ] || [ "$platform" = "tracker" ]
[ "$platform" = "argon" ] || [ "$platform" = "asom" ] || [ "$platform" = "boron" ] || [ "$platform" = "bsom" ] || [ "$platform" = "b5som" ] || [ "$platform" = "tracker" ] || [ "$platform" = "esomx" ]
}

# Handle invalid arguments
Expand Down Expand Up @@ -136,6 +136,9 @@ case "$PLATFORM" in
"boron")
PLATFORM_ID="13"
;;
"esomx")
PLATFORM_ID="15"
;;
"asom")
PLATFORM_ID="22"
;;
Expand Down
16 changes: 12 additions & 4 deletions build/release.sh
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
#!/bin/bash
set -o errexit -o pipefail -o noclobber -o nounset

VERSION=${VERSION:="4.0.0-alpha.1"}
VERSION=${VERSION:="4.0.0-alpha.2"}

function display_help ()
{
echo '
usage: release.sh [--output-directory=<binary_output_directory>]
(--platform=<argon|asom|boron|bsom...
|b5som>...
| --platform-id=<12|13|22|23|25|26>)
|b5som|esomx>...
| --platform-id=<12|13|15|22|23|25|26>)
[--debug] [--help] [--tests]
Generate the binaries for a versioned release of the Device OS. This utility
Expand Down Expand Up @@ -218,6 +218,10 @@ elif [ ! -z $PLATFORM ]; then
PLATFORM_ID="13"
GEN3=true
;;
"esomx")
PLATFORM_ID="15"
GEN3=true
;;
"asom")
PLATFORM_ID="22"
GEN3=true
Expand Down Expand Up @@ -249,6 +253,10 @@ else
PLATFORM="boron"
GEN3=true
;;
15)
PLATFORM="esomx"
GEN3=true
;;
22)
PLATFORM="asom"
GEN3=true
Expand Down Expand Up @@ -305,7 +313,7 @@ rm -rf $ABSOLUTE_TARGET_DIRECTORY/
#########################

# GEN3
if [ $PLATFORM_ID -eq 12 ] || [ $PLATFORM_ID -eq 13 ] || [ $PLATFORM_ID -eq 22 ] || [ $PLATFORM_ID -eq 23 ] || [ $PLATFORM_ID -eq 25 ] || [ $PLATFORM_ID -eq 26 ]; then
if [ $PLATFORM_ID -eq 12 ] || [ $PLATFORM_ID -eq 13 ] || [ $PLATFORM_ID -eq 15 ] || [ $PLATFORM_ID -eq 22 ] || [ $PLATFORM_ID -eq 23 ] || [ $PLATFORM_ID -eq 25 ] || [ $PLATFORM_ID -eq 26 ]; then
# Configure
if [ $DEBUG = true ]; then
cd ../main
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 = 4.0.0-alpha.1
VERSION_STRING = 4.0.0-alpha.2

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

CFLAGS += -DSYSTEM_VERSION_STRING=$(VERSION_STRING)
2 changes: 1 addition & 1 deletion ci/cf_generate_message.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ EOF
)

fields=""
for p in Argon Boron BSoM B5SoM Tracker GCC Newhal; do
for p in Argon Boron BSoM B5SoM Tracker ESoMX GCC Newhal; do
if echo -e "${failures}" | grep -q "PLATFORM=\"${p,,}\""; then
msg=":scrum_closed: $p\\n"
else
Expand Down
8 changes: 4 additions & 4 deletions ci/enumerate_build_matrix.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@ MAKE=runmake
# define build matrix dimensions
# "" means execute execute the $MAKE command without that var specified
DEBUG_BUILD=( y n )
PLATFORM=( argon boron asom bsom b5som )
PLATFORM_BOOTLOADER=( argon boron asom bsom b5som tracker )
PLATFORM=( argon boron asom bsom b5som esomx )
PLATFORM_BOOTLOADER=( argon boron asom bsom b5som tracker esomx )
APP=( "" tinker product_id_and_version)
TEST=( wiring/api wiring/no_fixture wiring/no_fixture_long_running )

MODULAR_PLATFORM=( argon boron asom bsom b5som tracker )
MODULAR_PLATFORM=( argon boron asom bsom b5som tracker esomx )

filterPlatform PLATFORM
filterPlatform MODULAR_PLATFORM
Expand Down Expand Up @@ -147,7 +147,7 @@ do
do
# Gen 3 overflows with modular DEBUG_BUILD=y, so skip those
if [[ "$db" = "y" ]]; then
if [[ "$p" = "argon" ]] || [[ "$p" = "boron" ]] || [[ "$p" = "asom" ]] || [[ "$p" = "bsom" ]] || [[ "$p" = "b5som" ]] || [[ "$p" = "tracker" ]]; then
if [[ "$p" = "argon" ]] || [[ "$p" = "boron" ]] || [[ "$p" = "asom" ]] || [[ "$p" = "bsom" ]] || [[ "$p" = "b5som" ]] || [[ "$p" = "tracker" ]] || [[ "$p" = "esomx" ]]; then
continue
fi
fi
Expand Down
2 changes: 1 addition & 1 deletion communication/src/build.mk
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ CPPSRC += $(TARGET_SRC_PATH)/description.cpp
ASRC +=

# if PLATFORM_ID matches 13 23 25 or 26, and not DEBUG_BUILD=y, set LOG_LEVEL_ERROR
ifneq (,$(filter $(PLATFORM_ID), 13 23 25 26))
ifneq (,$(filter $(PLATFORM_ID), 13 15 23 25 26))
ifneq ($(DEBUG_BUILD),y)
CFLAGS += -DLOG_COMPILE_TIME_LEVEL=LOG_LEVEL_ERROR
endif
Expand Down
3 changes: 1 addition & 2 deletions hal/build.mk
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ include $(call rwildcard,$(HAL_PLATFORM_SRC_PATH)/,sources.mk)

LOG_MODULE_CATEGORY = hal

# if PLATFORM_ID matches 13 23 25 or 26, and not DEBUG_BUILD=y, set LOG_LEVEL_ERROR
ifneq (,$(filter $(PLATFORM_ID),13 23 25 26))
ifneq (,$(filter $(PLATFORM_ID),13 15 23 25 26))
ifneq ($(DEBUG_BUILD),y)
CFLAGS += -DLOG_COMPILE_TIME_LEVEL=LOG_LEVEL_ERROR
endif
Expand Down
4 changes: 3 additions & 1 deletion hal/inc/exflash_hal.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ typedef enum hal_exflash_command_t {
HAL_EXFLASH_COMMAND_SLEEP = 2,
HAL_EXFLASH_COMMAND_WAKEUP = 3,
HAL_EXFLASH_COMMAND_SUSPEND_PGMERS = 4,
HAL_EXFLASH_COMMAND_RESET = 5
HAL_EXFLASH_COMMAND_RESET = 5,
HAL_EXFLASH_COMMAND_READID = 6,
HAL_EXFLASH_COMMAND_GET_OTP_SIZE = 7,
} hal_exflash_command_t;

typedef enum hal_exflash_state_t {
Expand Down
8 changes: 0 additions & 8 deletions hal/inc/hal_platform.h
Original file line number Diff line number Diff line change
Expand Up @@ -314,14 +314,6 @@
#define HAL_PLATFORM_GEN (PLATFORM_GEN)
#endif // HAL_PLATFORM_GEN

#ifndef HAL_PLATFORM_FLASH_MX25R6435FZNIL0
#define HAL_PLATFORM_FLASH_MX25R6435FZNIL0 (0)
#endif // HAL_PLATFORM_FLASH_MX25R6435FZNIL0

#ifndef HAL_PLATFORM_FLASH_MX25L3233F
#define HAL_PLATFORM_FLASH_MX25L3233F (0)
#endif // HAL_PLATFORM_FLASH_MX25L3233F

#ifndef HAL_PLATFORM_IO_EXTENSION
#define HAL_PLATFORM_IO_EXTENSION (0)
#endif // HAL_PLATFORM_IO_EXTENSION
Expand Down
Loading

0 comments on commit 5cfa3ec

Please sign in to comment.