在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):cbrake/linux-serial-test开源软件地址(OpenSource Url):https://github.com/cbrake/linux-serial-test开源编程语言(OpenSource Language):C 97.8%开源软件介绍(OpenSource Introduction):linux-serial-testLinux Serial Test ApplicationCompilingThis is a very simple program -- there are several ways to compile it on Linux: directly using GCC
Using CMake
Usage
ExamplesStress test a connection
This will send full bandwidth data with a counting pattern on the TX signal. On any data received on RX, the program will look for a counting pattern and report any missing data in the pattern. This test can be done using a loopback cable. Test flow control
This enables RTS/CTS flow control and sends a counting pattern on the TX signal. Reads are delayed by 250ms between reads, which will cause the buffer to fill up and start using flow control. As before any missing data in the pattern is reported, and if flow control is working correctly there should be none. This test can be done using a loopback cable, or by running the program on both ends of the connection. For a two-port solution invoke the following command on the receiver side:
and on the transmitter side:
Stress test that can be used in a script
This transmits for five seconds and receives for seven seconds, after which it will exit. The exit code will be zero if the number of received bytes matched the number of transmitted bytes and the received pattern was correct, so this can be used as part of an automated test script. Output a pattern where you can easily verify baud rate with scope:
This outputs 10 bits that are easy to measure, and then multiply by 10 in your head to get baud rate. |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论