See MM6D, MM7D, MM8D, MM9A and Mini serial console for MM8D equipments!
We growing mushrooms at home in cellar and two tents, but we have another growing site one km away from home. The are of this site is 1700 m2, we grow pumpkin, tomato, egg-plant and other vegetables on three quarter of it. There are two drilled wells, two growing tents, a little wood house on it.
The aim of this project is to ensure the automatic operation of mushroom growing tents and irrigation system of garden and so that the characteristics of the growing environment can be monitored and modified remotely. And these operations should be user-friendly, no programming knowledge required.
Here works a mixed system, it contents Raspberry Pi, personal computer and different Adafruit ESP8266 microcontrollers.
Components of the system(See Electrical control of the mini farm attachment.)
In/on the shack:
- FE is the main electrical distribution box of the grow site. It includes a residual-current device, Type I+II surge protective device and six overcurrent circuit breakers, of which only three are monitored by the MM8D: tents, shack and water pump.
- E-1 is the electrical distribution box of the wood shack. It includes Type III surge protective device, transformer of auxiliary voltage and four overcurrent circuit breakers, of which only one is monitored by the MM8D: cabinet ESz-1.
- MM9A device is used to protect water pump and switch the valves and pumps of the irrigation system on and off in cooperation with the MM8D. It has three control inputs, three 24V DC valve outputs, one 230V AC pump output and two pressure fault relay contact outputs. MM9A is installed in outdoor on wall of shack.
- ESz-1 electrical cabinet contains the IT devices (4G modem, WiFi router), the security devices, two interface cards of the central controller, console and the main control computer. It is a Raspberry Pi 2 B+ with Rasperry Pi OS 10.
- The spare computer is located below. It's a about twenty years old durable Compaq office computer with Debian GNU/Linux 9 operation system. This computer ran 24/7 during the nearly two-year long development and testing period. The reason for this is the more durable parallel port, which can be easily replaced in case of failure.
- MM8D interface cards connected in parallel each other. They have four isolated and protected inputs, four open collector LED outputs and four relay contact outputs. Auxiliary contact of overcurrent breakers (in FE and E-1 electrical distribution boxes) and pressure error outputs of MM9A are connected to inputs, alarm device input and MM9A control inputs are connected to relay outputs. Status LEDs on front panel are connected to open collector outputs.
- Mini serial console for MM8D is connected to the main computer via a 3.3V TTL serial connection, to the spare computer via a traditional RS-232 port. It receives the power supply from the common 5V DC power supply of the cabinet.
The operating software can be used on both operating systems. The software consists of four:
- Operating daemon: The connected MM6D, MM7D and MM9A electrical equipment is controlled by a Python program that runs as a service in the background. Utilities are Bash shell programs. The daemon logs the measured values and states and creates debug log in debugger mode. The program requires internet connection and access to data of OpenWeather.org. Configuration files are in text (INI) format. The configuration program has a full screen character interface, its source code (FreePascal) is available.
- Environmental characteristics adjustment program: The setup program has a full screen character interface, its source code (FreePascal) is available.
- Web interface: You can use a web browser to view the settings for the environmental characteristics, the current measured data and status, and an abbreviated log. And you can get more data via HTTP with external program in plain text and XML format. If there are one or two IP cameras at the growing place, snapshots of these can also be viewed on the website. Web access is provided by CGI programs written in Perl, its Bash shell utility, and web content consists of static HTML files. Currently available in English and Hungarian. This requires an Apache2 web server.
- Hardware checker program: This Python program can be used to verify that the hardware is working properly.
All shell scripts, CGI program, daemon have manual page.
The operation of the central controller can be checked with a web browser or MM8DRead application. The machines are accessible via SSH. Grow tents and irrigation setup can be done remotely with the XMMEEC app. (See Software control of the mini farm attachment.)
Next to the shack:
- Pump pit contents water pump, ball and magnetic valves, pressure regulators, pressure sensors and a manometer. It connects to drilled well and drip line irrigators. Pump pit is builded next to the drilled well.
In the growing tents:
- MM6D is a three channels remote controlled switching device. This device turns on the lights, fans, and heat, and detects the status of the mode switches, the door open sensor, and four internal overcurrent protections for loads. The continuous operation of the microcontroller is ensured by a 3.7V 500mAh LiPoly battery, the alarm sensor is provided by a non-rechargeable 6F22 9V battery. This device based on Adafruit Huzzah Feather ESP8266 microcontroller. Their status can be queried or set via wireless network. The operation of the controller can be checked on a serial console or on network with a web browser, MM6DTest command line program or MM6DRead application. MM6Ds are installed in all growing tents. Operating software is written in C++.
- MM7D is an air quality measuring device. It measures temperature, relative humitidy and unwanted gas concentration and displays air quality on very simple: with three LEDs. This device based on Adafruit Huzzah Breakout ESP8266 microcontroller. The measured values can be queried and LEDs can be turn on and off via wireless network. The operation of the controller can be checked on a serial console or on network with a web browser, MM7DTest command line program or MM7DRead application. MM7Ds are installed in all growing tents. Operating software is written in C++.
(Each tent has an electrical distribution box with Type III surge protective device and overcurrent breakers, but these are not monitored by the MM6D.)
Comments
Please log in or sign up to comment.