-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[nrfconnect] Support nRF52840 Dongle in all-clusters-app (#17215)
* [nrfconnect] Support nRF52840 Dongle in all-clusters-app The dongle doesn't have external flash, so only build configurations without the DFU are supported. Also, due to flash size limitations (nR52840 dongle reserves some flash for an immutable bootloader), shell commands must have been disabled, too. By the way, make fixes in lighting-app which in theory already had the support for the nRF52840 Dongle, but it didn't work due to various issues. Signed-off-by: Damian Krolik <[email protected]> * Add new targets to build_examples.py * Fix build * Revert accidentally committed change
- Loading branch information
1 parent
25cfd8d
commit 1123440
Showing
16 changed files
with
260 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
examples/all-clusters-app/nrfconnect/boards/nrf52840dongle_nrf52840.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# | ||
# Copyright (c) 2022 Project CHIP Authors | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# | ||
|
||
# Configure logging over USB | ||
# - do enable shell to reduce flash usage | ||
# - disable CDC ACM logs as it may lead to infinite loop when CDC ACM is used as the log backend | ||
CONFIG_USB_DEVICE_STACK=y | ||
CONFIG_CONSOLE=y | ||
CONFIG_UART_CONSOLE=y | ||
CONFIG_LOG_BACKEND_UART=y | ||
CONFIG_SHELL_LOG_BACKEND=n | ||
CONFIG_UART_LINE_CTRL=y | ||
CONFIG_USB_CDC_ACM_LOG_LEVEL_OFF=y | ||
|
||
# The minimal logging mode does not work properly with the USB CDC device, so use the deferred mode | ||
CONFIG_LOG_MODE_MINIMAL=n | ||
CONFIG_LOG2_MODE_DEFERRED=y | ||
CONFIG_LOG_BUFFER_SIZE=8192 | ||
|
||
# Reduce the code size as the dongle reserves some space for MBR and Open Bootloader | ||
CONFIG_ASSERT_VERBOSE=n | ||
CONFIG_SHELL=n | ||
CONFIG_OPENTHREAD_SHELL=n | ||
CONFIG_MATTER_LOG_LEVEL_INF=y | ||
|
||
# Use partition manager to configure the settings partition not to overlap with Open Bootloader | ||
CONFIG_PM_SINGLE_IMAGE=y | ||
|
||
# Enable CHIP pairing automatically on application start. | ||
CONFIG_CHIP_ENABLE_PAIRING_AUTOSTART=y |
28 changes: 28 additions & 0 deletions
28
examples/all-clusters-app/nrfconnect/boards/nrf52840dongle_nrf52840.overlay
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/* | ||
* Copyright (c) 2021 Project CHIP Authors | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http: //www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
/ { | ||
chosen { | ||
zephyr,console = &cdc_acm_uart0; | ||
}; | ||
}; | ||
|
||
&zephyr_udc0 { | ||
cdc_acm_uart0: cdc_acm_uart0 { | ||
compatible = "zephyr,cdc-acm-uart"; | ||
label = "CDC_ACM_0"; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
examples/all-clusters-app/nrfconnect/pm_static_nrf52840dongle_nrf52840.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
settings_storage: | ||
address: 0xd8000 | ||
size: 0x8000 | ||
region: flash_primary | ||
open_bootloader: | ||
address: 0xe0000 | ||
size: 0x20000 | ||
region: flash_primary |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
examples/lighting-app/nrfconnect/pm_static_nrf52840dongle_nrf52840_no_dfu.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
settings_storage: | ||
address: 0xd8000 | ||
size: 0x8000 | ||
region: flash_primary | ||
open_bootloader: | ||
address: 0xe0000 | ||
size: 0x20000 | ||
region: flash_primary |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.