Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support thingy91x #18

Merged
merged 8 commits into from
Dec 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/build_zephyr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ jobs:
west init -l app
west update --narrow -o=--depth=1
west zephyr-export
pip3 install ecdsa # Thingy91x
pip3 install -r deps/zephyr/scripts/requirements-base.txt
# Needed for TF-M
pip3 install cryptography pyasn1 pyyaml cbor>=1.0.0 imgtool>=1.9.0 jinja2 click
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
strategy:
matrix:
ZEPHYR_SDK: [0.16.3]
BOARD: ["thingy91/nrf9160/ns"]
BOARD: ["thingy91/nrf9160/ns", "thingy91x/nrf9151/ns"]

uses: ./.github/workflows/build_zephyr.yml
with:
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,9 @@ jobs:
ZEPHYR_SDK: 0.16.3
BOARD: thingy91/nrf9160/ns
ARTIFACT: false
test_build_thingy91x:
uses: ./.github/workflows/build_zephyr.yml
with:
ZEPHYR_SDK: 0.16.3
BOARD: thingy91x/nrf9151/ns
ARTIFACT: false
52 changes: 12 additions & 40 deletions boards/thingy91_nrf9160_ns.conf
Original file line number Diff line number Diff line change
@@ -1,45 +1,17 @@
# Copyright (c) 2022 Golioth, Inc.
# Copyright (c) 2024 Golioth, Inc.
# SPDX-License-Identifier: Apache-2.0

# General config
CONFIG_HEAP_MEM_POOL_SIZE=4096
CONFIG_NEWLIB_LIBC=y
CONFIG_BH1749=y
CONFIG_BH1749_TRIGGER=y

# Networking
CONFIG_NET_SOCKETS_OFFLOAD=y
CONFIG_NET_IPV6=y
CONFIG_NET_IPV6_NBR_CACHE=n
CONFIG_NET_IPV6_MLD=n
CONFIG_BME680=y

# Increase native TLS socket implementation, so that it is chosen instead of
# offloaded nRF91 sockets
CONFIG_NET_SOCKETS_TLS_PRIORITY=35
CONFIG_ADXL362=y
CONFIG_ADXL362_TRIGGER_GLOBAL_THREAD=y
CONFIG_ADXL362_INTERRUPT_MODE=1
CONFIG_ADXL362_ABS_REF_MODE=1
CONFIG_ADXL362_ACCEL_RANGE_2G=y
CONFIG_ADXL362_ACCEL_ODR_12_5=y

# Modem library
CONFIG_NRF_MODEM_LIB=y

# LTE connectivity with network connection manager
CONFIG_NRF_MODEM_LIB_NET_IF=y
CONFIG_NRF_MODEM_LIB_NET_IF_AUTO_START=y
CONFIG_NRF_MODEM_LIB_NET_IF_AUTO_CONNECT=n
CONFIG_NET_CONNECTION_MANAGER=y
CONFIG_NET_CONNECTION_MANAGER_MONITOR_STACK_SIZE=1024

# Add Logs for LTE Link Handler
CONFIG_GOLIOTH_SAMPLE_NRF91_LTE_MONITOR=y

# Disable options y-selected by NCS for no good reason
CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED=n
CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED=n

# MbedTLS configuration to support p-384 curve. These options
# enable using the MbedTLS built-in support for operations not
# supported by the default nRF Oberon crypto backend
CONFIG_NORDIC_SECURITY_BACKEND=n
CONFIG_MBEDTLS_LEGACY_CRYPTO_C=y

# Add Network Info Support
CONFIG_MODEM_INFO=y

