[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAOMZO5CywajwZEL8K2ATfS80WzqY69YVX+3S7hq9_HmNdNAwaw@mail.gmail.com>
Date: Fri, 6 Jan 2017 22:31:16 -0200
From: Fabio Estevam <festevam@...il.com>
To: Clemens Gruber <clemens.gruber@...ruber.com>
Cc: "linux-serial@...r.kernel.org" <linux-serial@...r.kernel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Sascha Hauer <s.hauer@...gutronix.de>,
Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>, Nandor Han <nandor.han@...com>,
Lucas Stach <l.stach@...gutronix.de>,
Fabio Estevam <fabio.estevam@...escale.com>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: imx: RS-485 problems during TX, maybe DMA related
Hi Clemens,
On Fri, Jan 6, 2017 at 8:50 PM, Clemens Gruber
<clemens.gruber@...ruber.com> wrote:
> But according to the i.MX Pins tool, they can be muxed vice-versa too.
> So if you connected the transceiver-enable to ball L4 (CSI0_DAT16), you
> could mux MX6QDL_PAD_CSI0_DAT16__UART4_CTS_B and
> MX6QDL_PAD_CSI0_DAT17__UART4_RTS_B instead?
Yes, I have tried like this:
&uart4 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_uart4>;
uart-has-rtscts;
status = "okay";
};
pinctrl_uart4: uart4grp {
fsl,pins = <
MX6QDL_PAD_CSI0_DAT12__UART4_TX_DATA 0x1b0b1
MX6QDL_PAD_KEY_ROW0__UART4_RX_DATA 0x1b0b1
MX6QDL_PAD_CSI0_DAT16__UART4_CTS_B 0x1b0b1
>;
};
In this case the DE pin of the rs485 transceiver is always at 0 then
RX works and TX does not.
Then I tried to use a gpio for controling the rts line:
&uart4 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_uart4>;
rts-gpios = <&gpio6 2 GPIO_ACTIVE_HIGH>;
status = "okay";
};
pinctrl_uart4: uart4grp {
fsl,pins = <
MX6QDL_PAD_CSI0_DAT12__UART4_TX_DATA 0x1b0b1
MX6QDL_PAD_KEY_ROW0__UART4_RX_DATA 0x1b0b1
MX6QDL_PAD_CSI0_DAT16__GPIO6_IO02 0x1b0b1
>;
}
In this case the DE pin of the rs485 transceiver is always at 1, then
TX works and RX does not.
So I was never able to observe the DE pin toggling correctly.
Maybe you could share your userspace application with me offline?
Thanks
Powered by blists - more mailing lists