https://github.com/amid68/uart_command_center
https://github.com/amid68/uart_command_center
embedded embedded-c embedded-systems led-controller rtos uart zephyr zephyr-rtos
Last synced: over 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/amid68/uart_command_center
- Owner: Amid68
- Created: 2024-12-19T14:39:50.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2025-01-23T18:47:02.000Z (over 1 year ago)
- Last Synced: 2025-02-14T15:47:28.333Z (over 1 year ago)
- Topics: embedded, embedded-c, embedded-systems, led-controller, rtos, uart, zephyr, zephyr-rtos
- Language: C
- Homepage:
- Size: 58.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
Awesome Lists containing this project
README
.. zephyr:code-sample:: uart
:name: UART echo
:relevant-api: uart_interface
Read data from the console and echo it back.
Overview
********
This sample demonstrates how to use the UART serial driver with a simple
echo bot. It reads data from the console and echoes the characters back after
an end of line (return key) is received.
The polling API is used for sending data and the interrupt-driven API
for receiving, so that in theory the thread could do something else
while waiting for incoming data.
By default, the UART peripheral that is normally used for the Zephyr shell
is used, so that almost every board should be supported.
Building and Running
********************
Build and flash the sample as follows, changing ``nrf52840dk/nrf52840`` for
your board:
.. zephyr-app-commands::
:zephyr-app: samples/drivers/uart/echo_bot
:board: nrf52840dk/nrf52840
:goals: build flash
:compact:
Sample Output
=============
.. code-block:: console
Hello! I\'m your echo bot.
Tell me something and press enter:
# Type e.g. "Hi there!" and hit enter!
Echo: Hi there!