Skip to main content
Egrets
Associate
August 5, 2020
Solved

Hi, I want to use RS232 and RS485 in my project, How can i choose the STM controller which support that,since the datasheet doesn't specify anything about it.

  • August 5, 2020
  • 4 replies
  • 7073 views

..

    This topic has been closed for replies.
    Best answer by KnarfB

    Most (all?) STM32 controllers have USART peripherals on-chip which can transmit+receive RS232 + RS485 signals at the 3.3V logic level including optional flow-control. But the original RS232 + RS485 specs also include the electrical level using special voltage ranges. To implement that, you need to attach external RS232 resp. RS 485 transceivers chips. Sometimes people say RS232 but only mean serial port / UART interface. So you must check what you want to connect on the other side of the serial interfaces.

    4 replies

    KnarfB
    KnarfBBest answer
    Super User
    August 5, 2020

    Most (all?) STM32 controllers have USART peripherals on-chip which can transmit+receive RS232 + RS485 signals at the 3.3V logic level including optional flow-control. But the original RS232 + RS485 specs also include the electrical level using special voltage ranges. To implement that, you need to attach external RS232 resp. RS 485 transceivers chips. Sometimes people say RS232 but only mean serial port / UART interface. So you must check what you want to connect on the other side of the serial interfaces.

    Egrets
    EgretsAuthor
    Associate
    August 5, 2020

    Hi KnarfB,

    Thank you for your fast response.

    So I can connect the the external transceiver chips for RS-485? I need to conform that STM support the RS-485 Communication with full duplex.

    Can you suggest any STM controller for that purpose?

    KnarfB
    Super User
    August 5, 2020

    Please use the STM32CubeMX tool or the online STM32 product selector. There are so many variables to consider (MCU performance, low-power, package). For prototyping you can use any cheap Nulceo board like NUCLEO-L432KC.

    Egrets
    EgretsAuthor
    Associate
    August 5, 2020

    Hi KnarfB,

    Thank you for your response.

    Piranha
    Principal III
    August 5, 2020

    For MCU the RS-485 is basically UART with RX, TX and (for half-duplex) RTS/DE pins enabled. All or almost all STM32 MCUs can do that.

    Egrets
    EgretsAuthor
    Associate
    August 5, 2020

    Hi Piranha,

    Thank you for your response. Is 10Mb/s speed needed for RS-485?

    Piranha
    Principal III
    August 5, 2020

    How do I know what speed do you need? So you are making RS-485, but you are to lazy to read even the basic info about it?

    https://en.wikipedia.org/wiki/RS-485

    Associate
    May 7, 2024

    Hi, I am trying to connect one energy meter sensor which has RS485 output, But i am unable to read RS485 sensor readings in Nucleo F401RE, If you have any examples please help out!!