Set Value Modbus Slave

Forum Home Forums Communicating with Devices Modbus Set Value Modbus Slave

This topic contains 11 replies, has 2 voices, and was last updated by Mikhail Mikhail 6 months, 3 weeks ago.

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #5185
    Avatar
    ronnie.nilsson
    Participant

    Hi, I have a Vacon 100 as a Modbus TCP Slave. It works fine to read values but when I try to send a command to write to the same it don´t work… I have tried to send the value with SetVal(1640, 20) (1640 is the Tag ID) in communicator but no luck. Do you have any suggestions what I do wrong?

    #5188
    Mikhail
    Mikhail
    Moderator

    Hi,

    First of all, make sure that sending commands works well only in Communicator (open Commands tab). If it doesn’t work, see communication line log.

    SetVal() doesn’t send command. You should use output channels for this.

    #5190
    Avatar
    ronnie.nilsson
    Participant

    Thanks for the answer Mikhail. Commands tab works well and it say´s commands are sent. To be honest I don´t know what command should be written and it´s very difficult to find this in the documentation? I have written a decimal and hexcode but no luck. Could you give me an example of a command that writes a value to a modbus TCP Slave in the Communicator command tab?

    #5195
    Mikhail
    Mikhail
    Moderator

    It depends of your Modbus register map. You have to create commands in Modbus template. The default configuration contains example of Modbus commands.
    Can you share what you did?

    #5199
    Avatar
    ronnie.nilsson
    Participant

    I really appreciate your help, really got stuck on this issue…
    It´s difficult to share pictures here but on … I put up some screenshoots. I have tried a lot of adresses but the latest I try to write to is FBProcessDataIn 2001 = 42001 I have another program looking at the value in the modbus slave but there is nothing…

    • This reply was modified 6 months, 3 weeks ago by Mikhail Mikhail.
    #5213
    Mikhail
    Mikhail
    Moderator

    You should upload images to any other hosting and copy links to this topic.

    #5222
    Avatar
    ronnie.nilsson
    Participant

    IDMap
    IDMAP Desc
    Communicator
    Settings
    Modbus_Setting
    Command_Sent
    Log

    #5226
    Mikhail
    Mikhail
    Moderator

    Sorry, the images have too small resolution. It’s impossible to read anything. Please don’t resize images when upload.

    #5231
    Avatar
    ronnie.nilsson
    Participant

    IDMap
    IDmap1
    Modbus
    Com1
    Com2
    Command
    Com

    #5233
    Mikhail
    Mikhail
    Moderator

    Set Commands enabled checkbox in Communication line parameters.
    You can find a message that describes it in communication line log.

    #5238
    Avatar
    ronnie.nilsson
    Participant

    Thank´s Mikhail!!! Now it´s working!!! : )

    #5243
    Mikhail
    Mikhail
    Moderator

    Nice )

Viewing 12 posts - 1 through 12 (of 12 total)

You must be logged in to reply to this topic.