Vai al contenuto

Bridge between 2 Modbus RTU devices over ethernet LAN

Home Forum Convertitori di interfaccia Bridge between 2 Modbus RTU devices over ethernet LAN

Stai visualizzando 6 post - dal 1 a 6 (di 6 totali)
  • Autore
    Post
  • #35921
    Joze
    Partecipante

    Hello. Can we use the “ATC-1000 Ethernet to Serial Converter” in the following configuration:

    Slimline PLC programmed with LogicLab as a Modbus Slave, we would use Modbus RTU on RS485.
    ↑↓
    ATC-1000 Ethernet to Serial Converter
    ↑↓
    Poweline adapter 1 for LAN ethernet over electrical installation
    ↑↓
    Poweline adapter 2 for LAN ethernet over electrical installation
    ↑↓
    ATC-1000 Ethernet to Serial Converter
    ↑↓
    Eaton PLC with Codesys used as a Modbus Master, again, Modbus RTU on RS485.

    So basically we would like to create a bridge between 2 Modbus RTU devices over ethernet LAN. Would this work ?

    #39305
    Sergio Bertana
    Amministratore del forum

    Yes, two ATC-1000 converters can be configured to work paired, one, must be set as a TCP server, the other must be set as a TCP client. In the TCP client, the IP address of the server must be defined. The two Powerline adapters work as an ethernet cable, so the RTU serial packets received by one ATC converter are sent out from the other ATC conveter and viceversa.

    But a suggestion, it could be better to use an ethernet version of SlimLine PLC, so in this way you can connect it directly to the Powerline and using the TCPServer FB it can directly receive the data from the ATC-1000 configured as a client. Or by using the TCPClient FB it can send the data directly to the ATC-1000 configured as a server.

    #39306
    Joze
    Partecipante

    Thank you for your answer and for suggesting the interesting solution with the “TCPServer” library. Do we specifically need the SlimeLine MPS053 or we can use MPS046 as well ?

    The MPS053 is very limited with storage, it has only half the FlashEPROM user program storage (48kBytes vs. 96kBytes), how big projects can this run ?

    We are also considering getting the Codesys SlimLine version since we are more experienced using Codesys, does it also support TCPServer/TCPClient Function blocks ?

    #39307
    Sergio Bertana
    Amministratore del forum

    The two SlimLine models MPS046 (Starting from version B) and MPS053 are both capable to run the TCPServer and TCPClient FBs. About the program memory dimension on the MPS053, it’s true it normally has half space of the MPS046 but now it’s possible to extend the memory to the same dimension of the MPS046. You must buy a DID code (The ordering code and price will be added shortly to our site).

    The CODESYS version of the SlimLine has raffly the same functionality of the LogicLab version, also for it you can find the TCPServer and TCPClient FBs. If you use two CPU modules both equipped with ethernet connection, you can exchange data between them by using Modbus TCP directly on ethernet without any serial converter.

    On this topic you will find a modbus RTU implementation, but it can be easily modified to use modbus TCP. On this topic a program that allow to access to the SlimLine by PHP script. The Modbus TCP client is native in the SlimLine LogicLab.

    #39313
    Joze
    Partecipante

    Oh, you are right, our HMI panel has Ethernet as well so a Modbus TCP/IP solution is definetely a option, thank you for your suggestion! 

    I looked a bit into the thing and I think that most portable solution will be using OSCAT ModbusTCP function blocks. Eaton has some function blocks for Modbus TCP, but I’m not sure if it can be used on SlimLine PLC. Maybe you can try using it on the SlimLine ?

    I also had a quick look into your solution (PHPToModbus.pro program), doesn’t look that hard to implement, but that then are basicaly ModbusRTU packets sent via TCP and not proper ModbusTCP ? As far as I know there are some differences between those two types.
    #39314
    Sergio Bertana
    Amministratore del forum

    The OSCAT library is a source of informations, often i take a look on it,  but I prefer to write the FBs by myself, about the Modbus you can use our FBs (In this topic you can find them).

    About the PHPToModbus program (It can be reached here), and about the PHP class it uses the Modbus TCP protocol…

    Don’t make confusion between RTU and TCP. The Modbus TCP frame starts with 6 bytes of additional data (Transaction Identifier, Protocol Identifier, Length) and after it’s exactly the same frame that Modbus RTU without the final 2 bytes of CRC (Please refer to this manual).

Stai visualizzando 6 post - dal 1 a 6 (di 6 totali)
  • Devi essere connesso per rispondere a questo topic.