Controller · LinuxCNC

Connect LinuxCNC

LinuxCNC has an official mtconnect-agent HAL component: an embedded HTTP agent on port 5000 (bound to 127.0.0.1 unless HTTP_BIND=0.0.0.0), optional MQTT and SHDR on 7878, endpoints /probe, /current, /sample and /assets, validated against MTConnect 1.7 schemas.

At a glance

Native protocolMTConnect (mtconnect-agent component)
Port5000 HTTP; 7878 SHDR
MQTTOptional (python3-paho-mqtt)

Connection paths

Ports

PortProtocolNote
5000HTTPAgent
7878TCPSHDR

Software versions

  • Documented in the LinuxCNC development manual (Oct 2026)

Data you can read

  • HAL pins mapped with HAL_ITEM entries; device model from the INI file

Setting it up

  1. Load the componentloadusr -W mtconnect-agent in the HAL file.
  2. Expose itSet HTTP_BIND=0.0.0.0 to reach it from the network.
  3. Map itemsAdd HAL_ITEM entries for the pins you need.

Troubleshooting

SymptomLikely causeFix
Agent unreachable from the networkBound to localhostSet HTTP_BIND=0.0.0.0.

Connectors that support this control

ProductVendorTypeOutputs
MTConnect cppagentMTConnect Institute (Apache-2.0)Open sourceMTConnect REST, MQTT

CNC connector directory →

Related

Sources

Facts on this page come from these documents, opened on 27 October 2026.

  1. LinuxCNC — mtconnect-agent

Last verified 27 October 2026 against vendor documentation. OPC UA Connect is an educational resource published by TEEPTRAK; it is not affiliated with the OPC Foundation, the MTConnect Institute or any control maker.

CNC Connectivity Field Kit
Take the Field Kit to site
Every controller on one spreadsheet, with ports, licences, commissioning checklists and a firewall request template. Free with an engineer account.
Get the Field Kit →