01 Overview
Read a byte, write it back. Proves pins, baud and wiring.
- Use when: second UART bring-up, meter link.
- Skip when: the protocol is already stable (add Modbus on top).
Sensors and I/O
Starting point for meters, PLCs and modules. RS485 is only a level shift.
Official path: examples/peripherals/uart/uart_echo
Read a byte, write it back. Proves pins, baud and wiring.
1. Port, baud, buffers.
2. Read loop, echo write.
3. Products parse frames instead of echoing forever.
中文
传感器与外设
接电表、PLC、模组的起点。RS485 只是电平转换。
官方路径: examples/peripherals/uart/uart_echo
从 UART 读什么写回什么。证明口线、波特率、接线。
1. 配端口、波特率、缓冲。
2. 读循环,echo 写出。
3. 产品改为帧解析,而不是永久 echo。