Mushroom Fruiting Automation with Mycodo
Create a fully automated system to control the optimal conditions for mushroom fruiting, including temperature, humidity, and CO₂ levels, using Mycodo and a grow tent setup.
What You'll Need:
Grow Tent – Size based on available space (e.g., AC Infinity 36”x24”x72”).
Sensors:
Control Devices:
Exhaust Fan – At least 100 CFM to effectively manage CO₂ levels.
Humidifier – Reptile fogger or other humidifier with a tube attachment for direct airflow control.
Grow Lights – Adjustable, full-spectrum lights for encouraging fruiting.
Raspberry Pi 4 – Running Mycodo for automation and control.
Solid-State Relays (SSRs) – For controlling fan, humidifier, and lights, compatible with Mycodo.
Additional Items:
Power supply and extension cords for all devices.
Mounting hardware and zip ties to organize cables.
Step 1: Setting Up the Tent and Mounting Components
Grow Tent Assembly:
Assemble the grow tent according to the manufacturer’s instructions, ensuring it’s in a suitable location for ventilation.
Confirm that the tent is sealed well to maintain controlled conditions.
Mount the Sensors:
Attach the temperature and humidity sensor at fruiting height in the middle of the tent. This ensures accurate readings where mushrooms are growing.
Place the CO₂ monitor close to the substrate level if the species is sensitive to CO₂ levels.
Install Control Devices:
Humidifier: Position the humidifier near the tent’s top, with the output tube directed downward to distribute humidity evenly.
Exhaust Fan: Mount the exhaust fan at the top of the tent, ensuring it vents to the outside or a well-ventilated area.
Lighting: Install grow lights at an adjustable height above the blocks, or attach to the sides if stacking blocks.
Step 2: Setting Up Mycodo on Raspberry Pi
Install Mycodo:
Connect your Raspberry Pi to power and internet.
Download and install Mycodo on the Raspberry Pi. Follow the Mycodo installation guide, which includes setting up dependencies and Mycodo’s web interface.
Once installed, access the Mycodo web interface through your browser to begin configuration.
Connect the Raspberry Pi to Relays and Devices:
Attach each control device (fan, humidifier, lights) to the Raspberry Pi through SSRs.
Label each relay channel based on the connected device for easy identification.
Ensure all connections are secure and that your relays can handle the power requirements of each device.
Step 3: Configuring Inputs in Mycodo (Sensors)
Temperature and Humidity Sensor:
In the Mycodo interface, navigate to Inputs and select “Add Input.”
Choose the appropriate sensor type (e.g., DHT22 or AM2301) from the list.
Set the polling interval (e.g., every 5-10 seconds for accurate control).
Save the input and verify readings appear correctly in Mycodo’s dashboard.
CO₂ Monitor (if applicable):
Repeat the process for the CO₂ sensor by selecting “Add Input” and configuring the interval.
Set CO₂ thresholds (e.g., >800 ppm for fan activation) based on mushroom species requirements.
Step 4: Setting Up Outputs in Mycodo (Control Devices)
Add Control Outputs for Each Device:
Go to Outputs and add each device (fan, humidifier, lights) as an output in Mycodo.
Assign the corresponding relay to each device and label them accordingly.
Test each output manually in Mycodo’s interface to confirm they activate and deactivate correctly.
Step 5: Creating Automated Conditions
Humidity Control:
Go to Conditionals and create a new conditional for the humidifier.
Set a condition to activate the humidifier when humidity drops below your target (e.g., 85% for oysters).
Add an action to turn off the humidifier once humidity reaches the upper threshold (e.g., 90%).
Test the humidity conditional by manually changing the threshold and observing the humidifier’s response.
CO₂ Management:
Create a conditional for the exhaust fan to manage CO₂ levels.
Set the fan to turn on when CO₂ levels exceed 800 ppm and off when they drop below 600 ppm.
This conditional will help maintain fresh air in the tent, essential for preventing stalling and promoting fruiting.
Temperature Control (optional):
If using additional heaters or cooling devices, create a conditional to maintain the temperature within the ideal range for the mushroom species.
Set up similar conditions to turn heating/cooling devices on and off based on the temperature readings from the sensor.
Lighting Schedule (optional):
If lighting needs to follow a cycle, configure an automation schedule to turn lights on and off based on the desired photoperiod (e.g., 12 hours on, 12 hours off).
Confirm the lights operate within the parameters you set.
Step 6: Testing and Calibration
Test Each Device in Manual Mode:
In Mycodo, switch each device to manual mode to verify their response times and functionality.
Observe and adjust any delays in activation to ensure smooth operation when automated.
Fine-Tune Conditional Thresholds:
Monitor environmental conditions over the next 24-48 hours and adjust threshold values based on mushroom growth response and sensor readings.
Log data through Mycodo’s Data Acquisition feature to review trends and identify optimal ranges for each parameter.
Step 7: Regular Monitoring and Maintenance
Monitor System Alerts:
Set up Mycodo’s Alert System to send notifications if any sensor goes out of range.
This can alert you to problems with equipment or sudden changes in conditions, reducing the risk of lost yields.
Check Sensor Calibration:
Periodically recalibrate sensors, especially the humidity sensor, to maintain accurate readings.
Clean the fan and humidifier regularly to ensure no blockages or microbial buildup impacts performance.
Review and Adjust as Needed:
Over time, you may need to adjust conditional thresholds based on mushroom variety, tent occupancy, or seasonal temperature changes.
Use logged data to refine your automation setup for better yields and consistency.