Skip to content

Conversation

@andysan
Copy link
Contributor

@andysan andysan commented May 6, 2020

The SX126x and the SX1276 share a significant amount of code. Refactor the current code to facilitate reuse.

Note: The CW API change is expected to go in together with the shell before this PR. The commit is included here as a "glue" commit.

@andysan andysan requested a review from Mani-Sadhasivam May 6, 2020 18:04
@zephyrbot zephyrbot added the area: API Changes to public APIs label May 6, 2020
@andysan andysan force-pushed the sx1276-refactor branch from 11afd94 to d2696d4 Compare May 7, 2020 13:18
Copy link
Member

@Mani-Sadhasivam Mani-Sadhasivam left a comment

Choose a reason for hiding this comment

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

LGTM

@andysan andysan force-pushed the sx1276-refactor branch from d2696d4 to 67ca7e9 Compare May 18, 2020 20:42
Copy link
Contributor

@chrta chrta left a comment

Choose a reason for hiding this comment

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

LGTM. I have not tested this, but i think this is a good improvement.

@ioannisg
Copy link
Member

ioannisg commented Jun 9, 2020

Needs rebase and switching to C99 types @andysan

andysan added 2 commits June 10, 2020 08:33
The implementation of the board support routines is shared between all
LoRa drivers that use LoRaMAC-Node. Move them from the SX1276
implementation to a separate source file to facilitate reuse. Make
this source file conditional on CONFIG_HAS_SEMTECH_RADIO_DRIVERS since
it will be used by all LoRaMAC-Node-based drivers.

Signed-off-by: Andreas Sandberg <andreas@sandberg.pp.se>
LoRa radios supported by LoRaMAC-Node have a lot of common
functionality. Zephyr's LoRa implementation for the SX1276 uses
LoRaMAC-Nodes Radio HAL to implement API functionality like send and
recv. The exact same functionality will be used by the SX126x
driver. Facilitate sharing by moving that to a separate source file.

Signed-off-by: Andreas Sandberg <andreas@sandberg.pp.se>
@andysan
Copy link
Contributor Author

andysan commented Jun 10, 2020

Needs rebase and switching to C99 types @andysan

Done.

@nashif nashif merged commit a36147c into zephyrproject-rtos:master Jun 11, 2020
@andysan andysan deleted the sx1276-refactor branch June 11, 2020 18:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: API Changes to public APIs area: LoRa

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants