- Home
- PLC Solution Library
- Simulators
- Fermentation cellar
PLC Solution Library · Fermentation cellar simulator
Keep every fermentation tank between its limits
Fermentation makes heat, and each tank holds a different wine. In this simulator, one M-Duino 42+ reads a probe in each of four tanks, opens the cooling jacket valve of the tank that goes above its maximum and runs the chiller only while a jacket is open.
Choose a scenario, change the limits or break a valve, a probe or the chiller. Watch each tank, the glycol loop, the alerts and the record every 5 minutes.
Choose your scenario
-
PLC readingReal temperature (simulator only)LimitsValve open
Operator reset stands for the reset on the panel PC: it acknowledges the alerts and lets the chiller start again once its fault input is clear.
Your design choices
These are choices you make in your own cellar program. They are explained below. A change applies at once, also in the middle of a scenario.
Limits of each tank
| Tank | Maximum, °C | Minimum, °C | Valve openings |
|---|
Defaults from the settings screenshot of the case: tank 1 from 20 to 26 °C, tank 2 from 18 to 24 °C, tank 3 from 18 to 25 °C, tank 4 from 20 to 26 °C. The PLC refuses a minimum that is not at least 1 °C under the maximum, and limits outside 5 to 35 °C.
Alerts and events
| day and time | tank | event | value | sent to |
|---|
One row per alert or event. The CSV has one row every 5 minutes with the PLC reading of each tank, the glycol temperature and the state of the chiller, like the record of the case. A failed probe is written as a fault, not as a temperature.
How does a PLC keep each fermentation tank between its limits?
With a maximum and a minimum for each tank and one jacket valve per tank. The yeast turns sugar into alcohol and CO2 and gives off heat, so a fermenting tank warms up by itself. The PLC compares every reading with the limits of that tank:
- Above the maximum: the PLC opens the jacket valve. Cold glycol flows through the jacket and takes heat out of the wine.
- Between the limits: the valve keeps its state. An open valve stays open, a closed valve stays closed.
- At the minimum or below: the PLC closes the valve, and the tank starts to warm up again.
This is control with hysteresis. The case shows it in its screenshots: tank 2 at 20.87 °C keeps its valve open until it reaches its minimum of 18 °C. Because each tank has its own limits, tanks with different wines ferment side by side.
A wide band means few valve operations and slow swings of several degrees. A narrow band holds the wine closer to one temperature, with many more operations of the valve and more starts of the chiller. Set Close the jacket valve at to 1 °C below the maximum and compare the Valve openings column.
Run the Four tanks, four stages scenario and follow each tank in its trend.
In what order does the PLC start and stop the pump and the chiller?
The pump, the flow check and the chiller start and stop in a fixed order, so the chiller never runs without a circuit to cool. In this simulator the PLC does it in this order:
- A jacket valve opens. The PLC starts the glycol pump.
- The flow switch confirms flow. Without flow in 20 s, the PLC stops the pump and sends a flow alert.
- The PLC enables the chiller, if it has been off for at least 5 min. That minimum off time protects the compressor from short cycles.
- The last valve closes. The PLC stops the chiller and keeps the pump on 2 more minutes, so the evaporator does not freeze with still glycol.
A chiller has a cooling capacity. In the example it gives 12 kW of cold for 4 kW of electricity, and one tank at 26 °C with glycol at -2 °C takes about 11 kW through its jacket. Two tanks at once already ask for more than the chiller gives. When several tanks open at the same time, the glycol warms up, every jacket cools less and the tanks stay above their maximum for longer.
Run the All tanks at their peak scenario and watch the glycol supply. A cellar avoids it by sizing the chiller for the peak days, by filling the tanks a few days apart, or by letting the PLC cool the hottest tanks first when the glycol is warm.
How does the PLC tell a stuck valve from a busy tank?
An open valve with cold glycol must bring the temperature down. The PLC keeps the temperature at the moment the valve opens. If after 60 min it has not dropped at least 0.3 °C, it sends a valve error alert for that tank.
The check runs only when the glycol is at least 15 °C colder than the wine and the chiller runs. When the whole cellar is at its peak and the glycol is warm, a tank can cool slowly with a good valve. Without that condition, the PLC would blame the valves for a chiller that is too small.
A solenoid valve gives no feedback of its own. To know for sure, fit a valve with a position switch, or a temperature probe on the jacket return. Both need one more input per tank.
Run the Jacket valve stuck scenario, then set Stuck valve check to Off and run it again: the first alert comes only when the wine is already 1 °C over its maximum.
What should the PLC do when a probe fails?
Know that it has failed, and not trust the value. A wired probe here is a Pt100 in a thermowell with a transmitter that gives 0-10 V for -10 to 40 °C. A broken wire reads 0 V, which would look like -10 °C. The PLC treats any signal under 0.2 V or over 9.8 V as a probe fault.
A wireless probe, like the ones in the case, sends a reading every 2 minutes on a battery. Its fault is silence: the PLC marks the probe as failed after 3 missing readings, 6 min. It also warns when a battery runs low, before the probe stops. The M-Duino 42+ has no radio of its own: a gateway or the panel PC receives the wireless probes and writes each reading to the PLC, for example over Modbus TCP, with its time.
With a failed probe, the PLC closes the jacket valve of that tank and sends an alert. It does not know the temperature, so it does not cool blind. The wine keeps fermenting and warming up, which the trend shows as the real temperature. Someone has to check the tank by hand until the probe is replaced. Another choice is to cool on a fixed time cycle until then. It is a decision for the winemaker, not for the program.
Run the Probe and chiller faults scenario with wired probes, then with wireless probes.
Design choices you make
1. Where the valve closes
Closing at the minimum, as in the case, gives the fewest valve operations and lets the tank swing across the whole band. Closing 1 °C under the maximum keeps the wine near the top of its band. Choose with the winemaker: the limits are part of the recipe of each wine.
2. When an alert is worth sending
Every tank goes a little over its maximum before its valve opens and the wine starts to cool. An alert at the maximum fires on every cycle, and people learn to ignore it. An alert at 1 °C over the maximum for 30 min fires only when the cooling cannot keep up. Set Temperature alert to At once and count the alerts.
3. Wired or wireless probes
A wired probe gives a reading every scan of the PLC and fails in a way the PLC sees at once. A wireless probe needs no cable to each tank, which helps in a cellar with many tanks, but it reads every 2 minutes, runs on a battery and fails by going silent. The case uses wireless probes over Wi-Fi or LoRa, with batteries that last 2 weeks per charge.
4. Where the logic lives
Keep the limits, the valves and the chiller interlock in the PLC, and the screens, the record and the alerts in the panel PC. If the panel PC stops, the PLC keeps cooling with the last limits. The panel writes new limits to the PLC registers, for example over Modbus TCP, and the PLC checks them before it uses them.
5. Outputs for the valves
The digital outputs of the M-Duino 42+ are optoisolated, 5 to 24 Vdc, with 70 mA at most each. A solenoid valve coil usually needs more. Drive each valve, the pump contactor and the chiller enable through an interface relay with a coil under 70 mA, and fit a suppressor on each valve coil.
The case study behind this simulator
This simulator goes with the SI-WINE success story by SIRA, a technology company from Andorra. In SI-WINE, wireless probes inside the tanks report every 2 minutes, an M-Duino 42+ acts on the jacket valves and the cooling machine, and a 7-inch TouchBerry Pi panel PC shows the tanks and sends alerts by email, Telegram or WhatsApp. This simulator zooms into the control of the cold.
Read the SI-WINE wine fermentation success story
The limits of the four tanks come from the screenshot of the case. The tank size, the chiller, the glycol loop, the times and the faults are examples, not data from the winery. The case does not publish how the outputs are wired.
To follow battery radio nodes and a gateway across a site, try the Wireless Sensor Network simulator.
Learn the building blocks
These examples cover the parts of this cellar on Industrial Shields hardware.
- The basics of the analog inputs of an industrial PLC, for the probe transmitters
- Chiller control over Modbus RTU with an M-Duino, when the chiller takes orders by bus
- A Modbus TCP register map for a plant on an M-Duino, for the limits and the states that the panel PC reads and writes
- CSV logging with a live history table on a TouchBerry, for the record every 5 minutes
- Telegram alerts and remote control, for the alerts to the phone
More examples: PLC Solution Library · all simulators.
M-Duino 42+: the specs that matter here
| Name | M-DUINO ETHERNET PLC ARDUINO 42, reference IS.MDuino.42+ |
|---|---|
| Inputs | 26: 12 analog/digital (0-10 V, 10-bit) and 14 digital optoisolated (5 to 24 Vdc), 4 of them with interrupt |
| Outputs | 16: 10 digital optoisolated (5 to 24 Vdc, 70 mA) and 6 analog/digital/PWM (0-10 V, 8-bit, 20 mA) |
| Communication | Ethernet W5500 (RJ45), RS-485, RS-232, TTL serial, I2C, SPI |
| Built in | Real-time clock, microSD slot, USB 2.0 Type-B |
| Controller | Arduino Mega 2560 (ATmega2560, 16 MHz) |
| Power supply | 12 to 24 Vdc |
| Mounting | DIN rail TS35, IP20, inside a cabinet |
| Programming | Arduino IDE with the Industrial Shields boards package |
Example I/O for this cellar
| Signal | PLC I/O | Count |
|---|---|---|
| Tank probes, Pt100 with a 0-10 V transmitter | Analog inputs | 4 |
| Wireless probes (option) | Through a gateway or the panel PC, Ethernet, Modbus TCP | 4 |
| Glycol supply temperature | Analog input | 1 |
| Flow switch, chiller running, chiller fault | Digital inputs, optoisolated | 3 |
| Jacket valves, one per tank | Digital outputs, through interface relays | 4 |
| Glycol pump, chiller enable, alarm beacon | Digital outputs, through interface relays | 3 |
| Panel PC: limits, states, record, alerts | Ethernet, Modbus TCP | 1 |
This example uses 5 of the 12 analog inputs, 3 of the 14 optoisolated inputs and 7 of the 10 optoisolated outputs. With 10 bits over 50 °C, one count of a probe is about 0.05 °C. The same M-Duino 42+ covers up to 8 tanks: 8 valves, the pump and the chiller fill its 10 optoisolated outputs, and the alarm beacon moves to an analog/digital output, and 9 probes fit in its analog inputs. The case speaks of up to 32 tanks per control unit, which needs more outputs, for example expansion modules or remote I/O. Check your loads and levels against the M-Duino family datasheet. Full specs: M-Duino 42+ · M-Duino family.
FAQ
How does a PLC control the temperature of a fermentation tank?
It reads a probe in the tank and compares the value with a maximum and a minimum set for that tank. Above the maximum it opens the solenoid valve of the cooling jacket, and at the minimum it closes it. Between the two limits the valve keeps its state. This hysteresis keeps the valve from switching on every small change, and each tank can have its own limits for its own wine.
What is the start and stop sequence of a glycol chiller for fermentation tanks?
The PLC starts the pump when a valve opens, waits for the flow switch, then enables the chiller, and stops it when the last valve closes, with the pump running for 2 more minutes. A minimum off time of a few minutes protects the compressor. With every jacket closed there is no load and no working circuit, so a chiller that kept running would only cool a still loop, waste energy and cycle on and off.
How can a PLC detect a jacket valve that does not open?
By its effect. With the valve open and cold glycol, the wine must cool. The PLC keeps the temperature at the moment it opens the valve, and if the temperature has not dropped by a set amount after a set time, for example 0.3 °C in 60 min, it sends a valve error alert. The check is valid only when the glycol is much colder than the wine and the chiller runs. A position switch on the valve or a probe on the jacket return gives a direct answer, with one more input per tank.
What happens to a tank when its temperature probe fails?
The PLC must see the fault and stop trusting the value. A wired probe with a 0-10 V transmitter shows a broken wire as a signal near 0 V, which the PLC treats as a probe fault. A wireless probe fails by going silent, so the PLC marks it as failed after a few missing readings. In this simulator the PLC then closes the valve of that tank and sends an alert, and someone checks the tank by hand until the probe is replaced.
Why does a cellar with a big enough chiller still go over its limits at the peak of fermentation?
Because the chiller is sized for its capacity, not for every tank at once. Each open jacket takes heat into the glycol. When more tanks open than the chiller can handle, the glycol warms up, every jacket cools less and each tank takes longer to come back down. Filling the tanks a few days apart, sizing for the peak days or cooling the hottest tanks first all help.
Which Industrial Shields PLC fits the control of a fermentation cellar?
This simulator uses an M-Duino 42+, the PLC of the SI-WINE case. It has 12 analog inputs for 0-10 V probe transmitters, 14 optoisolated inputs for the flow switch and the chiller contacts, and 10 optoisolated outputs for the valves, the pump and the chiller through interface relays. Ethernet links it to a panel PC that shows the tanks, keeps the record and sends the alerts. For more tanks, add outputs with expansion modules or remote I/O.
Send me this architecture
Tell us how many tanks you ferment, how you cool them and who must get the alerts. Our team replies with a proposed architecture for your cellar. Your simulator settings go with the request.