Anybus 7808 Profibus (Master) Modbus RTU (Slave)

Hello,

I am trying to test the module Profibus (Master) Modbus RTU (Slave). However, i have a problem with the Holding Registers.

I am using the program Modscan32 as a master to read and write data of a Siemens module in the profibus network. I can read correctly the information from the module, however when i try to write to the module, the holding register contains the same information than the input registers and it gives me an error if i try to force a bit or word.

Questions:

  • Is this something that i may have configured or wired incorrectly in the Anybus module?
  • Could it be something wrong with the Modscan32 SW i am using for testing? Do you recommend? another program for this?

Note: I have been using the Modscan32 for the testing of a different anybus module (Profibus Master Modbus TCP/IP Slave and it works perfectly.

Thanks

Marcelo Vega

Hello Marcelo,

I will review this issue to determine where the point of failure is.

Hi Kevin,

Thanks for taking this issue. How is it going? Any luck?

Marcelo

Hello,

I haven’t been able to replicate this issue. I apologize for the delay, the Modscan 32 should work fine.
We usually use simply modbus.

What function code are you using? Are you writing to the Output buffer?

Hello,

I used “simply modbus” with the same result. In modscan i used the code “03:Holding register” (40001-40030) to try to send commands through the Anybus module. I noticed that the “simply modbus” used a different code, but the result was the same. Both programs display the information of the input registers on the holding registers.

Marcelo Vega

Hi Kevin,

Tried again with both programs and the same issue. I try to change some configurations but the error still the same.
Is it possible that we can have a conference so i can show you my screen with the programs? This way you will be able to see it. I took some screenshots of the test. maybe you see what is the error.

Hello @Marcelo what modbus addressing mode are you using? If you are using modbus addressing mode you will read input registers and write to holding registers. If you disable modbus mode and use Anybus addressing mode you can use holding registers for all the data but will need to use a registers offset. take a look at the modbus register mapping in the Network guide.

Hi Deryck,
The addressing I was using is 30000 (30001-30030) for the input registers and 40000 (40001-40030) for the holding registers. I don’t have the option (or i don’t see it in the manual) you mentioned, however i found a table in the manual about the addressing and it worked. To read, i can use the range 30001-30030 for the input registers, but to write I must use the range 41025-41054 for the holding registers instead of 40001-40030. Thanks for pointing out addressing.

Thanks again

Glad to hear this helped. It looks like you are using Anybus addressing mode. The option is found in ACM.

Deryck

Hi Deryck,

I dont have that option in my ACM. I see you have Modbus TCP/IP though this one is RTU. Not sure if I can do what you are proposing.

Please let me know

Ah, my apologies for some reason i was thinking this was a modbus TCP device. The modbus RTU device does not have this option. You were looking at the correct manual and mapping.

Deryck

No problem.

Please, I have another question. I tested this unit with a RS232/RS485 at 9.6kbps, and it works well, however, if i try with 38.4kbps it doesn’t work. I connected directly to the ANYBUS module ( I changed the dip switch from RS485 to RS232 and the port baud rate settings of my laptop) and it also didn’t work. I am missing something? any ideas?

Hello,

Can verify it’s RX to TX for the serial connection?

Also, what is the baud rate settings on the dipswitch?

the dip switch for the 38.4kbit/s was as indicated in the manual

image

And the connection i have is this one

Hi Kevin

I tried the 4800bps and 9600 and both works fine on RS485, but not on RS232.
I also tried 19200bps and 38400 and none of these worked, neither on RS485, nor RS232.

Thanks

Marcelo

Hi Kevin,

Should i return the modules?

Thanks

Hello Marcelo,

I apologize for the delay, but i have not been able to replicate this issue, and I awaiting a response for an escalation.

If you are using a serial port sniffer on the PLC side, does it show communication to the unit?

Hi Kevin,

I am using “Modscan32” and “simply modbus master” to check the communication. I tried the 4800bps and 9600 and both works fine on RS485 and i can monitor the values with the mosdcan, but not on RS232. Once i increase the baud rate the communication doesn’t work anymore. there is no response to the polls sent.

I also tested an RS232 to RS485 converter with two laptops at 38.4kbps, separated from the Anybus and i an have communication between them.

Note: every time the baud rate is changed in the module i also change it on the program “Modscan32” and on the properties of the serial port in my computer. And i reboot everything (20sec off): Module, laptop, converter.

So the question are:

  • Why is not communicating at higher speed than 9200bps on RS-485?
  • Why is not working on RS-232?
  • There is a minimum cable lenght (I know about the maximum length)? (Currently i am using a 3ft wire PN:3222 for the RS-485)

Thanks

Marcelo

Hello Marcelo,

I just had a quick conversation with our team regarding this issue.

For the communication, are you getting a exception code in the communication? Or is this a blank communication?
Is Baud rate, pairity, and stop bits?
Are you using two seperate converters? Or are you using a single converter for both?
For RS485, are you termination resistor on the line?

Also can you try to switch the Rx Tx on one end of the line for?

The settings on the serial port of my laptop and the settings in the Modscan32 are these:

bps: 38400
data bits: 8
Parity: None
Stop bits: 1

In addition to this Serial port properties has:
Flow control: None

I tried swapping the RX and TX as well at the beginning . Once again, the communication works at 9.6kbps and lower baudrate.

I am using one converter RS485 to RS232 to communicate with my laptop. Once again, the Anybus module has dip switch to work on RS232 to connect directly to the laptop, however it doesn’t work.

Yes the terminations resistors are present on the Anybus module and on the converter RS485 to RS232.

The configuration i have is this:

  • Using RS485
    Simotion controller (Profibus) <==> Anybus (Profibus) <==> Anybus (Modbus RS485) <==> converter RS485 to RS232.<==> Laptop

  • Using RS232
    Simotion controller (Profibus) <==> Anybus (Profibus) <==> Anybus (Modbus RS232) <==> Laptop