Skip to main content

Pfeiffer Vacuum Gauge Controller — MCP Server

Let an AI agent read and log chamber and foreline pressures, identify the connected gauges, change the pressure unit and switch ionisation gauges on and off (with a pressure check) on Pfeiffer Vacuum TPG total-pressure gauge controllers.

Package labmcp-pfeiffer-tpg
Instruments TPG 361 SingleGauge, TPG 362 DualGauge, TPG 366 MaxiGauge (ActiveLine gauges); TPG 261 / TPG 262 (compact gauges)
Interfaces TPG 36x: USB type B (virtual COM port), Ethernet (TCP port 8000); TPG 26x: RS-232
Protocol Pfeiffer mnemonics protocol, ACK/NAK + ENQ (TPG 361/362 communication protocol BG 5510 BEN, TPG 366 communication protocol BG 5511 BEN, TPG 262 operating instructions BG 805 196 BE section 5; originals in the Pfeiffer download center)
Status 🧪 simulated: tested against a byte-level simulator of the protocol, not yet verified on hardware. Report a hardware test

Try it without hardware

uvx labmcp-pfeiffer-tpg --simulate --check                      # TPG 362: FullRange gauge + Pirani
uvx labmcp-pfeiffer-tpg --simulate --option model=tpg366 --check # 6 channels incl. a cold cathode gauge

The simulated chamber pumps down from 8e-5 mbar towards 2e-7 mbar (10 min time constant) and the foreline sits at about 2.4e-2 mbar.

