Unexpected results testing serial loopback using echo and cat

view full story

http://unix.stackexchange.com – So I have a standard RS232 serial port that is looped back to itself by simply running a wire from Tx to Rx. I'm testing loopback by running echo and cat in two separate terminals: cat /dev/ttyS1 echo "hi" > /dev/ttyS1 My issue is with the output. I would expect to see one "hi" come back on the terminal running cat but instead I get this: hi [1 newline] hi [3 newlines] hi [7 newlines] hi [15 newlines] hi [31 newlines] hi ...and so on until I ctrl+C cat. After interrupting cat, if I run it again I will not output "hi"s until I run echo a second time. Is this normal? Any idea why I (HowTos)