serialcheck.c中的一段代码一直弄不明白:
do { status = stress_test_uart_once(opts, fd, data, data_len); memset(opts->cmp_buff, 0, data_len); printf("loops %u / %u%c[K ", loops + 1, opts->loops, 27); if (!status) printf("%cM", 27); } while (++loops < opts->loops && !status);
查ansi
https://godoc.org/github.com/pborman/ansi#pkg-constants
EL = Name(" 33[K") // Erase in Line
RI = Name(" 33M") // Reverse Line Feed