Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

A MicroPython greenhouse project can monitor air temperature and humidity, track moisture in a chosen growing medium, and automate a bounded task such as watering. The controller reads sensors and operates a fan, light, or pump through suitable driver hardware—not directly from a microcontroller pin. Treat this as a build pattern: board, wiring, sensor placement, thresholds, and load ratings must match your parts and growing conditions.

How the greenhouse controller works

The basic control path is sensor → MicroPython board → driver or relay → actuator. A local manual switch or other override lets you control an actuator without relying on the automatic loop. Define a safe response for failed or implausible readings; for irrigation, that commonly means stopping the pump rather than leaving it running.

Start with one useful job, such as monitoring conditions or watering when a calibrated moisture reading crosses a crop-specific threshold. A local control loop does not require Wi-Fi or a cloud dashboard. Networking can be added separately for remote monitoring, but it brings its own connectivity and security decisions.

Choose a MicroPython controller

Both ESP32 boards and Raspberry Pi Pico-series microcontrollers have MicroPython support. The right choice depends on the exact board variant, wireless needs, available I/O, pin mapping, and the peripherals your sensors require. MicroPython maintains an ESP32 quick reference; Raspberry Pi documents MicroPython for Pico-series boards.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Elebase USB to USB C Adapter for iPhone 18 Pro Max,USBC Car Charger Adapter
  • Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
  • Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
  • Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
  • Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
  • 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.
Choice Useful when Checks before wiring
ESP32 board You want an ESP32-based build, potentially with Wi-Fi for optional remote features. Confirm MicroPython support for the exact variant, its pinout, which pins support ADC, and the voltage limits. On ESP32, ADC2 shares resources with Wi-Fi; analog reads from ADC2 while Wi-Fi is active raise an exception. Use a suitable ADC1 pin for an analog soil sensor if Wi-Fi will be active, and verify the board documentation.
Pico-series board You want a MicroPython-capable Raspberry Pi microcontroller family and can select a board variant suited to the project. Check the chosen board’s wireless capability, analog-input availability, pin mapping, electrical limits, and MicroPython support for the peripherals you intend to use.

Do not assume a GPIO label or pin number is universal across boards. MicroPython’s ESP32 documentation directs users to board documentation for mapping logical and physical pins and notes that ESP32 variants differ. The same practical rule applies when planning a build around another family: check the selected board’s documentation and schematic.

Select sensors for the conditions you need to know

Air temperature and relative humidity

A DHT22/AM2302 measures temperature and relative humidity; it does not tell you whether the root zone needs water. MicroPython’s DHT tutorial says to call a DHT22 no more often than once every two seconds for the most accurate results. It gives a different cadence for DHT11—no more than once per second—and points readers to the device datasheet for its operating range. Follow the datasheet for the exact sensor you buy.

Rank #2
Anker USB-C Hub, 5-in-1 USB Hub for Laptops, 4K HDMI Multiport Adapter
  • 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
  • 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
  • Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
  • 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
  • What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.

Growing-medium moisture

A soil-moisture probe measures a local signal from the medium around its sensing area. A generic probe’s raw or scaled reading is not a universal plant-water percentage. Readings depend on the sensor, its placement, and the actual medium, so calibrate it in the growing medium you will use and choose thresholds for the crop and setup.

Optional light measurement

A BH1750 light sensor is one option if you want to add light monitoring. It is not required for basic air and moisture monitoring. A community ESP32/MicroPython greenhouse project includes a DHT22, capacitive soil sensor, BH1750, relay board, and pump with tubing among its design choices; that parts list is an example, not a comparative test or a validated recommendation.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
Sale
Anker USB C Hub, 7in1 Multi-Port USB Adapter, 4K@60Hz USBC to HDMI Splitter
  • Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
  • Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
  • Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
  • Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
  • What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.

Gather the parts and check compatibility

Keep the first build small. Add actuators only after the sensors are reading reliably.

Core monitoring parts

  • A MicroPython-compatible controller board selected for the required connectivity and I/O.
  • An air temperature and humidity sensor, such as a DHT22/AM2302.
  • A soil-moisture sensor suitable for the medium and its moisture exposure.
  • A suitable power source, wiring, and any required interface components.

Parts for automation or expansion

  • A relay or other driver matched to the actuator and its electrical load.
  • A pump and tubing for irrigation, or a fan or light if those are the tasks you intend to automate.
  • Optional light sensor, display, enclosure, or logging and network features.

Before connecting a sensor output to a board, confirm its voltage is safe for that board’s input. MicroPython’s ESP32 quick reference gives 3.6 V as the ESP32 input-pin absolute maximum. That is a limit, not a target operating voltage; check the exact board and sensor specifications rather than assuming a module’s output is compatible.

Rank #4
Sale
UGREEN USB to USB C Adapter Combo 4-Pack, 10Gbps USB C Converter Space Gray
  • Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
  • Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
  • Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
  • Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
  • Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft

A pump is an electrical load, not something to power from a GPIO pin. Use a separate power arrangement and a switching device rated for the pump’s specifications. Check the pump’s voltage and current requirements, the driver’s ratings, and the flow and head needed by your irrigation layout. The parts in the community greenhouse example do not establish a complete electrical-safety design. Enclose and route the hardware appropriately for a damp environment, and follow component documentation and applicable local requirements.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Build the control loop around measured behavior

Write the program as a recurring sequence: read sensors at suitable intervals, validate readings, decide whether action is needed, switch the driver, and record or display the result if desired. MicroPython’s ESP32 tutorial path provides an official starting point for ESP32 setup and peripheral use.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Best Value
Anker USB C Hub, 5-in-1 USBC to HDMI Splitter with 4K Display
  • 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
  • Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
  • Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
  • HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
  • What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.
  1. Read at an appropriate cadence. Respect the sensor’s sampling guidance; for a DHT22, allow at least two seconds between calls for the most accurate results. Soil readings can be collected on a cadence appropriate to your system rather than being treated as instantaneous truth.
  2. Calibrate the moisture signal in context. Place the probe as it will be used, observe its readings in the selected medium under conditions you understand, and establish what readings correspond to the watering state you want. Do not copy a threshold from another sensor, pot, or crop without checking it.
  3. Use a deadband (hysteresis). Set distinct start and stop conditions so small fluctuations around one threshold do not rapidly switch a pump or fan on and off.
  4. Bound each actuator run. Give a pump a maximum runtime, then stop it and recheck before another run. The appropriate duration depends on the pump, tubing, medium, and container; the cited sources do not establish a universal value.
  5. Handle errors explicitly. If readings are missing, invalid, or implausible, avoid making an uncontrolled watering decision. Put the output in its defined safe state and provide a way to inspect or override it.

There is no crop-independent moisture threshold or watering schedule established here. Choose setpoints for the crop and growing medium, then adjust them based on observed readings and plant conditions.

Commission the build before leaving it unattended

  • Test sensor readings and actuator switching separately before combining them in automatic control.
  • Verify the board pin mapping, sensor output levels, and driver connections against the exact component documentation.
  • Test a pump with water safely contained; confirm it starts, stops, and respects the maximum runtime.
  • Observe readings and control behavior over time before relying on automation, and keep the manual override accessible.

This approach keeps the project useful without implying that a particular parts list or threshold is a tested turnkey greenhouse. For a source example of an ESP32/MicroPython arrangement, see the author’s greenhouse project.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.