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

samples: matter: Added system off configuration for smoke CO alarm #19244

Closed

Conversation

kkasperczyk-no
Copy link
Contributor

Added configuration that allows to enable system off for the smoke CO alarm.

@kkasperczyk-no kkasperczyk-no requested review from a team as code owners December 4, 2024 10:45
@github-actions github-actions bot added the doc-required PR must not be merged without tech writer approval. label Dec 4, 2024
@NordicBuilder
Copy link
Contributor

NordicBuilder commented Dec 4, 2024

CI Information

To view the history of this post, clich the 'edited' button above
Build number: 4

Inputs:

Sources:

sdk-nrf: PR head: 3f9e7a6b5194ca81bc4de2f13419cdb53e41db66

more details

sdk-nrf:

PR head: 3f9e7a6b5194ca81bc4de2f13419cdb53e41db66
merge base: eaa215e9051d05c5c399739f51a7124affbcd546
target head (main): 90ac4ed82133568e784a93dcbc85a82a48354e49
Diff

Github labels

Enabled Name Description
ci-disabled Disable the ci execution
ci-all-test Run all of ci, no test spec filtering will be done
ci-force-downstream Force execution of downstream even if twister fails
ci-run-twister Force run twister
ci-run-zephyr-twister Force run zephyr twister
List of changed files detected by CI (7)
doc
│  ├── nrf
│  │  ├── releases_and_maturity
│  │  │  ├── releases
│  │  │  │  │ release-notes-changelog.rst
samples
│  ├── matter
│  │  ├── light_switch
│  │  │  ├── snippets
│  │  │  │  ├── lit_icd
│  │  │  │  │  │ lit_icd.conf
│  │  ├── smoke_co_alarm
│  │  │  ├── Kconfig
│  │  │  ├── README.rst
│  │  │  ├── overlay-system_off.conf
│  │  │  ├── src
│  │  │  │  ├── app_task.cpp
│  │  │  │  │ app_task.h

Outputs:

Toolchain

Version: b77d8c1312
Build docker image: docker-dtr.nordicsemi.no/sw-production/ncs-build:b77d8c1312_912848a074

Test Spec & Results: ✅ Success; ❌ Failure; 🟠 Queued; 🟡 Progress; ◻️ Skipped; ⚠️ Quarantine

  • ◻️ Toolchain - Skipped: existing toolchain is used
  • ✅ Build twister
    • sdk-nrf test count: 123
  • ❌ Integration tests
    • ❌ test-fw-nrfconnect-chip
Disabled integration tests
    • desktop52_verification
    • doc-internal
    • test_ble_nrf_config
    • test-fw-nrfconnect-apps
    • test-fw-nrfconnect-ble_mesh
    • test-fw-nrfconnect-ble_samples
    • test-fw-nrfconnect-boot
    • test-fw-nrfconnect-fem
    • test-fw-nrfconnect-nfc
    • test-fw-nrfconnect-nrf-iot_libmodem-nrf
    • test-fw-nrfconnect-nrf-iot_lwm2m
    • test-fw-nrfconnect-nrf-iot_mosh
    • test-fw-nrfconnect-nrf-iot_nrf_provisioning
    • test-fw-nrfconnect-nrf-iot_positioning
    • test-fw-nrfconnect-nrf-iot_samples
    • test-fw-nrfconnect-nrf-iot_serial_lte_modem
    • test-fw-nrfconnect-nrf-iot_thingy91
    • test-fw-nrfconnect-nrf-iot_zephyr_lwm2m
    • test-fw-nrfconnect-nrf_crypto
    • test-fw-nrfconnect-ps
    • test-fw-nrfconnect-rpc
    • test-fw-nrfconnect-rs
    • test-fw-nrfconnect-tfm
    • test-fw-nrfconnect-thread
    • test-fw-nrfconnect-zigbee
    • test-low-level
    • test-sdk-audio
    • test-sdk-dfu
    • test-sdk-find-my
    • test-sdk-mcuboot
    • test-sdk-pmic-samples
    • test-sdk-sidewalk
    • test-sdk-wifi
    • test-secdom-samples-public

Note: This message is automatically posted and updated by the CI

@NordicBuilder
Copy link
Contributor

You can find the documentation preview for this PR at this link. It will be updated about 10 minutes after the documentation build succeeds.

Note: This comment is automatically posted by the Documentation Publish GitHub Action.

config SYSTEM_OFF
bool "Enable system off on idle"
depends on POWEROFF
depends on SOC_NRF54L15_CPUAPP
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we want to support this on L05 or L10?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For L05, definitely not, but maybe for L10. I will change it to SOC_SERIES_NRF54LX

@@ -5,6 +5,16 @@
#
mainmenu "Matter nRF Connect Smoke CO Alarm Example Application"

config SYSTEM_OFF
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would prefer this to have a prefix e.g. APPLICATION_SYSTEM_OFF because without a prefix, it just seems like this could easily conflict with something in zephyr in future

@kkasperczyk-no kkasperczyk-no removed the DNM label Dec 4, 2024
@kkasperczyk-no kkasperczyk-no added this to the 2.9.0 milestone Dec 4, 2024
Added configuration that allows to enable system off for the
smoke CO alarm.

Signed-off-by: Kamil Kasperczyk <[email protected]>
System off configuration
------------------------

The sample supports optional system off configuration, that turns off the whole system once an ICD device enters the idle state.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The sample supports optional system off configuration, that turns off the whole system once an ICD device enters the idle state.
The sample supports optional system off configuration that turns off the whole system once an ICD device enters the idle state.

