Skip to content

Latest commit

 

History

History

README.md

SystemLink Client API Examples

This directory holds self-contained example projects for various aspects of the SystemLink Client APIs. To make finding relevant examples easier, a summary of each one is listed below.

Running an Example

Unless otherwise specified by the example's README, each example is run in the same way:

  1. Download and extract the repository source.
  2. Install the .NET Core SDK.
  3. Navigate to the example's directory and use the dotnet run command.

To run the example with a different configuration, use one of the following commands instead:

dotnet run -- --cloud <api_key>
dotnet run -- --server <url> <username> <password>

For example: dotnet run -- --server https://my_server admin "my password".

Solution File

For convenience, the NISystemLinkClientExamples.sln solution file can be used to build all example projects at once. Some development environments such as Visual Studio also support using the solution file to view and run all example projects at once. Note that the dotnet run command used to run an example requires referencing individual projects and does not support the solution file.

Common Examples

The following examples demonstrate concepts common across all SystemLink Client APIs:

  • configuration: Demonstrates the different ways to supply a configuration for SystemLink APIs.

API Examples

  • Utilization: Demonstrates how to use the SystemLink Asset Management Client API to track asset utilization.
  • Stream: Demonstrates how to use the SystemLink File API to upload files using an in-memory stream.
  • Send and Receive: Demonstrates how to use the SystemLink Message Client API to send and receive messages between sessions.
  • LabVIEW Async: Demonstrates how to use the SystemLink Message Client API to asynchronously send and receive messages as part of the Async Messaging LabVIEW example.
  • Query: Demonstrates how to use the SystemLink Tag services API to query for tags by properties to retrieve metadata for each tag.
  • Selection: Demonstrates how to use the SystemLink Tag API to read metadata and values for multiple tags at once.
  • Subscription: Demonstrates how to use the SystemLink Tag API to receive notifications when tag values change.
  • Results: Demonstrates how to use the SystemLink Test Monitor API to publish test results to the server.
  • File Attachment: Demonstrates how to use the SystemLink Test Monitor API to attach files that are uploaded to the SystemLink server using the SystemLink File API.