Thales-Remote-Python is a Python extension which uses the Zahner Remote2 to control Zahner ZENNIUM Potentiostats.
It was developed to easily integrate Zahner ZENNIUM Potentiostats into Python scripts for more complex measurement tasks and for automation purposes.
The measurement methods Impedance Spectroscopy (EIS), Cyclic Voltammetry (CV), Current–Voltage characteristic (IE),and DC sequences are supported. Also constant current or constant voltage can be output and current and voltage can be measured. Single frequency impedance measurement is also possible. Other supported functions are the remote control of the BC-MUX and the import of ism files in Python.
The complete documentation of the individual functions can be found on the API documentation website.
The package can be installed via pip.
pip install thales_remote
⚠️ Since v1.1.1 works only with Thales ≥ 5.8.6. For previous versions of Thales Software, please download an older version of the package.For example:
pip install thales_remote==1.0.1
The class BCMuxInterface to control the BC-MUX is located in the Python file BCMuxInterface.py, from this file the class can be imported.
There is a separate Python package on GitHub and PyPI/pip for analyzing measurement data.
In this repository there are examples of how to fit equivalent electrical circuit models to electrochemical impedance spectra, also known as EIS equivalent circuit fitting. The model parameters can be further processed after the fit with Python, for example for the comparison of serial measurements.
The Jupyter notebook BasicIntroduction.ipynb explains the fundamentals of using the library.
"""
Connect to the Zahner Zennium Potentiostat
"""
zenniumConnection = ThalesRemoteConnection()
zenniumConnection.connectToTerm("localhost", "ScriptRemote")
zahnerZennium = ThalesRemoteScriptWrapper(zenniumConnection)
zahnerZennium.forceThalesIntoRemoteScript()
"""
Read the measured voltage and current.
"""
print("Potential: " + str(zahnerZennium.getPotential()))
print("Current: " + str(zahnerZennium.getCurrent()))
"""
Single frequency impedance measurement at 1 V DC and 2 kHz
with 10mV amplitude for 3 periods.
"""
zahnerZennium.setPotentiostatMode(PotentiostatMode.POTMODE_POTENTIOSTATIC)
zahnerZennium.setPotential(1)
zahnerZennium.enablePotentiostat()
zahnerZennium.setFrequency(2000)
zahnerZennium.setAmplitude(10e-3)
zahnerZennium.setNumberOfPeriods(3)
zahnerZennium.getImpedance()
zahnerZennium.disablePotentiostat()
zenniumConnection.disconnectFromTerm()
There is at least one example for each possible electrochemical method that can be controlled remotely.
BasicIntroduction.ipynb is the most basic introduction, which describes the connection setup in detail. For each example there is a Jupyter notebook which explains the example code in detail. For the user there is a Python script for each example which contains the pure Python code so that Jupyter does not need to be installed.
In the examples only one method is explained and parameterized at a time for better comprehension. But the methods can also be combined flexibly in a Python script, for example a CV measurement followed by an EIS measurement.
- Basic introduction to remote control
- Switch potentiostat on or off
- Setting potentiostat potentiostatic or galvanostatic
- Setting output potential or current
- Read potential and current
- Single frequency impedance measurement
- Measurement of an impedance spectrum - EIS
- Importing the measurement results from the ism file into Python
- Plotting the spectrum in bode and nyquist representation with the matplotlib library
- Zahner DC Sequencer measurement
- Sequencer file generation with Jinja2 template engine
- Measurements at different current strengths or current densities
- EIS measurement
- Measurement of an impedance spectrum - EIS
- Importing the measurement results from the ism file into Python
- Acquiring the measurement files with Python via network
- Setting output file naming for impedance spectras
- Parametrizing an impedance spectrum
- Measurement with an external potentiostat (EPC-Device)
- Measure cylic voltammetry measurement
- Setting output file naming for CV measurements
- Parametrizing an CV measurement
- Importing the measurement results from the isc file into Python
- Acquiring the measurement files with Python via network
- Measure cylic voltammetry measurement
- Setting output file naming for CV measurements
- Parametrizing an CV measurement
- Importing the measurement results from the isc file into Python
- Acquiring the measurement files with Python via network
- Setting output file naming for IE measurements
- Parametrizing an IE measurement
- Importing the measurement results from the iss file into Python
- The Zahner sequencer outputs current and voltage curves defined in a text file.
- Setting output file naming for sequence measurements
- Parametrizing an sequence measurement
- Measurement with an external potentiostat or external load (EPC-Device)
- Measure impedance specta and cyclic voltammetry
- Plotting the measurement data.
- Create a PDF with the measurement data using LaTeX
- Measurement of an impedance spectrum on a stack with single cells connected to the PAD4 card.
- Importing the measurement results from the ism file into Python
- Plotting the spectrum in bode and nyquist representation with the matplotlib library
- Setting output file naming for impedance spectra
- Measure impedance spectra with different DC parameters
- Importing the measurement results from the ism file into Python
- Display impedance and phase in contourplots with the matplotlib library
- Configure FRA Probe measurement
- Measure EIS with FRA Probe
- Measure EIS at OCP with the electronic load EL1002 and the Delta Elektronika SM3300 SM 18-220
- Remote control Delta Elektronika SM3300 SM 18-220
- Acquiring the measurement files with Python via network
- Plotting the spectrum in bode representation with the matplotlib library
- Multichannel operation with several external potentiostats, of the latest generation, type PP2x2, XPOT2 or EL1002
- Shared Zennium series device for impedance measurements
- Operation of the power potentiostats standalone without thales with the Python package zahner_potentiostat
- Switch between Thales/EPC and SCPI/standalone operation of the external potentiostats (PP2x2, XPOT2 or EL1002) without switching off the potentiostat
- Shared Zennium series device for impedance measurements
- Operation of the power potentiostats standalone without thales with the Python package zahner_potentiostat
- Remote control of the BC-MUX
- Class which realizes the remote control
Send a mail to our support team.
Feel free to create a new issue with an appropriate title and description in the Thales-Remote-Python repository issue tracker. Or send a mail to our support team.
If you have already found a solution to your issue or feature, we would be happy to review your pull request!
Programming is done with the latest Python version at the time of commit.
For the thales_remote package only the Python standard library was used. If measurement data are imported and plotted, the package zahner_analysis is used.
For standalone communication without Thales with the PP2x2, XPOT2 or EL1002 devices the zahner_potentiostat package is used.
The packages matplotlib, SciPy and NumPy are used in some examples to display the measurement data graphically. Jupyter is not necessary, since each example is also available as a Python file.