Connect your controller

  1. Protocol (TPG 36x): the PROTOCOL parameter must be AUTO (factory setting) or MNE (mnemonics), not PV (Pfeiffer Vacuum telegram protocol).
  2. USB (TPG 36x): the USB type B port appears as a virtual COM port. Factory setting 9600 baud, 8N1 (parameter BAUD USB; 19200-115200 also possible).
  3. Ethernet (TPG 36x, TPG 366): set DHCP or a static IP (front panel or Pfeiffer's Ethernet Configuration Tool); the command port is fixed at 8000.
  4. RS-232 (TPG 261/262): 9600 baud 8N1 by default, only TXD/RXD used.
  5. Test the connection:
    uvx labmcp-pfeiffer-tpg --address /dev/ttyUSB0 --check
    uvx labmcp-pfeiffer-tpg --address COM3 --check
    uvx labmcp-pfeiffer-tpg --address "serial://COM3?baudrate=115200" --check
    uvx labmcp-pfeiffer-tpg --address tcp://192.168.1.70:8000 --check
    
    The model is detected with AYT (TPG 36x); a controller that does not know AYT is treated as a TPG 26x. Use --option model=tpg261 (or tpg262, tpg361, tpg362, tpg366) to be explicit.

Add to your MCP client

Claude Code

claude mcp add vacuum -- uvx labmcp-pfeiffer-tpg --address tcp://192.168.1.70:8000

Claude Desktop / Cursor / Windsurf (claude_desktop_config.json, .cursor/mcp.json, …)

{
  "mcpServers": {
    "vacuum": {
      "command": "uvx",
      "args": ["labmcp-pfeiffer-tpg", "--address", "tcp://192.168.1.70:8000"]
    }
  }
}

Add --read-only to allow reading and logging but block unit changes and switching gauges on (switch_gauge_off stays available). For other clients, generate the snippet with uvx labmcp config pfeiffer-tpg --address tcp://192.168.1.70:8000 --client vscode (also cursor, codex, claude-code).

Tools

Tool Kind Description
get_command_log 👁 read Return the most recent raw commands sent to / replies received from the instrument (newest last). Useful for debugging and for recording what was done.
get_connection_info 👁 read Report which instrument is connected (identity, address, simulated or real), whether the server is read-only, and the active safety limits. Call this first.
get_errors 👁 read Read (and clear) the controller's ERROR word: controller error, no hardware, inadmissible parameter or syntax error. An empty list means no error.
get_gauge_types 👁 read List the gauge connected to each channel (TID), what kind it is, and whether it is an ionisation gauge that is currently switched on or off (SEN).
log_pressure_series 👁 read Log pressures at a fixed interval (e.g. a pump-down curve, leak-up/rate-of-rise test or bake-out). Returns per-channel statistics in log-space plus a downsampled series; the full series can be written to CSV. Bounded by max_log_duration_s.
read_all_pressures 👁 read Read every channel of the controller at once (PRX), with status per channel.
read_pressure 👁 read Read one gauge channel: status, pressure in the display unit and in mbar.
reconnect 🛑 safety Close and re-open the connection to the instrument (e.g. after it was power cycled or a cable was re-plugged).
set_gauge_power ⚠️ hazard Switch an ionisation gauge (IKR, PKR, PBR, IMR) on or off (SEN). Switching a hot or cold cathode gauge on at high pressure can burn out the filament or contaminate the gauge, so switching ON is refused unless a valid reading from this gauge or reference_channel is at or below max_switch_on_pressure_mbar. Switching off may trip setpoint relays used as interlocks.
set_unit 🎛 control Change the pressure unit used on the display and interface (UNI). Readings in mbar are always included regardless of this setting.
switch_gauge_off 🛑 safety Switch an ionisation gauge off (e.g. before venting, or if the pressure is rising). Always allowed. Note that setpoint relays assigned to this channel may change state.

get_connection_info, get_command_log and reconnect are built into every LabMCP server.

Safety limits

Limit Default Meaning
max_switch_on_pressure_mbar 1e-2 mbar An ionisation gauge may only be switched on when a valid reading (its own, or reference_channel) is at or below this pressure
max_log_duration_s 3600 s Longest log_pressure_series an agent may start

Override at launch: --limit max_switch_on_pressure_mbar=1e-3 --limit max_log_duration_s=86400.

Example prompts

  • "What's the chamber pressure right now, and is the foreline below 5e-2 mbar?"
  • "Log all gauges every 10 s for 30 minutes and tell me how many decades per minute the chamber is pumping down."
  • "Close the valve, then log channel 1 every 2 s for 5 minutes so I can estimate the leak-up rate."
  • "Which gauges are connected, and which ones are ionisation gauges that are switched off?"
  • "The chamber is below 1e-5 mbar on the FullRange gauge - switch on the cold cathode gauge on channel 3, using channel 1 as the reference."

Notes

  • Switching ionisation gauges on is the hazard. Hot-cathode (Bayard-Alpert) filaments can burn out and cold-cathode (Penning) gauges contaminate when operated at high pressure. set_gauge_power(on=True) requires a reading with status ok at or below max_switch_on_pressure_mbar from the gauge itself or from reference_channel on the same vacuum. An underrange reading from a Pirani is not accepted as proof (what the controller reports on underrange is not specified), so in a Pirani + Penning setup switch the Penning on at the controller, or use a FullRange gauge as the reference. The 1e-2 mbar default is the upper end of a typical cold cathode measuring range; check your gauge's manual and lower it for hot-filament gauges if recommended.
  • Switching a gauge off (switch_gauge_off, or set_gauge_power(on=False)) can change setpoint (switching-function) relays assigned to that channel, which may be wired to valve or pump interlocks.
  • Every pressure comes with the controller's status: ok, underrange, overrange, sensor error, sensor off, no sensor or identification error. pressure is only filled in when the status is ok; raw_value is what the controller sent. Values are converted to mbar (1 Torr = 1.333224 mbar); in V mode no conversion is made.
  • Every command waits for ACK/NAK; after a NAK the ERROR word (controller error, no hardware, inadmissible parameter, syntax error) is read and reported. get_errors reads and clears it.
  • Degas, filter, calibration factors, switching-function setpoints, gauge control (hot start/self control), the data logger and the Pfeiffer Vacuum (PV) telegram protocol are not exposed. RS-485 multi-drop operation has not been tested.

Hardware verification

Model Firmware Interface Verified by Date
none yet: be the first

Release files for labmcp-pfeiffer-tpg 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for labmcp-pfeiffer-tpg 0.1.0
File Size Uploaded
labmcp_pfeiffer_tpg-0.1.0.tar.gz 17.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for labmcp-pfeiffer-tpg 0.1.0
File Interpreter ABI Platform
labmcp_pfeiffer_tpg-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 35.1 kB

Release files / labmcp_pfeiffer_tpg-0.1.0.tar.gz

Download URL labmcp_pfeiffer_tpg-0.1.0.tar.gz
Size 17.5 kB
Tags Source
SHA-256 checksum
How to use checksums
c2ba9f25d6aa351bc0a0886663b30622f5d110feea1f69765a0ece589c98bf8f
BLAKE2b-256 checksum
How to use checksums
d0dd0a52a7c013798a645599441df66aa178e3c3c500bb85818c9614a024bb3c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 26, 2026.

Transparency log

Release files / labmcp_pfeiffer_tpg-0.1.0-py3-none-any.whl

Download URL labmcp_pfeiffer_tpg-0.1.0-py3-none-any.whl
Size 17.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
acd9d21d745a62662dd6b1145b0065fa01028351b39eb12e7e611f249cf64b0d
BLAKE2b-256 checksum
How to use checksums
d52a86de56b7f184bd75e2c7eb6b63c0fccd87d4c6ad043b7540ea5d1342f24d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 26, 2026.

Transparency log

Release history Release notifications | RSS feed

0.1.2

2 release files

0.1.1

2 release files

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page