Skip to content

Add CoAP protocol support to serial modem#179

Open
zavdimka wants to merge 1 commit intonrfconnect:mainfrom
zavdimka:main
Open

Add CoAP protocol support to serial modem#179
zavdimka wants to merge 1 commit intonrfconnect:mainfrom
zavdimka:main

Conversation

@zavdimka
Copy link

Description

This PR adds CoAP (Constrained Application Protocol) support to the ncs-serial-modem application, enabling IoT/M2M communication over the CoAP protocol.

Changes

  • New file: app/src/sm_at_coap.c - Full CoAP protocol implementation

    • Support for up to 3 simultaneous CoAP connections
    • CoAP socket management and message handling
    • TLS/DTLS credential support for secure communication
    • CoAP payload buffering (512 bytes max)
  • Updated: app/CMakeLists.txt

    • Added sm_at_coap.c to build system with CONFIG_COAP conditional compilation

Features

  • Multiple concurrent CoAP contexts
  • Secure communication via TLS/DTLS
  • Full CoAP message handling
  • Integration with existing AT command interface

How to Test

Enable CoAP support in your configuration with CONFIG_COAP=y

@zavdimka zavdimka force-pushed the main branch 3 times, most recently from 8e61a7b to 008ac0e Compare February 17, 2026 17:10
- Implement sm_at_coap.c with CoAP protocol handling
  - Support for multiple CoAP contexts (up to 3 simultaneous connections)
  - CoAP socket management and message handling
  - TLS/DTLS credential support
  - CoAP payload buffering (512 bytes)

- Update CMakeLists.txt to include CoAP source file
  - Add conditional compilation with CONFIG_COAP flag
  - Integrate sm_at_coap.c into the build system

- Add overlay-coap.conf

This enables CoAP protocol communication capabilities in the serial modem application.

Signed-off-by: Dmitrii Zavrazhnov <zavdimka@gmail.com>
@trantanen
Copy link
Collaborator

Thanks for the contribution. We do have CoAP AT command API in our backlog. It will likely appear in the public repository during April.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants