Swapping command values

Forum Home Forums Understanding the Software Swapping command values

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #16660
    oley
    Participant

    Hi,

    I have a device with controllable switches.
    I can open the switch by writing the data 0x0000 and close it with 0xFF00.
    I realized this in SCADA by creating commands like Coils(0X) and assigned created channels to a dynamic image.
    The standard way it works is that on click an On(green) and Off(red) window appears.
    Clicking on Off(red) opens the switch, and clicking on On(green) closes it.
    I need the exact opposite action: On(green) opens and Off(red) closes.
    Is the solution a negation in the channel using a formula?

    Best regards

    #16661
    manjey73
    Participant

    if you are using an enumeration, then add your own.
    ONN: green; OFF:red
    by analogy, or any other at your discretion

    #16669
    Mikhail
    Moderator

    Hi,
    In the output formula of the channel, put something like
    Cmd > 0 ? 0xFF : 0x00
    If it doesn’t work, make screenshots.

    #16670
    Mikhail
    Moderator

    In case of Modbus coils
    Cmd > 0 ? 0 : 1

    #16688
    oley
    Participant

    Hi,

    thank you. The custom enumeration works properly.

    Best regards

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.