# Generate MCUboot compatible images
CONFIG_BOOTLOADER_MCUBOOT=y
# Disable unused libraries to save flash
CONFIG_ADXL372=n
4 changes: 0 additions & 4 deletions boards/thingy91_nrf9160_ns.overlay
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
/ {
aliases {
click-uart = &uart1;
click-i2c = &i2c2;
golioth-led = &green_led;
user-led = &blue_led;
sw1 = &button0;
buzzer-pwm = &buzzer;
};
Expand Down
7 changes: 7 additions & 0 deletions boards/thingy91x_nrf9151_ns.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Copyright (c) 2024 Golioth, Inc.
# SPDX-License-Identifier: Apache-2.0

CONFIG_BME680=n
CONFIG_BME68X_IAQ=y
CONFIG_BME68X_IAQ_THREAD_STACK_SIZE=2048
CONFIG_BME68X_IAQ_SAMPLE_RATE_ULTRA_LOW_POWER=y
14 changes: 14 additions & 0 deletions boards/thingy91x_nrf9151_ns.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/ {
aliases {
sw1 = &button0;
};

};

&bme680 {
status = "okay";
};

&accel {
status = "okay";
};
13 changes: 0 additions & 13 deletions prj.conf
Original file line number Diff line number Diff line change
Expand Up @@ -54,24 +54,11 @@ CONFIG_NETWORK_INFO=y
# Longer response length needed for network info
CONFIG_GOLIOTH_RPC_MAX_RESPONSE_LEN=512
CONFIG_I2C=y

CONFIG_SENSOR=y
CONFIG_BH1749=y
CONFIG_BH1749_TRIGGER=y

CONFIG_BME680=y

CONFIG_ADXL362=y
CONFIG_ADXL362_TRIGGER_GLOBAL_THREAD=y
CONFIG_ADXL362_INTERRUPT_MODE=1
CONFIG_ADXL362_ABS_REF_MODE=1
CONFIG_ADXL362_ACCEL_RANGE_2G=y
CONFIG_ADXL362_ACCEL_ODR_12_5=y

CONFIG_PWM=y
CONFIG_PWM_LOG_LEVEL_DBG=n

# Disable unused libraries to save flash
CONFIG_ADXL372=n
CONFIG_FLASH_SHELL=n
CONFIG_SENSOR_SHELL=n
45 changes: 45 additions & 0 deletions socs/nrf9151_ns.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Copyright (c) 2024 Golioth, Inc.
# SPDX-License-Identifier: Apache-2.0

# General config
CONFIG_HEAP_MEM_POOL_SIZE=4096
CONFIG_NEWLIB_LIBC=y

# Networking
CONFIG_NET_SOCKETS_OFFLOAD=y
CONFIG_NET_IPV6=y
CONFIG_NET_IPV6_NBR_CACHE=n
CONFIG_NET_IPV6_MLD=n

# Increase native TLS socket implementation, so that it is chosen instead of
# offloaded nRF91 sockets
CONFIG_NET_SOCKETS_TLS_PRIORITY=35

# Modem library
CONFIG_NRF_MODEM_LIB=y

# LTE connectivity with network connection manager
CONFIG_NRF_MODEM_LIB_NET_IF=y
CONFIG_NRF_MODEM_LIB_NET_IF_AUTO_START=y
CONFIG_NRF_MODEM_LIB_NET_IF_AUTO_CONNECT=n
CONFIG_NET_CONNECTION_MANAGER=y
CONFIG_NET_CONNECTION_MANAGER_MONITOR_STACK_SIZE=1024

# Add Logs for LTE Link Handler
CONFIG_GOLIOTH_SAMPLE_NRF91_LTE_MONITOR=y

# Disable options y-selected by NCS for no good reason
CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED=n
CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED=n

# MbedTLS configuration to support p-384 curve. These options
# enable using the MbedTLS built-in support for operations not
# supported by the default nRF Oberon crypto backend
CONFIG_NORDIC_SECURITY_BACKEND=n
CONFIG_MBEDTLS_LEGACY_CRYPTO_C=y

# Add Network Info Support
CONFIG_MODEM_INFO=y

# Generate MCUboot compatible images
CONFIG_BOOTLOADER_MCUBOOT=y
45 changes: 45 additions & 0 deletions socs/nrf9160_ns.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Copyright (c) 2024 Golioth, Inc.
# SPDX-License-Identifier: Apache-2.0

# General config
CONFIG_HEAP_MEM_POOL_SIZE=4096
CONFIG_NEWLIB_LIBC=y

# Networking
CONFIG_NET_SOCKETS_OFFLOAD=y
CONFIG_NET_IPV6=y
CONFIG_NET_IPV6_NBR_CACHE=n
CONFIG_NET_IPV6_MLD=n

# Increase native TLS socket implementation, so that it is chosen instead of
# offloaded nRF91 sockets
CONFIG_NET_SOCKETS_TLS_PRIORITY=35

# Modem library
CONFIG_NRF_MODEM_LIB=y

# LTE connectivity with network connection manager
CONFIG_NRF_MODEM_LIB_NET_IF=y
CONFIG_NRF_MODEM_LIB_NET_IF_AUTO_START=y
CONFIG_NRF_MODEM_LIB_NET_IF_AUTO_CONNECT=n
CONFIG_NET_CONNECTION_MANAGER=y
CONFIG_NET_CONNECTION_MANAGER_MONITOR_STACK_SIZE=1024

# Add Logs for LTE Link Handler
CONFIG_GOLIOTH_SAMPLE_NRF91_LTE_MONITOR=y

# Disable options y-selected by NCS for no good reason
CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED=n
CONFIG_MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED=n

# MbedTLS configuration to support p-384 curve. These options
# enable using the MbedTLS built-in support for operations not
# supported by the default nRF Oberon crypto backend
CONFIG_NORDIC_SECURITY_BACKEND=n
CONFIG_MBEDTLS_LEGACY_CRYPTO_C=y

# Add Network Info Support
CONFIG_MODEM_INFO=y

# Generate MCUboot compatible images
CONFIG_BOOTLOADER_MCUBOOT=y
Loading
Loading