How to setup rs485 with linux,rs485-enabled-at-boot-time?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-04-04 3:21 AM
This is how I would like to use rs485:
&usart3{
pinctrl-names = "default", "sleep";
pinctrl-0 = <&usart3_pins_mx>;
pinctrl-1 = <&usart3_sleep_pins_mx>;
status = "okay";
uart-has-rtscts;
linux,rs485-enabled-at-boot-time;
rs485-rts-delay-ns = <800 300>;
};
But it does not work.
The setup function stm32_usart_config_rs485() in drivers/tty/serial/stm32-usart.c does not get executed. This seems wrong. Could you elaborate on this?
When configuring rs485 from userland by using the ioctl, the setup function stm32_usart_config_rs485() does get executed and rs485 does work.
- Labels:
-
STM32MP15 Lines
-
UART-USART
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-05-06 2:21 AM
*ping*?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-05-31 1:31 AM
Hi @HLee.21​ ,
Sorry for late reply.
This issue has been escalated internally as ticket #BZ129026 and is currently under analyze.
Keep you posted
Olivier
In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-06-07 12:57 AM
Hi @HLee.21​ ,
I did some tests with the RS485 and it works for me.
The drivers uses stm32_usart_config_reg_rs485() and needs to be initialized before being used with the command "stty -F /dev/ttySTM1 2000000 -echo -icanon -onlcr" on the STM32 board and on the host by modifying the PATH.
I hope it can help you.
Do not hesitate to come back to me if necessary.
Grégory
