Facility Control

 View Only
Expand all | Collapse all

Sending Chyron II commands via Dashboard TCP SendMessage

  • 1.  Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-18-2018 22:19
    I've been playing around with Dashboard 8.4.1 and I'm trying just for fun to send II commands over Telnet to my Chyron. I've been using ogScript commands like Send TCP Message as String with the proper host, port, commands etc. but it doesn't appear to be going through and nothing shows up in the Chyron II status boxes.

    I know it works from the machine, because I can do it without a problem from the Telnet command window. Any tips on this? Thank you.


  • 2.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 13:51
    Hi Rob.
    You are correct, rosstalk.sendMessage(host, port, message) should be fairly similar to sending a command via Telnet. Can you send an example of the ogScript code you are executing?

    One minor thing to look at: Often times when a device is 'controllable via Telnet' it is actually just accepting ASCII over a raw TCP connection. That's true most of the time, but it isn't guaranteed. Instead of using a Telnet application, you could try using an application like Putty and set the connection type to "Raw" to do the actual equivalent of what DashBoard is sending when you use rosstalk.sendMessage and verify that your commands work that way.

    James
    #DashBoard


  • 3.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 18:47
    This is what's in the ogScript:

    rosstalk.SendMessage("xx.xx.xx.xx", 32, "W\50005\50000\ \LINE ONE\LINE TWO\\", null)

    It's sending it as a TCP string.

    I xed out the IP address, but it corresponds to the Lyric telnet host, and the string is the IIUpdate command. Les at NAB suggested I use \r\n instead of CRLF, but it doesn't seem to work. That same command does work using the traditional Telnet through a command prompt. From what I can tell, it's not even making it out of Dashboard.
    #DashBoard


  • 4.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 19:26
    Hi Rob.
    There are several issues here. The first is that the backslash is an escape character in JavaScript (it indicates that the next character is 'special' which is how \r becomes CARRIAGE_RETURN and \n becomes LINE_FEED) so, if you need to send an actual backslash, you need to escape the it ('\\' becomes '\').

    Les's suggestion is correct, you would use \r and \n (do not escape those). Though, for rosstalk.sendMessage, we actually automatically append those for you.

    Try:
    rosstalk.SendMessage("xx.xx.xx.xx", 32, "W\\50005\\50000\\ \\LINE ONE\\LINE TWO\\\\", null)

    James
    #DashBoard


  • 5.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 19:57
    Thank you James. Unfortunately that doesn't seem to be working either, and as near as I can tell the command isn't actually being sent. Is there a way to monitor Dashboard network output?

    #DashBoard


  • 6.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 20:07

    To see if there is an error executing your script, you will want to open the "openGear Debug Information View". It will show any exceptions encountered while executing your script. You can also capture any exceptions thrown when trying to actually open the network socket. You'll see this view listed in the "Views" menu in DashBoard's main menu bar.

    One issue I just noticed with your script (and my modified copy/paste of it) is that you have a capital "S" in "rosstalk.sendMessage".

    Fixed case issue:

    function callback(success, sentData, resultString, exception)
    {
        if (!success && exception != null)
        {
          ogscript.debug("EXCEPTION THROWN: " + exception);
        }
    }
    
    rosstalk.sendMessage('xyz.xyz.xyz.xyz', 32, 'W\\50005\\50000\\ \\LINE ONE\\LINE TWO\\\\', callback);
    

    #DashBoard


  • 7.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 20:22
    Ooh, it's throwing a Connection Refused error.
    #DashBoard


  • 8.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 20:28
    java.net.ConnectException: Connection refused: connect
    #DashBoard


  • 9.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 20:42
    Okay, this narrows things down to:

    • The server is not actually running at the given IP Address and port
    • The server cannot accept multiple connections on that port and something else is already using it
    • A firewall is blocking access from your computer (or the DashBoard app) to that port

    #DashBoard


  • 10.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 20:42
    p.s. the capital S in SendMessage was a transcription error. it's sendMessage
    #DashBoard


  • 11.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 20:56
    That's really weird, because it didn't work even when firewalls were turned off on both machines. Also, it works via the Telnet command prompt window, and though it only accepts one connection at a time I've had it closed while testing it. For some reason, Dashboard can't successfully connect, and it seems to be the only thing having that issue.
    #DashBoard


  • 12.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 21:05

    Are you able to run DashBoard on another computer? We could see if there is something blocking DashBoard's ability to communicate on that port to remote machines by running a simple custom panel on another machine that just listens for/outputs text received on that port:

    <abs contexttype="opengear" gridsize="20" id="_top">
       <listener autostart="true" buttontype="toggle" delimitertype="newline" height="80" left="100" listenport="32" name="Listener" style="style:toggleButton;" top="60" width="140">
          <task tasktype="ogscript">if (event.isMessageEvent())
    {
       ogscript.rename('message-output', event.getBytesAsString());
    }</task>
       </listener>
       <label height="80" id="message-output" left="260" style="style:timerLabel;txt-align:center;" top="60" width="620"/>
    </abs>

    #DashBoard


  • 13.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 21:22
    That's very cool, and it's not Dashboard - data is being sent for sure, and it's arriving on this box as expected. There has to be some sort of exception coming from the Chyron even though the firewall is turned off.

    #DashBoard


  • 14.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 21:24
    It's a little odd as ConnectionRefused should be happening at the operating system level (before it even hits the Chyron software).
    Perhaps an IP Address conflict?
    #DashBoard


  • 15.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 21:37
    Well, the Telnet connections aren't blocked, so it kinda has to be the OS level as it doesn't even make it to Chyron - diagnostic logs don't show any input or output at all, so it's not even making it that far.
    #DashBoard


  • 16.  RE: Sending Chyron II commands via Dashboard TCP SendMessage

    Posted 10-19-2018 22:26
    James,

    Thank you for your help.

    Chyron uses telnet on port 23.


    It works now.

    Thank you.

    lol
    #DashBoard