Aim-TTi PL303QMDP#
Control the Aim-TTi PL303QMDP power supply from Python with the PL303QMDP driver.
Driver: pymeasure
Type: Power supplies
Manufacturer: Aim-TTi
Control AimTTI PL series power supplies.
Publishing through instro#
instro publishes the commands you send to a PL303QMDP and the values you read from it, through any publisher. It takes two forms, both described in the pymeasure guide. Install with uv add "instro[pymeasure]".
With a PymeasureInstrument#
PymeasureInstrument wraps the driver in an instro instrument, with tags and background polling. The instrument is created inside the with block, and .device is the pymeasure instrument.
from pymeasure.instruments.aimtti import PL303QMDP
from instro.pymeasure import PymeasureInstrument
with PymeasureInstrument(
name="psu",
instrument=PL303QMDP("ASRL7::INSTR"),
dataset_rid="<dataset rid>",
) as psu:
psu.device.reset()
psu.device.ch_2.voltage = 1.2
psu.device.ch_2.output_enabled = True
...
psu.device.ch_2.output_enabled = False
psu.device.local()
With existing pymeasure code (attach())#
attach() adds publishing to pymeasure code you already have. The imports, the attach() call after the instrument is created, and recorder.close() are all that instro adds.
from pymeasure.instruments.aimtti import PL303QMDP
from instro.lib import NominalCorePublisher
from instro.pymeasure import attach
psu = PL303QMDP("ASRL7::INSTR")
recorder = attach(psu, "psu", [NominalCorePublisher(dataset_rid="<dataset rid>")])
psu.reset()
psu.ch_2.voltage = 1.2
psu.ch_2.output_enabled = True
...
psu.ch_2.output_enabled = False
psu.local()
recorder.close() # flush and close the publishers
The examples are adapted from the pymeasure documentation for PL303QMDP, which lists every property and method.