Welcome to our new forum
All users of the legacy CODESYS Forums, please create a new account at account.codesys.com. But make sure to use the same E-Mail address as in the old Forum. Then your posts will be matched. Close

Offset Modbusverbindung

GEEH
2019-03-08
2019-03-12
  • GEEH - 2019-03-08

    Hallo,

    ich habe eine CODESYS anwendung , in der ich bei einer Modbusverbindung den "Write Offset" programmatisch ändern möchte z.B über eine WebVisu.
    Hat einer eine Idee, wie das funktionieren könnte?

    Gruß Georg

    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Hello,

    I have a CODESYS application in which I want to programmatically change the "Write Offset" in a Modbus connection, for example via a WebVisu.
    Does anyone have an idea how this could work?

    Greeting Georg

    IMG: Modbusverbindung_Offset.JPG

     
  • GEEH - 2019-03-11

    how should that work with the CAA SerialCom lib?
    How can I change the offset of the Modbus connection?

     
  • dFx

    dFx - 2019-03-12

    Serialcom lib allows you to code every read/write and port open/close.
    The scanner is simpler and easier because it does this automatically. But it's less flexible.

     
  • Anonymous - 2019-03-12

    Originally created by: ph0010421

    When you have brought in the ModbusMaster, the IoDrvModbus library is automatically used.
    In here is an FB ModbusRequest which lets you choose the slave, function code and offset/size of data.
    I'm never too sure of the best way to get the hComPort parameter...maybe you'll find it

     

Log in to post a comment.