This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

RS-485 Bus-Polarity Correction Question

Other Parts Discussed in Thread: SN65HVD888, SN65HVD1794, SN65HVD1791, SN65C3232E

For the SN65HVD888, what would the result be if you had 50% of your nodes with the incorrect polarity and 50% of your nodes with the correct polarity?

 

For the SN65HVD1794, what would the result be if you had 50% of your nodes with the incorrect polarity and 50% of your nodes with the correct polarity?

  • Hi Rob,

    With the SN65HVD888, the nodes that are cross-wired will correct themselves after 76ms of the bus being idle. One node on the bus is set up as the 'master' and will have failsafe resistors on A and B (pull-up on A, pull-down on B). This means that when the bus is idle, the master will create a positive Va-b and all the other nodes can check whether the bus voltage is positive or negative. If they are seeing a negative voltage (B > A), they will automatically flip all of the incoming bits and outgoing bits so the microcontroller won't even know anything is wrong. This is the key feature of the SN65HVD888.

    The SN65HVD1794 doesn't have this feature, so the 50% of nodes that are cross-wired will be sending and receiving inverted data. Actually, the ones that are cross-wired will be able to understand each others messages, but not from the 'correct' transceivers. In order to account for this scenario, there would need to be a code at the microcontroller level which would be able to detect if it is receiving inverted bits and handle it with software. Under this paradigm, it might be hard to set which node is the 'correct' polarity, and each node might think it is inverted if any incoming packet is inverted. This could probably also be solved in software.

    I hope this helps answer your questions! Let me know if you have any more.

    Jason Blackman

  • I saw your video :  Engineer It - How to isolate a power supply for RS485 & CAN

    Swaroop Vaidyanath  was very nervous.   jeje

    I need  help, mm how calculate the value of resistor for (DE) in the  sn65hvd1791 device.

    http://www.ti.com/lit/ds/symlink/sn65hvd1791.pdf

    RE= GND ok enable
    DE =  VCC                  4mA Typical

    I have 5 volts in the power supply
    ___________

    resistor
    R=v/i
    ______________
    R= 5volt/0.004 ?
    R=  1250 Ohm??
    _______________

    1250  ohms for enable the driver output?
    I'm right?
    I'm wrong?
    I hope you can help me, I am a super super newbie. LOL
    ___________
    Aplication: RS232-RS485  non isolate converter

  • Hello,

    Are you trying to find the resistor value to use as a pull-up on DE in order to have a certain amount of current? If so, then you are performing it correctly. For enable pull-ups and pull-downs, we usually use 4.7kOhm as a good default value. 1250 Ohm may be stronger than is needed.

    Let me know if you have any other questions!

    Thanks,
    Jason Blackman 

  • Hi jason,

    Thank you for your prompt response Just wondering how to enable DE, will use 4.7k resistor to enable DE. I will use 4.7Kohms resistor to enable it. Is correct then use this value with 5Volts, right? ______________________________________________

    I'll use it to make a converter RS232-> RS485, and help a college friend.

    Another question, I will use the device SN65C3232EPWRG4, I was wondering if I can add an LED that blinking when a data transmit (TX) if possible in that position would put the LED (direct direct polarization) and as calculated resistance.

    something like http://www.usconverters.com/index.php?main_page=product_info&cPath=67&products_id=290

    hehehe.

     jason you could, recommend me some manual RS232/485 to pursue the subject of the communication protocols?

    http://www.ti.com/lit/ds/symlink/sn65c3232e.pdf

    ____________________________

    Google traslate

  • Hello,

    You might be interested in this document showing an example RS-232 to RS-485 converter. 

    3566.RS232 to RS485 Converter.pdf

    Thanks,
    Jason 

  • I like the topic of electronics much, I'm not an engineer but will study university the next year, this example I had seen earlier in another topic, I think the converter is isolated (but not why this converter is isolated .. by so I would like to know about a book that explains the topic of communication protocols ('' Handbook Communication protocols  for Beginners'' or something like that =) ......)

    jason

    Thank you very much for your prompt reply. It was kind of you to reply 
    =)

    GTrslte

  • Hello,

    Here is an application note about different communication protocols. You may find it useful.

    http://www.ti.com/lit/an/snla138a/snla138a.pdf

    Thanks,
    Jason Blackman 

  • =) Thank you jason, you are the man