Facility Control

 View Only
  • 1.  fireGPI - Rosstalk or internal command?

    Posted 10-23-2017 11:08
    Hi.
    Just to clarify things.

    Is ogscript.fireGPI (Trigger, State, Global) a Rosstalk command which can be used for communication over a network, or is it only for communicating internally between panels on the same PC?
    So if it is possible to use ogscript.fireGPI on a network how would you set the port/IP, or is it intended to use rosstalk.sendMessage(IP, PORT, 'COMMAND:STATE') instead?

    Do we have to set up a listener on a second panel to receive Rosstalk messages, or should incoming Rosstalk messages automatically be detected if listen port is activated on receiving panel and we have setup triggers (trigger-string) on elements (labels).

    Best Regards



  • 2.  RE: fireGPI - Rosstalk or internal command?

    Posted 10-23-2017 13:37
    Hi erlandsv,

    I've only used ogscript.fireGPI for communication within DashBoard itself. (between panels, within a panel).

    You can easily send GPI messages between computers to trigger events using the Rosstalk GPI message.
    rosstalk.sendMessage () as you said.

    To receive GPI messages on a second computer is fairly easy, GPI messages in particular don't require you to build a listener by hand.
    To do this do the following:
    (also, this is how you could configure DashBoard to receive GPI messages from Ross Carbonite Swithers or Ross XPression Graphics)

    1: Enable GPIs in your DashBoard.
    Go to: Window\Preferences\Ross Talk GPI Listener.
    Enable the 'Global GPI Listener' item. (you can change the port if it makes sense to, but, usually you would keep the default value).

    2: Add 'GPI Triggers' to items in your panel.
    Typically you would put GPI triggers on a button in your panel. This means that whenever DashBoard receives a GPI trigger any Button that has the same trigger value will run it's scripts.

    To do this, on a button, in edit mode, on the 'Button Attributes' tab, put a value in 'Trigger ID' this is the GPI value to look for.
    Typically this is a number.

    Let me know if you need further help.

    Troy
    #DashBoard


  • 3.  RE: fireGPI - Rosstalk or internal command?

    Posted 10-23-2017 21:37
    Ok, thanks Troy. I have tried setting this up over our internal network. Maybe it has something to do with the way I have done it below. I would like to fetch a concenated string in addition to the GPI trigger name like this:

    Provider panel:
    var content = "some concenated string";
    rosstalk.sendMessage('192.168.100.40', 7788, 'TriggerName:'+content);


    Receiver/consumer panel:
    A label has a GPI trigger named 'TriggerName' and with this test ogscript:
    var content = "";
    if ((event != null) && (event.getState() != null))
    {
    content = event.getState();
    }
    ogscript.debug(content);

    I get no response at all, and I've tried different ports using Rosstalk.
    If I try the same on localhost with ogscript.fireGPI('TriggerName', content, true) from provider panel it works as expected on the consumer panel.
    I thought I could add a state in addition to the GPI trigger in the Rosstalk message, but maybe I got wrong syntax with the ":" separator or my 'TriggerName:'+content syntax?
    Or do you think there are some firewall issues on ports on our network?
    BR, erland

    #DashBoard


  • 4.  RE: fireGPI - Rosstalk or internal command?

    Posted 10-23-2017 22:00
    Aah, my bad!
    From Dashboard User Guide:
    rosstalk.sendMessage('localhost', 7788, 'GPI StartClock')

    So if anyone else has problems with GPI Trigger Id strings, just prefix the Trigger Id with "[I]GPI[/I] ... and then your Trigger ID".
    It works now Troy!
    E:)

    #DashBoard


  • 5.  RE: fireGPI - Rosstalk or internal command?

    Posted 10-24-2017 13:56
    Glad you got it working!

    T.
    #DashBoard