Developing a Custom Protocol for PXIe-657x Interfaces
- Updated2025-09-22
- 4 minute(s) read
The Semiconductor Device Control Add-On Professional edition for InstrumentStudio includes a Visual Studio project template that enables you to add custom protocols to the existing PXIe-657x interface.
The NI657x project template is an extension of the generic protocol project template and is designed to allow you to quickly create, build, and deploy a custom PXIe-657x protocol as an I2C protocol for PXIe-657x interfaces. The project template provides default logic and an example pattern. You can use the default logic and example pattern or modify them to meet your requirements.
The following diagram illustrates the workflow of creating a custom PXIe-657x protocol:
Creating and Deploying a Custom Protocol for PXIe-657x Interfaces
- Launch Visual Studio.
- Enter Semiconductor Device Control NI657x Protocol Library in the search field.
-
Click Semiconductor Device Control NI657x Protocol Library to
create a new NI657x protocol project from the protocol template for PXIe-657x interfaces.
Note The project template for the PXIe-657x protocol provides basic settings required by a PXIe-657x protocol. You can define new settings or modify existing settings according to your requirements. Refer to the NI657x Protocol Template Default Settings section for more information about the default logic of the protocol template.
-
In the Configure your new project dialog box, enter the
name of the protocol.
The name must be different than any existing protocols for the PXIe-657x interface. The word Protocol automatically appends to the name you specify when the project is created.Note When creating a new project, do not change any of the class names in the project template. The class names are automatically generated with the template.
-
Set up the pattern files required for the protocol.
Note Use the example pattern project located in the project folder. The example pattern project defines the default logic of the NI657x protocol template. The pattern follows a simple I2C protocol structure.
- Add logic to define the source waveform usage based on the patterns used in the CreateWriteWaveforms() and CreateReadWaveforms() APIs. These APIs are located in the waveform creation logic section. The default logic these APIs provides to the source waveform requirements of the example pattern. You can modify the logic to meet your requirements.
- Build the project and use the unit test project to debug and resolve any issues with the logic.
- Run the PackageGenerator.bat file located in the Visual Studio project directory to create the package file.
-
Run the package (.nipkg file) to deploy the
binaries.
Note Ensure that InstrumentStudio is closed when running the package. When the package finishes installing, open InstrumentStudio to use the new protocol.
- When the package finishes deploying, the custom PXIe-657x protocol appears in the Protocol section of the Add Function dialog box of the PXIe-657x interface.
NI657x Protocol Template Default Settings
The NI657x protocol template provides the following default settings: