Open source PyVISA library can be used for interaction with NI VISA software which, in turn, provides functionality required to support communication with measurement instruments using protocols such as HiSLIP.

To install PyVisa library open command prompt and type:

pip install pyvisa

If you receive error message saying “'pip' is not recognized as an internal or external command, operable program or batch file.“, then ensure that Python is correctly installed.

Check if communication with Pendulum CNT-104S device is possible from python (at the very basic level):

  • 1. Ensure your instrument is connected to the network.
  • 2. Start Python in interactive mode by typing in command prompt: python

In python command prompt type the following lines replacing with the actual IP address of your instrument (can be checked in Settings → User options → Network → Ethernet IP address):

import pyvisa as visa
rm = visa.ResourceManager()
instr = rm.open_resource('TCPIP::')

The last line executes “*IDN?” query which asks the instrument for identification information. You should get response from the instrument like this:

'Pendulum, CNT-104S, 607017, v1.2.0 2023-07-13\n'

  • 4. Type the following to disconnect from the instrument and exit python: