Deploying Custom Interfaces and Protocols

The Semiconductor Device Control Add-On Professional edition for InstrumentStudio provides default files and folders in the custom interface and protocol projects for creating an NI package that you deploy to the Semiconductor Device Control Add-On.

NI Project Manager installs project files in a specific folder structure. Refer to the NI Package Manager documentation for more information about package components and creating packages.

PackageGenerator.bat File

The PackageGenerator.bat file is a batch file that has the logic to place the custom interface or protocol .dll and .ini files in the packaging folder and create the package (.nipkg) file with the specifications. When the package is successfully created, the .nipkg file is in the same folder as the PackageGenerator.bat file.

Custom.ini File

The custom.ini file binds and loads the interfaces and protocols you create into the Semiconductor Device Control Add-On. The custom.ini file contains the key-value pair needed for the Semiconductor Device Control Add-On. NI recommends that you do not modify the contents of the custom.ini file.

The custom.ini file of a custom interface contains the following information:

  • [Section]—Name of the interface.
  • Interface Type—Name of the interface that appears in the drop-down menu in the Semiconductor Device Control Add-On configuration page.
  • Interface DLL Path—Path to the interface DLL file.
  • Compatible Comms Adaptor—Path to the CommsAdaptorCsharp.dll file.
  • [SampleInterface]
    Interface Type = SampleInterface
    Interface DLL Path = C:\Program Files\National Instruments\Semi Device Control\Components\Hardware Types\SampleInterface.dll
    
    Compatible Comms Adaptor = C:\Program Files\National Instruments\Semi Device Control\AdapterSupport\CommsAdaptorCSharp.dll

    The custom.ini file of a custom protocol contains the following information:

  • [Section]—Name of the protocol.
  • Interface Type—Name of the interface associated with the protocol. When developing a custom protocol and before creating a package, you must modify the custom.ini file the template provides. The interface name for the Interface Type and the Interface DLL Path must match.
  • Interface DLL Path—Path to the interface DLL file.
  • Protocol Type 1—Name of the protocol. Protocol Type 1 appears in the drop-down menu in the Semiconductor Device Control Add-On configuration page.
  • Protocol DLL Path 1—Path to the protocol DLL file.
  • Compatible Comms Adaptor—Path to the CommsAdaptorCsharp.dll file. Do not modify the default path value and Compatible Comms Adaptor field value.
  • [SampleProtocol]
    Interface Type = InterfaceName
    Interface DLL Path = C:\Program Files\National Instruments\Semi Device Control\Components\Hardware Types\[InterfaceName].dll
    
    Protocol Type 1 = SampleProtocol
    Protocol DLL Path 1 = C:\Program Files\National Instruments\Semi Device Control\Components\Hardware Types\SampleProtocol.dll
    
    Compatible Comms Adaptor = C:\Program Files\National Instruments\Semi Device Control\AdaptorSupport\CommsAdaptorCSharp.dll
    Note The .dll filenames are set as <project-name> appended with the word Interface or Protocol for the interface DLL and protocol DLL, respectively.

    Building a Standard Package

    Before you build a package, you must build the interface.
    Complete the following steps to build a package.
    Note This build process does not allow you to perform any advanced operations during the packaging process.
    1. Update the custom.ini file with required interface and protocol information.
    2. Run the PackageGenerator.bat file.
    The PackageGenerator.bat file generates the package (.nipkg) file.

    Building a Custom Package

    A custom package is a package that allows advanced operations that require you to modify the control file or add a dependency to the package.

    Complete the following steps to build a custom package.

    Note You can perform further advanced operations during packaging by generating the package using the packages folder provided. Refer to the NIPKG Guidelines document to understand how to generate a package.
    1. Open the control file located at Packing/ni-sdc-custom/control.
    2. Modify the control file attributes. Refer to the NI Package Manager Manual for information about the control file and its attributes.
    3. Save the control file.
    4. Add any required dependencies such as the required instrument drivers or other dependencies to the folder located at Packaging/ni-sdc-custom/data/ProgramFiles_64/National Instruments/Semi Device Control.
    5. Run the PackageGenerator.bat file.
    The PackageGenerator.bat file generates the package (.nipkg) file containing the changes you specified.