[En-Nut-Discussion] Problems with UART.c and _read()
Jason Walton
walton.jason at gmail.com
Thu Sep 14 16:27:16 CEST 2006
Harald,
I shorted pins 2 and 3 (Tx and Rx) together and Hyperterm operated as
expected (characters appeared as typed and "enter" brings the cursor to the
beginning of the same line). I don't think that it is a terminal issue. I
believe that the call to _read() or fgets() is the culprit. After
receiving the first character, if either is called again later, they return
immediately with the maximum amount of data allowed by the calling function;
even when no such data has been sent.
Thanks,
Jason
On 9/14/06, Harald Kipp <harald.kipp at egnite.de> wrote:
>
> Jason,
>
> At 11:29 13.09.2006 -0400, you wrote:
> >Harald/Discussion,
> >
> >Is there a particular "Hyperterninal" setup that is prefered. I'm
> >attempting the rs232d project now with similar results. The data pushed
> >from the telnet session displays perfectly on the Hyperterminal (UART
> >Output); but when a response character is sent back to the UART, the
> telnet
> >session fills up with random, non-ascii characters.
>
> If random characters appear, you probably did not set 115200,8,n,1.
>
> I'm not too familiar with Hyperterm, but this may help:
>
> - Disconnect the serial cable from Ethernut
> - Short pin 2 and 3 of the serial cable
> - Type characters into the Hypertem window
> - Press Enter
>
> All typed characters should be displayed once only.
> Pressing enter should place the cursor on the beginning
> of the same line (NOT the next line).
>
> Harald
>
> _______________________________________________
> En-Nut-Discussion mailing list
> En-Nut-Discussion at egnite.de
> http://www.egnite.de/mailman/listinfo.cgi/en-nut-discussion
>
More information about the En-Nut-Discussion
mailing list