Application to test a communication bus by writing a sequence of bytes and verifying the integrity when receiving it back. The loopback can be performed in some different ways like:
- short-circuiting the RX-TX in case of a serial bus;
- software loop back, performed by the linux driver
- external device does the loopback by returning the data it receives.
To build the project in a Linux distribution, follow the bellow steps.
$ mkdir build && cd build
$ cmake ..
$ make
To run the application
$ ./comm_test <device> <baud_rate> <sw_loopback_en>
For instance
$ ./comm_test /dev/ttyUSB0 9600 1