Mettler Toledo Balance — MCP Server
Let an AI agent weigh samples, tare containers, log drift and evaporation, run internal adjustments and drive the draft shield on Mettler Toledo balances through the open MT-SICS interface command set.
| Package | labmcp-mettler-toledo |
| Instruments | Excellence XPR/XSR, XP/XS, XA/XE, MS/ML, NewClassic ME/MS, and other MT-SICS balances and weighing terminals |
| Interfaces | RS-232, USB (virtual COM port), Ethernet (XPR/XSR, or any serial-to-Ethernet adapter) |
| Protocol | MT-SICS levels 0–2 (reference manual) |
| Status | 🧪 simulated: tested against a wire-level MT-SICS simulator, not yet verified on hardware. Report a hardware test |
Try it without hardware
uvx labmcp-mettler-toledo --simulate --check
Connect your balance
- Balance setup: in the balance menu, set the interface (RS232/USB/Ethernet) to MT-SICS (sometimes called "Host" or "Dialog"). Factory settings are 9600 baud, 8 data bits, no parity, 1 stop bit, Xon/Xoff.
- Find the port:
uvx labmcp ports - Test the connection:
uvx labmcp-mettler-toledo --address /dev/ttyUSB0 --check # Linux uvx labmcp-mettler-toledo --address /dev/tty.usbserial-XXXX --check # macOS uvx labmcp-mettler-toledo --address COM4 --check # Windows uvx labmcp-mettler-toledo --address tcp://192.168.1.60:8001 --check # Ethernet
Non-default settings go in the address:serial://COM4?baudrate=19200&xonxoff=false.
Add to your MCP client
Claude Code
claude mcp add balance -- uvx labmcp-mettler-toledo --address /dev/ttyUSB0
Claude Desktop / Cursor / Windsurf (claude_desktop_config.json, .cursor/mcp.json, …)
{
"mcpServers": {
"balance": {
"command": "uvx",
"args": ["labmcp-mettler-toledo", "--address", "/dev/ttyUSB0"]
}
}
}
Add --read-only to allow weighing but block taring, zeroing and door movement. For other clients, generate the snippet with uvx labmcp config mettler-toledo --address /dev/ttyUSB0 --client vscode (also cursor, codex, claude-code).
Tools
| Tool | Kind | Description |
|---|---|---|
clear_tare |
🎛 control | Clear the tare memory (tare = 0). |
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_draft_shield |
👁 read | Report the position of the motorised draft-shield doors (Excellence/XPR balances only). |
get_tare |
👁 read | Return the weight currently stored in the tare memory. |
log_weight_series |
👁 read | Record a series of immediate (unfiltered) readings to monitor drift, evaporation, moisture uptake or stabilisation. Returns every reading plus summary statistics. |
read_temperature |
👁 read | Read the balance's internal temperature probe(s) in °C (MT-SICS M28, if supported). |
read_weight |
👁 read | Read the current net weight from the balance. |
reconnect |
🛑 safety | Close and re-open the connection to the instrument (e.g. after it was power cycled or a cable was re-plugged). |
reset_balance |
🛑 safety | Abort whatever the balance is doing (an adjustment, a repeating weight stream, a pending command) and reset it to its power-on state without zeroing (MT-SICS @). Clears the tare. Motorised draft-shield doors have their own obstruction detection and reverse if blocked. |
run_internal_adjustment |
🎛 control | Adjust (calibrate) the balance with its built-in reference weight (MT-SICS C3). The pan must be empty and the balance undisturbed. Takes roughly 1-3 minutes. |
set_draft_shield |
⚠️ hazard | Open or close the motorised draft-shield doors. Make sure nothing (and no one's fingers) is in the way of the doors. |
set_tare_preset |
🎛 control | Preset a known tare weight (e.g. a container weighed earlier). |
show_message |
🎛 control | Show a short message on the balance display (e.g. 'Add sample 3'). Use show_weight_display to return to the normal weight display. |
show_weight_display |
🎛 control | Switch the balance display back to showing the weight. |
tare |
🎛 control | Tare the balance: store the current load (e.g. an empty container) as the tare weight. Returns the stored tare weight. |
zero |
🎛 control | Zero the balance with the current load. Also clears the tare memory. |
get_connection_info, get_command_log and reconnect are built into every LabMCP server.
Safety limits
| Limit | Default | Meaning |
|---|---|---|
max_series_duration_s |
600 s | Longest weight-logging series an agent may start |
Override at launch: --limit max_series_duration_s=3600. Whatever the limit says, a single series is capped at one hour (the tool's time limit).
Example prompts
- "Tare the balance, then tell me when the reading is stable after I add the sample."
- "Log the weight every 10 s for 5 minutes and tell me the evaporation rate in mg/min."
- "Weigh out ~250 mg: tell me how much more to add, reading every few seconds, until I'm within ±2 mg."
- "Run an internal adjustment and confirm it succeeded before we start the calibration curve."
Notes
read_weight(stable=True)sendsS, which waits for stability. If the balance cannot settle (draughts, vibration), it returnsS I. The server reports this as an error, so retry or usestable=false.- Weights are in the balance's unit 1 (normally grams). Units shown on the display (unit 2) don't affect the interface.
- Draft-shield (
WS) and temperature (M28) commands exist only on balances with that hardware; other balances answerES/L, which the server reports clearly. run_internal_adjustmentwaits for the finalC3 Awithout blocking the connection:reset_balanceaborts a running adjustment, and other commands are refused until it ends (their replies would be mixed up with the result).- Before each command the server discards anything the balance sent unasked (e.g. a print-key transmission) and checks that the reply belongs to the command, so one late reply cannot shift every later reply by one.
show_messageaccepts printable ASCII only, andset_tare_presetonly a unit symbol: a line break would otherwise reach the balance as a second MT-SICS command.
Hardware verification
| Model | Firmware | Interface | Verified by | Date |
|---|---|---|---|---|
| none yet: be the first |
Release files for labmcp-mettler-toledo 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| labmcp_mettler_toledo-0.1.2.tar.gz | 13.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| labmcp_mettler_toledo-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 27.4 kB
Release files / labmcp_mettler_toledo-0.1.2.tar.gz
| Download URL | labmcp_mettler_toledo-0.1.2.tar.gz |
|---|---|
| Size | 13.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7dd4ebcc3c09940d818dfc85d8f0d41e1644b0540a152529834e7019dfb61ab3
|
|
BLAKE2b-256 checksum How to use checksums |
6ce1d9995b38dcc3a0e5ee8f0aad2d568102c9448f2e03b0efd1980f3b86e05d
|
| 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 logRelease files / labmcp_mettler_toledo-0.1.2-py3-none-any.whl
| Download URL | labmcp_mettler_toledo-0.1.2-py3-none-any.whl |
|---|---|
| Size | 13.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
57189035498a1751dcbcd4efa81854106a68358798f90ed1f3a61126b707adf6
|
|
BLAKE2b-256 checksum How to use checksums |
19aaae6c3bae2b7e760756f19756d71eb6a1b3a7c2976996b1fb418d3221d660
|
| 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