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

net: lib: coap: Service support #64265

Merged
merged 14 commits into from Nov 9, 2023

Conversation

pdgendt
Copy link
Collaborator

@pdgendt pdgendt commented Oct 23, 2023

This PR introduces CoAP services (similar to HTTP services) and a CoAP server implementation.

Note: the CoAP Server sample was copied as everything remains backwards compatible. If this isn't desired it can be removed in favor of CoAP services.

samples/net/sockets/coap_service/src/main.c Outdated Show resolved Hide resolved
samples/net/sockets/coap_service/src/test.c Outdated Show resolved Hide resolved
include/zephyr/net/coap_service.h Show resolved Hide resolved
@pdgendt pdgendt force-pushed the coap-service branch 4 times, most recently from 53a4089 to a99c48c Compare October 24, 2023 09:11
subsys/net/lib/coap/coap_server.c Outdated Show resolved Hide resolved
include/zephyr/net/coap_service.h Outdated Show resolved Hide resolved
samples/net/sockets/coap_service/README.rst Outdated Show resolved Hide resolved
@pdgendt pdgendt force-pushed the coap-service branch 5 times, most recently from 02e9ce9 to 04757c7 Compare October 24, 2023 11:59
rlubos
rlubos previously approved these changes Oct 25, 2023
kartben
kartben previously approved these changes Nov 8, 2023
Fixed a typo to include DOXYGEN generated documentation.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Add length variant for the well known core resource and parsing.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Add URI path matching function to public CoAP API.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Add function to check if CoAP packet is a request to the public API.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Add a CoAP helper function to find a matching observer by token.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Change coap_remove_observer to return the result of removing the
observer if found.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
This commit adds the option to register an event handler to CoAP
resources when observers are added/removed.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Add CoAP services and server as a subsystem implementation.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Add shell commands that allow to start/stop CoAP services.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Add a test for CoAP macro usage.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Replaced the CoAP server example with CoAP services.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Created a dedicated page for CoAP service and resource examples.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
The CoAP documentation has server/clients sample usages, added a
note about the available subsystems that can be used instead.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
Add a note to the 3.6 migration guide about the CoAP API changes
introduced with the CoAP server subsystem.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
@jukkar jukkar removed the DNM This PR should not be merged (Do Not Merge) label Nov 9, 2023
@carlescufi carlescufi merged commit 98052aa into zephyrproject-rtos:main Nov 9, 2023
20 of 21 checks passed
@pdgendt pdgendt deleted the coap-service branch November 9, 2023 11:23
Desvauxm-st added a commit to Desvauxm-st/zephyr that referenced this pull request Nov 29, 2023
due to this PR:
net: lib: coap: Service support zephyrproject-rtos#64265
we exclude :
nucleo_f207zg, nucleo_f429zi, nucleo_f746zg, nucleo_h743zi
stm32h573i_dk ,stm32h735g_disco, nucleo_f207zg



Signed-off-by: Marc Desvaux <marc.desvaux-ext@st.com>
Desvauxm-st added a commit to Desvauxm-st/zephyr that referenced this pull request Nov 29, 2023
due to this PR:
net: lib: coap: Service support zephyrproject-rtos#64265
we exclude :
nucleo_f207zg, nucleo_f429zi, nucleo_f746zg, nucleo_h743zi
stm32h573i_dk ,stm32h735g_disco, nucleo_f207zg



Signed-off-by: Marc Desvaux <marc.desvaux-ext@st.com>
Desvauxm-st added a commit to Desvauxm-st/zephyr that referenced this pull request Nov 29, 2023
due to this PR:
net: lib: coap: Service support zephyrproject-rtos#64265
we exclude :
nucleo_f207zg, nucleo_f429zi, nucleo_f746zg, nucleo_h743zi
stm32h573i_dk ,stm32h735g_disco, nucleo_f207zg



Signed-off-by: Marc Desvaux <marc.desvaux-ext@st.com>
Desvauxm-st added a commit to Desvauxm-st/zephyr that referenced this pull request Nov 29, 2023
due to this PR:
net: lib: coap: Service support zephyrproject-rtos#64265
we add harness: coap



Signed-off-by: Marc Desvaux <marc.desvaux-ext@st.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Networking area: Samples Samples area: Sockets Networking sockets Release Notes To be mentioned in the release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants