Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can't seem to send \r on serial port

Status
Not open for further replies.

RoyceyBaby

IS-IT--Management
Mar 23, 2001
22
0
0
Hi,

As per subject, I can send a \n fine using the code below:

write(fd, "\n", 1);

when I try and send:

write(fd, "\r", 1);

the CR character is not received on the other end.

I am using linux for writing my C program, and I have a WindowsXP machine running TeraTerm connected via a null modem cable to capture the output.

I am using UltraEdit to examing the Hex codes received.

Can anybody help me,

Thanks,

Royce
 
Fixed it!, I was sending a 00hex after the \r which was confusing things.

FYI TeraTerm did not log this, I used HyperTerminal's logging facility to determine this.

Royce
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top