linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chris <mailingliste.chris@gmail.com>
To: linux-serial@vger.kernel.org
Subject: mxs-auart stop bit-RTS delay
Date: Sun, 27 Apr 2014 11:28:37 +0200	[thread overview]
Message-ID: <535CCDC5.8000805@gmail.com> (raw)

I want to use the AUART0 of the i.MX28 with the handshake signals. For 
this I am using the latest stable Linux Kernel 3.14.1.

The AUART0 part of the device tree:

	auart0: serial@8006a000 {
    	pinctrl-names = "default";
    	pinctrl-0 = <&auart0_pins_a>; //four pins RX,TX,CTS,RTS
    	fsl,uart-has-rtscts;
    	status = "okay";
     };

So the device tree uses all four pins of this UART. In Linux itself I 
configure the interface with:

stty -F /dev/ttyAPP0 raw 9600 -echo -echoe -echok -echoctl -echoke crtscts

The UART and the handshake signals are working in principle. But I've 
noticed a delay between the RTS signal and the stopbit as you can see in 
the attached figure. If I have understood the RTS/CTS system correctly 
the RTS signal should be toggled immediately after the stopbit is sent. 
So that 13 ms (from the logic analyzer image) are really unnecessary and 
I can not trace it back where they are from. With other baudrates it is 
no less and no more than the 13 ms (~2...18ms-spread inside of the same 
baudrate)

I tried this too:

stty -F /dev/ttyAPP0 raw 9600 -echo -echoe -echok -echoctl -echoke -crtscts

The bits CTSEN and RTSEN of the UARTAPP_CTRL2 register are toggled, but 
there is still a something similar on the RTS lines, but now it is no 
CTS needed.

So my questions are, where are this delays come from?

How can I be sure who is toggling the RTS line (Linux or the i.MX28 
hardware module) ?

image logic analyzer:
https://community.freescale.com/servlet/JiveServlet/download/398158-274040/auart0_rts.png

                 reply	other threads:[~2014-04-27  9:28 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=535CCDC5.8000805@gmail.com \
    --to=mailingliste.chris@gmail.com \
    --cc=linux-serial@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).