Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update readme doc for Measurement Plug-In Client generator #593

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 56 additions & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
- [Installation](#installation)
- [Developing a LabVIEW measurement](#developing-a-labview-measurement)
- [Running a LabVIEW measurement](#running-a-labview-measurement)
- [Generating a LabVIEW measurement client](#generating-a-labview-measurement-client)
- [Running a LabVIEW measurement client](#running-a-labview-measurement-client)
- [Examples](#examples)
- [Using a measurement in InstrumentStudio](#using-a-measurement-in-instrumentstudio)
- [Creating a LabVIEW executable for static registration](#creating-a-labview-executable-for-static-registration)
Expand All @@ -15,7 +17,8 @@
## Introduction

The Measurement Plug-In SDK for LabVIEW packages enable measurement developers
to quickly create LabVIEW measurements and run them as a service. NI Measurement
to quickly create LabVIEW measurements and run them as a service. They also allow developers
to generate a LabVIEW client which communicates with the service over gRPC. NI Measurement
Plug-In Support allows users to interact with measurement services with a
LabVIEW UI in InstrumentStudio.

Expand Down Expand Up @@ -119,6 +122,58 @@ Note:

---

## Generating a LabVIEW measurement client

1. Create and save a new LabVIEW project.

2. From the project window, go to `Tools` → `Plug-In SDKs` → `Measurements` → `Create Measurement Plug-in Client...`.
- A dialog will open displaying the V2 measurement services that are currently running or deployed on the system.

![New measurement client dialog](images/New%20measurement%20client%20dialog.png)

- In the dialog, select one or more available measurements, then click `Create Measurement Plug-in Client(s)`.

- This will create a new measurement client library in the project.

![Measurement client library files](images/Measurement%20client%20library%20files.png)

Note:

- The Measurement Plug-In Client is compatible with all datatypes supported by the Measurement Plug-In.
- For Enum datatypes, the LabVIEW Client supports only contiguous enums.
- If the Measurement Plug-In uses a LabVIEW UI, ring controls in the UI will be represented as numeric controls in the client, maintaining the same representation.

---

## Running a LabVIEW measurement client

1. Open your measurement client project.

2. For non-pin based measurement, open the `Run Client.vi`.
- Set the inputs to the configuration control.
- Run the `Run Client.vi` to invoke the measurement logic and display the results.

![Run Client VI](images/Run%20Client%20Template%20VI.PNG)

3. For pin-based measurement
- Create and save a new VI.
- Navigate to `Measurement I/O` → `Measurement Plug-In SDK` → `Pin Map` → `Register Pin Map.vi` in the palette.

![Register Pin Map VI](images/Register%20Pin%20Map%20VI.png)

- Drag the `Register Pin Map.vi` to the Block diagram.
- Wire the Pin Map path of the measurement to this VI to register the Pin Map.
- Wire the `pin map id` output of this VI to the `pin map context.pin_map_id` input of the Run Client VI.
- Set the `pin map context.sites` input of the Run Client VI.
- Set the inputs to the configuration control.
- Run the `Run Client.vi` to invoke the measurement logic and display the results.

Note:

- To run `Run Client.vi` without registering the pin map for a pin-based measurement, specify the IOResource name in the configuration control instead of the Pin name.

---

## Examples

The `Source\Example Measurements` directory contains example measurement
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/New measurement client dialog.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/Register Pin Map VI.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/Run Client Template VI.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.