For a very similar example that only works on Windows, see Section 15.6.
It demonstrates how to set the target of the Jrk by sending a “Set target” command and how to read variables using a “Get variables” command. The example C code below uses parts of the POSIX API provided by Linux and macOS to communicate with a Jrk G2 via serial.