1. Ensure the gRPC server is running on the correct machine.
    Note For a local server, the gRPC server must run on the same local machine as the server. You can launch the gRPC server from the Radar Target Generator pane if the RTG Server.exe is installed on the local machine. Refer to Accessing Utilities for more information.
    Note For a remote server, the gRPC server must run on the same remote machine as the server.
    Note The server must be running for RTG to receive gRPC commands.
    Note The information icon is bordered in red to indicate an invalid configuration or error. Click the information icon for more information.
    Figure 39. RTG gRPC Server Window


    Server Status
    Listening Port Status
  2. Connect to the gRPC server using the UI or the API.
    • To connect using the UI, complete the following steps.
      1. In the Radar Target Generator pane, fill in the IP Address field and the Port Number field for the gRPC server you want to connect to.
      2. Select Connect. The panel moves into the Connected: Idle state.
    • To connect using the API, complete the following steps.
      1. Call Create NI-RTG.
      2. Define the following option string values: CertificatePath, ClassPath, IPAddress, and Port Timeout.

Server Default Settings

The RTG server default settings are as follows:

  • The gRPC server port is 50052.
  • The server finds the IP address of the host computer automatically. Use the IP address or computer name to access the gRPC server through a gRPC client.

Refer to Using the Configuration Utility to change the server default settings in the INI file.

Remote Communication

For remote communication, the Radar Target Generation software includes a designated server, RTG Server.exe, to listen for remote commands by way of gRPC. gRPC is an open-source, language-agnostic framework that uses protocol buffers to send data between systems and services. For more information about gRPC, refer to Introduction to gRPC on the gRPC Open Source Framework website.

When using gPRC, you can establish a connection to the RTG server and send data in the following ways:

  • Un-Encrypted (Default)—For an un-encrypted connection, users must specify a server IP address and server port number in the [Setting] section of the RTG configuration file prior to launching the server. The server IP address is then coupled with the IP address in the [DriverSetup] section or API option string to ensure that you can send and receive commands directly to the RTG system.
  • Encrypted—For a secure encrypted connection, users must specify a path of a Signed Certificate on the system running the server, the path of the private key, the server IP address, and the server port number in the [Setting] section of the RTG configuration file. This must then be paired with the Signed Certificate on the client and the IP address of the server to which to connect in the [DriverSetup] section or API option string. Users can generate classes from the protocol buffer file, for their language of choice, using open-source protocol buffer compilers. RTG provides the NI-RTG gRPC Client API, built on LabVIEW code generated from the protocol buffer file. Users can use this API in the same manner as RTG's local API.
    Note When using certificates to create an encrypted connection, verify that the certificate is signed and has the common name field populated appropriately. Otherwise the RTG client cannot connect to the specified server.
  • NI provides an example script to generate a certificate using OpenSSL. Find this example on the ni/grpc-labview repo on GitHub.