Socket Interface
STK Scheduler works in conjunction with STK's Connect module to provide a method for controlling the functions of STK Scheduler via network-based TCP/IP sockets.
STK Scheduler contains a series of specialized STK Scheduler connect commands for this purpose. STK identifies STK Scheduler commands by the "SCHED /" prefix.
See STK Connect Module Help for more information on using the features of the Connect Module.
The format of the command file used for Command Ingest is such that it can be used with the STK Connect command "ConFile /" when using the socket interface.
In some cases when using a machine name for the remote address 'localhost' and the actual machine ID may produce different IP addresses. When setting up the STK Scheduler Configuration on a network be sure to use the actual machine ID.
Each time a command is sent, Scheduler returns a string describing the status of the command. If successful the return value will be: "0, Success". If unsuccessful the return value will be a "-1," followed by an error message (e.g., "-1, Invalid Command Format")
Command Logging
For each socket command received, an entry will be made into the STK Scheduler Log. Any command formatting errors will be recorded in the log along with information about the nature of the error.
Example Programs
The following example programs use the updated TCP socket interface. They can be found in the C:\Program Files\AGI\STK 12\STKScheduler\Examples\TCP directory, with their subfolder referenced in the table below:
Language | Subfolder |
---|---|
Java | Java |
Python | Python |
C# | C# |
A readme file is included with each code sample.
All file locations are based on the default Scheduler install location. Directory paths may change if you have installed in a non-default location.