User Tools

Site Tools


socket_server

There are two modes for Socket TCP/UDP output:

  1. Socket client. Scoreboard OCR acts as a client and connects to a 3rd party application
  2. Socket server (new fetature). Scoreboard OCR acts as a server and waits for connections from a 3rd party applications. Only TCP (not UDP) server is currently supported

Socket TCP/UDP output JSON

Socket TCP/UDP output option sends data as JSON lines to socket server.

Syntax to be used in Scoreboard OCR:

tcp://host:port/[stream_id]
udp://host:port/[stream_id]
udp://localhost:3322/stream1

The following command is sent when creating new connection, but ONLY if the stream_id has been specified (this is useful if your graphics service is serving multiple broadcasts at the same time):

{"type":"register", "stream":"stream1", "role":"ocr"}

Command sent when updating data:

{“type”:”ocr”, “values”:{"field_name1": “value1”, "field_name2": “value2”}}
{“type”:”ocr”, “values”:{"time": “3:12”, "score_a": “56”}}

Socket TCP/UDP output TXT

Socket TCP/UDP output option sends data as field=value lines to the server

Syntax to be used in Scoreboard OCR:

tcp://host:port
udp://localhost:3322

Command sent when updating data (lines are terminated with CR+LF):

Clock=2:45
ShotClock=12
socket_server.txt · Last modified: 2019/11/19 22:34 by arturs