Post Go back to editing

EVAL-CN0359-EB1Z polling over RS485 not working

Hello,

I am trying to automate data logging on a CN0359 eval board and I cannot get the poll command to work.

The command I have been trying to use "1 poll\n"

Some of the things I have tried:

  • I have tried multiple different USB to RS485 converters
    • One which has worked with other devices: USBG-COMi-M
    • These are capable of outputting at the baud rates I have tested
    • I have tried wiring them backwards, B->A  A->B, just for good measure
  • I have tried using Putty, TeraTerm, and Python
  • I have tried setting my board to different RS485 addresses and baud rates
  • I have tried sending 2 spaces before my command, like in the user guide. ex "  1 poll\n"
  • I have tried using other commands. ex "1 setvolt 2.5" and they do not update values on the board.
  • I have tried re-flashing the board with the newest firmware
  • I have tried sending commands from an arduino through a serial to RS485 converter shield, which I know works with other devices.

Throughout all of this I have never gotten any response.

All other functions of the board are working correctly.

Any ideas would be greatly appreciated.

Parents
  • Hi osullivan,

    I just have a few questions to verify.

    • When you set the board to different RS485 addresses, did you send the command still as "1 poll" or as "<address> poll"?
    • By "All other functions of the board are working correctly", are you referring to the other RS485 commands? You also mentioned that the other commands do not update the values on the board.
    • Can you send me a link to the USB to RS485 converter that you are using?

    Regards.

  • Hi ACatapang,

    • I was sending "<address> poll\n", and I was always matching the address I set on the board.
    • None of the RS485 commands are working, but all other functions of the board are working. It is reading the conductivity and temperature correctly and all of the menus on the board work as they should. Sorry for any confusion here.
    • Here is the converter I have been using:
    • Here is how I have the converter configured:
      • Pin 1   Data-  (A)  ->  3 A
      • Pin 2   Data+ (B)  ->  2 GND
      • Pin 6   GND         ->   1 B
      • Baud: 115200
        • Same as on the board, I have also tried 9600 on the board and on the serial connection.
      • Data bits: 8
      • Stop bits: 1
      • Parity: None
      • I have the dip switches set to [on, off, off, off] for RS-485 Half Duplex, and when I enable Echo [on, off, off, on] I get the same message I sent out back in.
      • This is how I am wiring it. I am using the terminal blocks, not the DB-9 connector on the converter:
      • This is how my serial connection to the USB to RS485 converter is set up. I could not find anything about the data bits, stop bits, or parity bits in the documentation or code so I have kept them as their defaults:
      • Pinout:
      • Dip Switch Settings:

     

    Regards.

  • Sorry for the awful formatting, I was copy-pasting to and from Word because my posts keep getting removed (I think because of the link), and now I cannot edit my comment without it being removed again...

    This part should read as follows:

    • Here is how I have the converter configured:
      • I have the dip switches set to [on, off, off, off] for RS-485 Half Duplex, and when I enable Echo [on, off, off, on] I get the same message I sent out back in. 
      • This is how I am wiring it. I am using the terminal blocks, not the DB-9 connector on the converter:
        • Pin 1   Data-  (A)  ->  3 A
        • Pin 2   Data+ (B)  ->  2 GND
        • Pin 6   GND         ->   1 B
      • This is how my serial connection to the USB to RS485 converter is set up. I could not find anything about the data bits, stop bits, or parity bits in the documentation or code so I have kept them as their defaults:
        • Baud: 115200
          • Same as on the board, I have also tried 9600 on the board and on the serial connection.
        •  Data bits: 8
        • Stop bits: 1
        • Parity: None
  • Hi osullivan,

    I don't see the figure you have for the converter but the wiring for the RS485 terminal block is half duplex and the A terminal of one device should be connected to the A terminal of the other and the same for the B terminal.

    I  also think setting the dip switches for echo just creates a loopback wiring within the converter which is why you get the same message back.

    Regards.

  • Hi ACatapang,

    That is how I have been wiring the device and the USB to rs485 converter together.

    I tested with two different boards, I have tested 3 in total now, and I still cannot get any of them to do anything over rs485. Is there anything else you would recommend I try?

    Regards.

  • FormerMember
    0 FormerMember
on Feb 24, 2021 5:16 PM in reply to osullivan

Is there any way you could send over a couple pictures of your setup?  Especially with how you are connecting to the CN0359 board? and how you are translating the RS485 to the PC.

Nikko any other recommendations from you?

  • Have you tried wiring the A of the USB to RS485 converter to the CN0359s A pin together, and their B pins together?

    From your previous wiring:

    • Pin 1   Data-  (A)  ->  3 A
    • Pin 2   Data+ (B)  ->  2 GND
    • Pin 6   GND         ->   1 B

    It should be:

    • Pin 1   Data-  (A)  ->  3 A
    • Pin 2   Data+ (B)  ->  1 B
    • Pin 6   GND         ->   2 GND
  • I have been connecting it that way. I wrote it down wrong.

    I am actually wiring it like this:

    • Pin 1   Data-  (A)  ->  3 A
    • Pin 2   Data+ (B)  ->  1 B
    • Pin 6   GND         ->   2 GND
  • I cannot seem to send images, so here is a more clear explanation:

    Terminal 3 (A) on the CN0359 is connected to Terminal 1(A)  of the converter.

    Terminal 2 (GND) on the CN0359 is connected to Terminal 6 (GND) of the converter.

    Terminal 1 (B) on the CN0359 is connected to Terminal 2 (B) of the converter.

    The USB B port on the converter is connected to my computer with a USB A to B cable.

    The converter is configured for RS-485 2-Wire (Half duplex) with its dip switches set to 1000.

    I have verified that the converter is working.

  • Hi osullivan,

    Do you have an oscilloscope you can use to probe the RO and DI signals of the ADM3075E (Pins 1 and 4 of U7)?

    The two reasons that I see are that the ADM3075E is not working or the software was not loaded correctly. If the RO pin signals are correct, this can be a software or microcontroller side issue.

  • Reply Children