Skip to content

app: PIPE interface to UART#6

Merged
MarkusLassila merged 1 commit into
nrfconnect:mainfrom
MarkusLassila:pipe-interface-to-uart
Oct 1, 2025
Merged

app: PIPE interface to UART#6
MarkusLassila merged 1 commit into
nrfconnect:mainfrom
MarkusLassila:pipe-interface-to-uart

Conversation

@MarkusLassila
Copy link
Copy Markdown
Contributor

@MarkusLassila MarkusLassila commented Sep 24, 2025

Jira: SLM-134

Implement PIPE interface to Serial Modem UART to be able to use the same UART implementation for both pure AT-commands and for CMUXed AT-commands and PPP.

Copilot AI review requested due to automatic review settings September 24, 2025 11:02
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR implements a PIPE interface to the Serial Modem UART to enable unified UART implementation for both pure AT-commands and CMUXed AT-commands with PPP. The changes streamline the UART backend architecture by consolidating functionality and removing the SLM-specific backend dependency.

  • Replaces backend-specific UART implementations with a unified pipe interface
  • Refactors AT command processing to support CMUX switching with proper state management
  • Standardizes error message formatting across initialization functions

Reviewed Changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
doc/app/sm_description.rst Updates documentation for PPP configuration files
app/src/sm_uart_handler.h Adds pipe interface declarations and transmit callback typedef
app/src/sm_uart_handler.c Implements unified UART pipe interface with CMUX support
app/src/sm_ppp.c Switches from SLM-specific to generic UART backend
app/src/sm_defines.h Adds CMUX command return code constant
app/src/sm_cmux.h Adds uninit function declaration
app/src/sm_cmux.c Refactors CMUX to use new pipe interface and removes SLM dependency
app/src/sm_at_host.h Updates AT receive function signature
app/src/sm_at_host.c Removes backend abstraction and integrates direct UART calls
app/src/sm_at_commands.c Standardizes error message formatting
app/overlay-ppp.conf Removes SLM backend configuration
app/overlay-ppp-without-cmux.conf Adds generic UART backend configuration
app/overlay-ppp-cmux-linux.conf Updates buffer sizing and removes SLM configuration
app/overlay-cmux.conf Removes SLM backend and buffer configuration

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread app/src/sm_uart_handler.h Outdated
Comment thread app/src/sm_uart_handler.c Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Copilot reviewed 14 out of 14 changed files in this pull request and generated 4 comments.


Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread app/src/sm_uart_handler.h Outdated
Comment thread app/src/sm_uart_handler.c
Comment thread app/src/sm_uart_handler.c
Comment thread app/src/sm_uart_handler.c
@MarkusLassila MarkusLassila force-pushed the pipe-interface-to-uart branch 3 times, most recently from d729f8a to a564d42 Compare September 24, 2025 12:15
Copy link
Copy Markdown
Collaborator

@trantanen trantanen left a comment

Choose a reason for hiding this comment

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

Add Jira: SLM-xx into PR description.

Comment thread app/src/sm_uart_handler.h Outdated
Comment thread app/src/sm_uart_handler.h
Comment thread app/src/sm_at_host.c Outdated
Comment thread app/src/sm_uart_handler.c
@trantanen
Copy link
Copy Markdown
Collaborator

@moksanen, @jvaliharju
When this goes in hopefully at some point next week, a new Kconfig overlay has to be taken into use for AT+PPP without CMUX config: EXTRA_CONF_FILE="overlay-ppp-without-cmux.conf"

@MarkusLassila MarkusLassila force-pushed the pipe-interface-to-uart branch 4 times, most recently from 5c31b71 to a8ddf7c Compare October 1, 2025 08:11
Jira: SLM-134

Implement PIPE interface to Serial Modem UART to be able to use
the same UART implementation for both pure AT-commands and for
CMUXed AT-commands and PPP.

Signed-off-by: Markus Lassila <markus.lassila@nordicsemi.no>
@MarkusLassila MarkusLassila force-pushed the pipe-interface-to-uart branch from a8ddf7c to c262cab Compare October 1, 2025 08:24
@MarkusLassila MarkusLassila merged commit 0e3c69b into nrfconnect:main Oct 1, 2025
1 check passed
trantanen referenced this pull request in trantanen/ncs-serial-modem Oct 22, 2025
PPP connection has been opened automatically when AT+CFUN=1 is done and
PDN has been activated even without PPP request using AT#XPPP=1.
This is now changed so you need to issue AT#XPPP=1
in order to start PPP. This can be done before or after AT+CFUN=1.

Enabled CONFIG_MODEM_BACKEND_UART_ASYNC_HWFC forgotten in PR #6.

Jira: SLM-85

Signed-off-by: Tommi Rantanen <tommi.rantanen@nordicsemi.no>
trantanen added a commit that referenced this pull request Oct 23, 2025
PPP connection has been opened automatically when AT+CFUN=1 is done and
PDN has been activated even without PPP request using AT#XPPP=1.
This is now changed so you need to issue AT#XPPP=1
in order to start PPP. This can be done before or after AT+CFUN=1.

Enabled CONFIG_MODEM_BACKEND_UART_ASYNC_HWFC forgotten in PR #6.

Jira: SLM-85

Signed-off-by: Tommi Rantanen <tommi.rantanen@nordicsemi.no>
@MarkusLassila MarkusLassila deleted the pipe-interface-to-uart branch November 18, 2025 09:30
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.

4 participants