------------------------

The sample supports optional system off configuration, that turns off the whole system once an ICD device enters the idle state.
Turning off the system, instead of putting it to sleep allows the device to achieve much lower power consumption in the idle state.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Turning off the system, instead of putting it to sleep allows the device to achieve much lower power consumption in the idle state.
Turning off the system instead of putting it to sleep allows the device to achieve much lower power consumption in the idle state.


The sample supports optional system off configuration, that turns off the whole system once an ICD device enters the idle state.
Turning off the system, instead of putting it to sleep allows the device to achieve much lower power consumption in the idle state.
On the other hand, the device wakes up from a sleep state much faster than from the system off, and it sends only Thread data poll frame and Matter data report.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
On the other hand, the device wakes up from a sleep state much faster than from the system off, and it sends only Thread data poll frame and Matter data report.
On the other hand, the device wakes up from the sleep state much faster than from the system off, and it sends only a Thread data poll frame and Matter data report.

The sample supports optional system off configuration, that turns off the whole system once an ICD device enters the idle state.
Turning off the system, instead of putting it to sleep allows the device to achieve much lower power consumption in the idle state.
On the other hand, the device wakes up from a sleep state much faster than from the system off, and it sends only Thread data poll frame and Matter data report.
In case of waking up from the system off, the device has to boot the whole system, initialize platform, re-attach to network and send data report every time, what consumes a lot of energy.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
In case of waking up from the system off, the device has to boot the whole system, initialize platform, re-attach to network and send data report every time, what consumes a lot of energy.
In case of waking up from the system off, the device has to boot the whole system, initialize platform, re-attach to network, and send data report every time, which consumes a lot of energy.

On the other hand, the device wakes up from a sleep state much faster than from the system off, and it sends only Thread data poll frame and Matter data report.
In case of waking up from the system off, the device has to boot the whole system, initialize platform, re-attach to network and send data report every time, what consumes a lot of energy.

The usage of system off configuration can be beneficial from the perspective of overall power consumption for the scenarios, when the device has relatively big sleep interval and the system boot happens rarely.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The usage of system off configuration can be beneficial from the perspective of overall power consumption for the scenarios, when the device has relatively big sleep interval and the system boot happens rarely.
Using the system off configuration can be beneficial from the perspective of overall power consumption for scenarios, where the device has relatively long sleep interval and the system boot happens rarely.

In case of waking up from the system off, the device has to boot the whole system, initialize platform, re-attach to network and send data report every time, what consumes a lot of energy.

The usage of system off configuration can be beneficial from the perspective of overall power consumption for the scenarios, when the device has relatively big sleep interval and the system boot happens rarely.
It was proven by measurements that an ICD device achieves better power consumption with the system off enabled for sleep intervals bigger than 15 minutes.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
It was proven by measurements that an ICD device achieves better power consumption with the system off enabled for sleep intervals bigger than 15 minutes.
It was proven by measurements that an ICD device achieves lower power consumption with the system off enabled for sleep intervals longer than 15 minutes.

The usage of system off configuration can be beneficial from the perspective of overall power consumption for the scenarios, when the device has relatively big sleep interval and the system boot happens rarely.
It was proven by measurements that an ICD device achieves better power consumption with the system off enabled for sleep intervals bigger than 15 minutes.

Additionally, the system off solution disables RAM retention, what results in losing the data that could be potentially stored there, like for example diagnostic logs.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Additionally, the system off solution disables RAM retention, what results in losing the data that could be potentially stored there, like for example diagnostic logs.
The system off solution disables RAM retention, which results in losing data that could be potentially stored in RAM, like for example diagnostic logs.


Additionally, the system off solution disables RAM retention, what results in losing the data that could be potentially stored there, like for example diagnostic logs.

This feature is disabled by default, and it is available only for the ``nrf54l15dk/nrf54l15/cpuapp`` target.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
This feature is disabled by default, and it is available only for the ``nrf54l15dk/nrf54l15/cpuapp`` target.
This feature is disabled by default, and it is available only for the ``nrf54l15dk/nrf54l15/cpuapp`` board target.

@@ -396,6 +396,7 @@ Matter samples
* :ref:`matter_smoke_co_alarm_sample` sample:

* Added support for ICD dynamic SIT LIT switching (DSLS).
* Added support for system off configuration for the :ref:`zephyr:nrf54l15dk_nrf54l15` target.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add the changelog entry as a comment to my #19240 and remove it from this PR.


This feature is disabled by default, and it is available only for the ``nrf54l15dk/nrf54l15/cpuapp`` target.
To enable it, set the :kconfig:option:`CONFIG_SAMPLE_MATTER_SYSTEM_OFF` Kconfig option to ``y``.
You can test the sample configuration that enables system off and configures the device to wake-up every 30 minutes, by applying a dedicated overlay file.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
You can test the sample configuration that enables system off and configures the device to wake-up every 30 minutes, by applying a dedicated overlay file.
You can test the sample configuration that enables system off and configures the device to wake-up every 30 minutes by applying a dedicated overlay file.

@kkasperczyk-no kkasperczyk-no removed this from the 2.9.0 milestone Dec 4, 2024
@kkasperczyk-no
Copy link
Contributor Author

There are too many issues with this change and it needs more work to be solid, so I'm closing the PR for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc-required PR must not be merged without tech writer approval.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants