Skip to content

DISCO_L072CZ_LRWAN1: enable LORA by default #14049

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

Merged
merged 3 commits into from
Jan 14, 2021

Conversation

jeromecoutant
Copy link
Collaborator

Summary of changes

DISCO_L072CZ_LRWAN1 target includes a SX1276 transceiver,
so LoRaWan could be enabled in default configuration

During this development, I changed the way of configuring pins for each Lora radio driver.
Before, it was up to application to configure all the pins for each radio,
now pins are configured in the driver, and application just has to override to needed ones.

Greentea test is also updated

Impact of changes

Migration actions required

Documentation


Pull request type

[x] Patch update (Bug fix / Target update / Docs update / Test update / Refactor)
[] Feature update (New feature / Functionality change / New API)
[] Major update (Breaking change E.g. Return code change / API behaviour change)

Test results

target platform_name test suite test case passed failed result elapsed_time (sec)
DISCO_L072CZ_LRWAN1-GCC_ARM DISCO_L072CZ_LRWAN1 connectivity-lorawan-tests-tests-lorawan-loraradio Test check_rf_frequency 1 0 OK 0.05
DISCO_L072CZ_LRWAN1-GCC_ARM DISCO_L072CZ_LRWAN1 connectivity-lorawan-tests-tests-lorawan-loraradio Test perform_carrier_sense 1 0 OK 0.06
DISCO_L072CZ_LRWAN1-GCC_ARM DISCO_L072CZ_LRWAN1 connectivity-lorawan-tests-tests-lorawan-loraradio Test random 1 0 OK 0.1
DISCO_L072CZ_LRWAN1-GCC_ARM DISCO_L072CZ_LRWAN1 connectivity-lorawan-tests-tests-lorawan-loraradio Test set_rx_config 1 0 OK 0.08
DISCO_L072CZ_LRWAN1-GCC_ARM DISCO_L072CZ_LRWAN1 connectivity-lorawan-tests-tests-lorawan-loraradio Test set_tx_config 1 0 OK 0.09
DISCO_L072CZ_LRWAN1-GCC_ARM DISCO_L072CZ_LRWAN1 connectivity-lorawan-tests-tests-lorawan-loraradio Test time_on_air 1 0 OK 0.05
[] No Tests required for this change (E.g docs only update)
[x] Covered by existing mbed-os tests (Greentea or Unittest)
[] Tests / results supplied as part of this PR

Reviewers


@jeromecoutant
Copy link
Collaborator Author

FYI @ludoch-stm

@mergify mergify bot added the needs: work label Dec 15, 2020
@ciarmcom ciarmcom added the release-type: patch Indentifies a PR as containing just a patch label Dec 15, 2020
@ciarmcom ciarmcom requested review from a team December 15, 2020 14:30
@ciarmcom
Copy link
Member

@jeromecoutant, thank you for your changes.
@ARMmbed/mbed-os-connectivity @ARMmbed/mbed-os-maintainers please review.

Copy link
Member

@pan- pan- left a comment

Choose a reason for hiding this comment

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

Thanks @jeromecoutant. It is a peculiar way of overriding the lora.radio parameter. Is there any side effect when the user attempt to override this value and one of the driver provides a value for MBED_CONF_LORA_RADIO ?

@@ -1,6 +1,10 @@
{
"name": "SX126X-lora-driver",
"config": {
"radio": {
Copy link
Member

Choose a reason for hiding this comment

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

If I understand this correctly this provides the override of "lora.radio"

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

yes, I don't find any clean way to override some config value defined in another lib....

Copy link
Member

Choose a reason for hiding this comment

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

That's a longstanding issue 😞 .

@@ -5,6 +5,9 @@
"help": "LoRa PHY region: EU868, AS923, AU915, CN470, CN779, EU433, IN865, KR920, US915",
"value": "EU868"
},
"radio": {
"help": "value set in radio driver : SX126X, SX1272, SX1276"
Copy link
Member

Choose a reason for hiding this comment

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

What happen if a value is provided in mbed_app.json ?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It will not be used as define will be MBED_CONF_APP_xxx

@jeromecoutant
Copy link
Collaborator Author

Could we start CI ?

@hugueskamba hugueskamba requested a review from pan- December 31, 2020 12:18
@@ -24,6 +28,17 @@
"standby-mode": {
"help": "Default: STDBY_RC = 0, STDBY_XOSC = 1",
"value": 0
}
},
"spi-mosi": { "value": "NC" },
Copy link
Contributor

Choose a reason for hiding this comment

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

should this follow the style: value on separate line with NC ? same as the rest above to be consistent (I understand it's not much value but consistency is better.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Done

@adbridge
Copy link
Contributor

adbridge commented Jan 7, 2021

@0xc0170 could you re-review please,I'll start CI in the meantime

@mbed-ci
Copy link

mbed-ci commented Jan 7, 2021

Jenkins CI Test : ✔️ SUCCESS

Build Number: 1 | 🔒 Jenkins CI Job | 🌐 Logs & Artifacts

CLICK for Detailed Summary

jobs Status
jenkins-ci/mbed-os-ci_unittests ✔️
jenkins-ci/mbed-os-ci_cmake-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-test ✔️
jenkins-ci/mbed-os-ci_greentea-test ✔️

"dio5": {
"value": "NC"
},
"rf-switch-ctl1": { "value": "NC" },
Copy link
Contributor

Choose a reason for hiding this comment

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

same style for the rest also (line here and lines below)

"dio5": {
"value": "NC"
},
"rf-switch-ctl1": { "value": "NC" },
Copy link
Contributor

Choose a reason for hiding this comment

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

also update here needed

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 12, 2021

@jeromecoutant please update the rest of the changes, LGTM once updated

@jeromecoutant
Copy link
Collaborator Author

@jeromecoutant please update the rest of the changes, LGTM once updated

Done

Copy link
Contributor

@0xc0170 0xc0170 left a comment

Choose a reason for hiding this comment

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

@pan- happy with the changes?

@mergify mergify bot added needs: CI and removed needs: review labels Jan 12, 2021
@mbed-ci
Copy link

mbed-ci commented Jan 12, 2021

Jenkins CI Test : ✔️ SUCCESS

Build Number: 2 | 🔒 Jenkins CI Job | 🌐 Logs & Artifacts

CLICK for Detailed Summary

jobs Status
jenkins-ci/mbed-os-ci_unittests ✔️
jenkins-ci/mbed-os-ci_cmake-example-ARM ✔️
jenkins-ci/mbed-os-ci_cmake-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-ARM ✔️
jenkins-ci/mbed-os-ci_build-greentea-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-ARM ✔️
jenkins-ci/mbed-os-ci_build-cloud-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_build-example-GCC_ARM ✔️
jenkins-ci/mbed-os-ci_greentea-test ✔️
jenkins-ci/mbed-os-ci_cmake-example-test ✔️

@mergify mergify bot removed the needs: CI label Jan 12, 2021
@0xc0170 0xc0170 merged commit 82f3126 into ARMmbed:master Jan 14, 2021
@mergify mergify bot removed the ready for merge label Jan 14, 2021
@jeromecoutant jeromecoutant deleted the PR_L072_LORA branch January 15, 2021 08:37
@mbedmain mbedmain added release-version: 6.7.0 Release-pending and removed release-type: patch Indentifies a PR as containing just a patch Release-pending labels Jan 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants