External Units

The External Units were designed by Krisztina Nagy, with whom I partnered together to carry out this project. She designed the circuit of the External Units, and I helped her to finish the software of these units.

The Home Automation System can currently handle up to three external units. The external units can measure temperature and humidity values, and the units can be equipped with two gas sensors from the MQ-family. Two analog circuits are designed (one for each sensor) to amplify and adjust the analog signals for the microcontroller. Each external unit features two relays which can control electrical devices connected to the units. The external units can communicate with the central unit via 2.4GHz radio, RS-485 and KNX. (The KNX interface has not been initialized for communication yet.) Since the external modules can be also supplied from the KNX bus, an auto-switching power supply multiplexer module was used to switch between the power sources automatically.



  • LM2594 (adjustable) step-down converter to establish stabilized 5V DC
  • MCP1755S step-down converter to establish stabilized 3V3 DC
  • TPS21114A auto-switching power multiplexer
  • STM32F107VC ARM Cortex-M3 core microcontroller
  • RFM73P 2.4GHz radio module with external antenna connectivity
  • MAX3485CSA RS-485 interface module
  • E981-03 KNX module
  • HIH6130 Temperature & Humidity sensor
  • Two gas sensor connection port (designed for the MQ-family, currently equipped with MQ-3)
  • Two analog amplifier circuits (with potentiometers for calibration and adjustments)
  • Two HFD23/005 relays
  • Four programmable LEDs
  • Internal DIP Switch for device ID selection

View External Board Schematic View External Board PCB


The External Units are designed to fit into a nice and ergonomic aluminum enclosure. The sensors, including the temperature & humidity sensor and the gas sensors are hanging out of the enclosure in order to measure the environment as accurately as possible. The required holes for the connectors, sensors and LEDs on the aluminum enclosure was milled based on our plans. These precise mechanical works were performed by Metronic Kft.


The software of the External Units are designed to be the same on each unit. On startup, the device ID is defined upon the state of the DIP switch. The microcontroller performs measurements in every second, and it is constantly watching the communication interfaces for incoming data. The units are able to respond to the Central Unit on each communication interface. The units control the relays based on the message received from the Central Unit. Although the system communication currently based on a polling-method, the system supports the event-based communication as well. For example, if an External Unit measures any extraordinary value, a message can be sent immediately to the Central Unit, and there is no need to wait for a query message.