This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

nrf_serial vs. app_uart

I'm migrating to the new 13.0.0 SDK and I'm wondering what are the benefits of using nrf_serial over app_uart (if any) and what steps I would need to take to switch over if I choose to.

  • Hi,

    The advantages of the Serial port library over UART library is described in the documentation:

    This module allows to create and handle serial port instances. It is designed as a more sophisticated replacement for the app_uart module. The following are the advantages of this module over app_uart:

    • API is more generic and robust: you can read or write any amount of bytes.
    • Multi-instance capability.
    • The module can work in three modes: POLLING, IRQ, and DMA.
    • Calls can be asynchronous and synchronus (with timeouts).
    • Independent RX/TX FIFOs with configurable sizes.
    • Configurable RX/TX transfer buffers (smallest transfer slice).
    • Event handler (not mandatory).
    • Sleep handler (not mandatory).

    You can find an example of how to use the Serial library in the SDK.

    Best regards,

    Jørgen

Related