Article 13For: IT lead24 Nov 20268 min read

Odoo MQTT: sensors and a PLC into Odoo Community, with no IoT box

Standard Odoo has no MQTT listener, and its IoT app is in Enterprise only. One live plant sends power and temperature signals to Odoo Community: a message each 15 seconds, offline after 2 minutes.

In short. Standard Odoo has no MQTT listener. Its IoT app is in Enterprise only, and it connects printers, scales and cameras through an IoT box. In Case 01, a micro-PLC and temperature sensors publish to an MQTT broker, and Odoo Community listens. Each device sends its state each 15 seconds, and the ERP marks it offline after 2 minutes of silence. The ERP keeps one reading per 5 minutes for 365 days, with US$0 in licence fees.

IT leads and maintenance engineers search for "ứng dụng IoT trong sản xuất" and for "odoo mqtt" with one aim. They want machine and room signals in the ERP, not in one more dashboard. This article shows one path that works, from a sensor to an ERP record, with its limits.

What do the pages on IoT in manufacturing not show?

They do not show a complete path from a sensor to an ERP record. We read five Vietnamese pages on 24 November 2026. Three general pages explain IoT and list its uses. One names the link to ERP and MES systems as a trend. Two monitoring pages describe sensors, a gateway and a separate platform, and one names MQTT. None shows how a signal becomes an ERP record. For "odoo mqtt", the Odoo app store shows four modules. None is for the Odoo version that Case 01 runs.

What is MQTT?

MQTT is an OASIS standard messaging protocol for the Internet of Things. A device publishes a message to a server, the broker, and the broker sends it to each client that subscribed. Each message has a topic name, such as plant/<device>/state, an example that we made for this article. There are three quality of service levels: 0 (at most once), 1 (at least once) and 2 (exactly once). The broker keeps a retained message for future subscribers, and it publishes a will message when a connection closes abnormally.

Does Odoo Community have MQTT or IoT?

No. The IoT app is in Odoo Enterprise only, and we found no MQTT code in Odoo Community.

  • The IoT app. The Odoo editions page marks IoT for Enterprise only. The app connects devices through an IoT box or a Windows program. The Odoo page gives US$20.00 a month for each box (read on 24 November 2026).
  • The devices. The documentation names barcode scanners, printers, scales, screens, cameras, footswitches, payment terminals and measurement tools. The pages that we read do not name MQTT, PLCs, or temperature and humidity sensors.
  • The source code. The Community addons folder has the program for the IoT box, which is not installable in a database. We searched the Community source code for "mqtt", in a copy of September 2026, and found no MQTT code.

For a PLC or a sensor that speaks MQTT, a plant adds a module.

How does Case 01 connect sensors and a PLC to Odoo?

Case 01 is a Vietnamese packaging manufacturer with more than 500 people in two plants. It runs Odoo Community with modules that Hoply.Works wrote. Two functions listen to MQTT.

  1. The device reads and publishes. An Arduino Opta micro-PLC reads on/off inputs that show power on a machine. An ESP32 gateway board reads an Autonics THD temperature and humidity sensor over Modbus RTU. Each device publishes its full state each 15 seconds, and at once when a value changes.
  2. The broker passes the message. The devices and the ERP are clients of an MQTT broker. Each device also keeps a retained status, "online" or "offline", on the broker. The "offline" text is its will message.
  3. The listeners run inside the ERP. Each function has one listener thread in the Odoo server, at quality of service 1. A database lock stops a second thread in the other worker processes. A check each minute starts the listener after a restart. It reconnects when no message came for 5 minutes.
  4. The ERP records the state and the history. A device registers itself on its first message, so it needs no set-up in the ERP. The ERP keeps the current state of each device. For temperature and humidity, it also stores one reading per device each 5 minutes. A daily job deletes readings older than 365 days. Both numbers are defaults.
  5. Alerts go to the ERP chat. The ERP posts a message when an input loses power, and when power returns. Each sensor has its own limits. The screen marks a value out of range at once, and an hourly check posts the alert in working hours.
  6. Silence is a signal. A will message marks the device offline at once. If none comes, a check each 5 minutes finds a device that was silent for 2 minutes. Thus the alert comes 2 to 7 minutes after the last message.

The same design fits any device that publishes MQTT.

What does the ERP record, and what does the user get?

The ERP keeps the current state of each device, and a history only for temperature and humidity. The user gets a list with colours, a chart and chat messages.

Signal Device What the ERP records What the user gets
Power presence on a machine Arduino Opta micro-PLC The current state of each input A red row, and a chat message when power stops and when it returns
Temperature and humidity in a store room Autonics THD sensor on an ESP32 gateway board The current values, and one reading per 5 minutes for 365 days A chart by hour, and an hourly alert in working hours while a value is out of range
Sensor fault The same gateway board A fault flag and an error code An orange row, and a message at the fault and at recovery
Device offline Each device An online flag and the time of the last message A grey row, one alert, and a "back online" message

17 automated tests cover the two functions, for example the single-listener lock and the limits. No test opens a network connection, so the tests do not prove the path from a real device.

How do you keep MQTT safe in a factory?

Give each device its own user name and password. Encrypt the link: MQTT can run on TLS. Keep the broker inside the factory network, and do not open it to the internet.

What Case 01 does not do yet

  • No control from the ERP. The ERP only listens. It cannot start or stop a machine.
  • No OPC UA. The path is MQTT only.
  • No cycle count and no energy data. The PLC reads on/off inputs only.
  • No history for power. The ERP keeps the current state and the chat messages, not a chart.
  • No link to production. A signal does not block a work centre, open a maintenance request or feed OEE. See what Odoo calculates for OEE.
  • Alerts stay in the ERP chat. The functions send no SMS and no e-mail. Out-of-range alerts go out in working hours only.
  • Gaps during a restart. The listeners stop while the ERP restarts. The ERP does not record a change that started and ended in that time.

When does this not fit?

  • You need data each second, or control. That is SCADA or MES work. NIST defines SCADA as a system that gathers data and applies operational controls.
  • Your machines speak OPC UA. OPC UA is a different standard, from the OPC Foundation. Use a gateway or a platform that speaks it.
  • You want dashboards for many device types now. A ready-made IoT platform gives charts, alerts and reports. Choose the ERP path when the signal must become an ERP record.
  • Your devices are printers or scales. The Odoo IoT box supports them, with Odoo Enterprise. Attendance terminals have their own protocol.

What to send us

  1. The signals that you want in the ERP, and what the ERP must do with each one.
  2. The devices that you have: the maker, the model and the output (on/off contact, 4-20 mA, Modbus, MQTT).
  3. The people who must get each alert, and the hours.

Read next: ZKTeco attendance terminals to Odoo in real time · Barcode warehouse on Odoo: labels straight to a thermal printer · Case 01: links to the plant's hardware · Talk to us

Sources

Do you have this question in your plant?

Tell us what you make, how many people work in your plants, and which tools you use today. We answer in English or Vietnamese.

Talk to us