UART RX idle logic 0

Hello,

We are working on a project that uses a UART->RS485 bridge, but the data coming from the bridge IC is idling low. In other words, the UART data we are receiving is "upside-down". At all times, the line is low until data starts to appear on the line, where the data raises the logic level to high repeatedly. This is a problem because the stock nRF52840 UART drivers expect UART to come in idling high. Is there any way we can flip the UART in software or do we have to add an inverter in hardware?

Thanks,

Nathan

Parents
  • Hi Nathan

    I will have to ask internally as I don't know of any way to do it. 

    I did come across a post made by a colleague regarding a workaround, however as the post is from some years back I have asked internally. 

    There is no way to invert the output in the UARTE or UART peripheral directly unfortunately, hidden or otherwise. 

    A method which isn't mentioned in the old case is to invert the signal by passing it through the GPIOTE peripheral, setting up one GPIOTE IN channel that automatically triggers a toggle on a separate GPIOTE OUT channel whenever there is activity on the TX pin. 

    This method should be less complicated from a software point of view, but will increase current draw somewhat, and will require an additional GPIO (one for the real TX signal, and one for the inverted one). 

    Best regards
    Torbjørn

    Regards

    Runar

Reply
  • Hi Nathan

    I will have to ask internally as I don't know of any way to do it. 

    I did come across a post made by a colleague regarding a workaround, however as the post is from some years back I have asked internally. 

    There is no way to invert the output in the UARTE or UART peripheral directly unfortunately, hidden or otherwise. 

    A method which isn't mentioned in the old case is to invert the signal by passing it through the GPIOTE peripheral, setting up one GPIOTE IN channel that automatically triggers a toggle on a separate GPIOTE OUT channel whenever there is activity on the TX pin. 

    This method should be less complicated from a software point of view, but will increase current draw somewhat, and will require an additional GPIO (one for the real TX signal, and one for the inverted one). 

    Best regards
    Torbjørn

    Regards

    Runar

Children
No Data
Related