Skip to content
Home » Articles » Working with Samovar in rectification mode

Working with Samovar in rectification mode

This page describes the full operating cycle of Samovar in “Rectification” mode: from power-on and column warm-up to the take-off of heads, hearts and tails and the automatic end of the program. The description applies to firmware 7.00.

General logic of the mode

In rectification mode Samovar separates low wines into three fractions: heads, hearts and tails. The controller heats the boiler through an SSR relay, stabilizes the column with a PID controller and, following the set program, switches the collection containers and controls the peristaltic pump. Temperature is monitored by five DS18B20 sensors: steam, column section, cooling water, boiler, TCA (atmospheric vent tube). The whole process is visualized in the web interface, in the Android and iOS mobile apps and on the samovar-tool.ru website.

The decision to start take-off is made by the operator. After the mode is selected and power is applied, Samovar goes to the “Off” state, waits for a command and only reads the sensors. To start the process, the operator presses “Power on” — the controller turns the heating on and begins warming up the column.

The “Off” state and start-up

When the “Rectification” mode is selected, or after a reboot, the controller stays in the “Off” state: sensor readings are displayed, but heating and pumps are off. Two transitions are possible from this state:

  • “Power on” — the controller turns the heating on in column warm-up mode.
  • “Pump calibration” — a separate service mode for measuring the flow rate of the peristaltic pump.

Column warm-up

After “Power on” is pressed, the controller goes to the “Warm-up” state (status 50, SAMOVAR_STATUS_RECT_ACCEL). In this state the power regulator works in warm-up mode. If the UART power regulator is enabled in your build (the SAMOVAR_USE_POWER flag in Samovar_ini.h), relay No. 4 can switch on a warm-up heating element — it turns off when the boiler temperature approaches the threshold for opening the water valve. The relay for the warm-up heating element must be rated at least 20% above the heating element’s power. If a four-relay module is used, the warm-up heating element can be connected through relay No. 4 — it controls a contactor or another relay of the required power.

When the boiler temperature reaches 77 °C (the OPEN_VALVE_TANK_TEMP constant in Samovar_ini.h), Samovar opens the cooling water valve (relay No. 3, RELE_CHANNEL3), sends a notification to the mobile app and to the samovar-tool.ru website, and shows a message about the cooling water supply on the main screen.

Column stabilization

When the steam temperature exceeds 39 °C (the CHANGE_POWER_MODE_STEAM_TEMP constant in Samovar_ini.h), the controller leaves warm-up mode and switches to stabilization mode (status 51, SAMOVAR_STATUS_RECT_STABILIZING). A notification about this is sent to the app and to the website.

In stabilization mode Samovar waits until the steam temperature fluctuations stay below 0.1 °C for 6 minutes (counted by the number of sensor polls, see alarm.h:463). After that the controller goes to the “Stabilization complete” state (status 52, SAMOVAR_STATUS_RECT_STABLE), a short beep sounds and a notification arrives. If the COLUMN_WETTING parameter and wetting_autostart are enabled in the settings, heads take-off can start automatically — for this, the sketch has an option to autostart heads after stabilization.

The “Stabilization complete” state is the point at which the operator decides whether to start the take-off program. To begin take-off, press “Start take-off” in the web interface or in the mobile app. After you press it, the pump starts at the speed set in the first line of the program.

Take-off program: line structure

The take-off program is a sequence of lines in the text field on the “Program” page. Each line describes one phase of take-off: heads, hearts, tails, a pause, auxiliary actions. A line consists of 5 fields separated by “;”:

  1. Line type: H (heads), B (hearts), C (tails), T (pause), P (pause program), L (Lua stage).
  2. Take-off volume in milliliters (for H/B/C lines) or duration in seconds (for pauses).
  3. Take-off speed in liters per hour (from 0.001 to 5 L/h).
  4. Number of the collection container (an integer from 1 to 4).
  5. Take-off temperature in °C. For heads and tails the automatically detected hearts temperature is used; for hearts, the one fixed at the start of the first hearts line (see below). A value of 0 means it is detected automatically.
  6. Heating element voltage, V (optional).

Example of a heads line: H;200;0.05;1;0;0 — take off 200 ml of heads at 0.05 L/h into container No. 1. Example of a hearts line: B;1500;1.5;2;0;0 — take off 1500 ml of hearts at 1.5 L/h into container No. 2.

Heads take-off

After the program starts, the controller begins with the first heads line. The pump runs at the speed given in the line, and the controller switches containers according to the numbers set in the lines. When the volume of the first heads line has been collected, the controller moves on to the next line of the program.

While any line is running, the operator can adjust the take-off speed at any time — enter a new value in liters per hour on the “Advanced” tab and press “Set”. The minimum speed is 0.001 L/h, the maximum is 5 L/h.

Hearts take-off and fixing the temperature

When the first hearts line begins, the controller memorizes the current steam and column section temperatures. These temperatures become the reference for the entire hearts take-off. You can adjust them at any moment while a hearts line is running by pressing “Set hearts take-off T” on the “Advanced” tab. The controller will overwrite the memorized temperatures with the current sensor readings.

If the “Use pressure correction” option (UsePreccureCorrect in Samovar.h) is enabled, the controller recalculates the memorized hearts take-off temperatures when atmospheric pressure changes (using the BMP180/BMP280/BME280 sensor, if installed): when pressure drops it lowers them, when it rises it raises them, following the dependence of the alcohol boiling point on pressure.

Hearts lines run until the volume set in the program has been collected. If during take-off the steam and column section temperatures go beyond the limits specified in the settings, the controller pauses take-off. If the “Use pump speed correction” option (useautospeed in Samovar.h) is enabled, then along with the pause the controller reduces the take-off speed by the percentage set in the settings.

Impurity detector

Version 7.00 has a built-in impurity detector that watches the stability of the steam and reflux temperature during hearts take-off. If temperature fluctuations exceed the threshold set for the current take-off stage, the detector stops take-off until stability is restored. This protects against tails fractions breaking through into the hearts. The detector parameters are in the impurity_detector.h file.

Tails take-off

When the last hearts line finishes, the controller moves on to the tails lines, if there are any in the program. The speed and container for tails are set in the program. When the last tails line finishes, the controller goes into standby mode: the pump stops, and the power regulator keeps running at the voltage used in the last tails line. A message about the end of the program appears on the main screen and in notifications.

After the program ends, the “self-reflux” mode turns on: the pump is stopped, heating continues. By default this mode lasts 30 minutes (the PROGRAM_DONE_AUTO_POWEROFF_MIN constant in Samovar_ini.h). During this time the operator can decide to switch the column off or to continue take-off with another program (for example, to collect fatty acids if the raw material was grain). If the operator does not intervene after 30 minutes, the controller turns the heating off automatically. A value of 0 in the setting disables the hold — power is removed right after the program finishes.

Control during take-off

While the program is running, the operator can at any moment:

  • Press “Start take-off” again — the controller moves on to the next line of the program.
  • Press “Pause” — the pump stops, heating continues.
  • Press “Resume take-off” — the program continues from the same place.
  • Change the take-off speed on the “Advanced” tab — the new speed applies immediately.
  • Adjust the hearts take-off temperature on the “Advanced” tab — the memorized temperatures will be overwritten with the current sensor readings.

Emergency shutdown

The controller turns the heating off and puts the process into “Alarm” mode when the boiler temperature exceeds the alarm threshold (100 °C by default), when the connection to the boiler or steam sensor is lost, and when the impurity breakthrough detector triggers. The alarm message is sent to the mobile app and to the samovar-tool.ru website, and is shown on the main screen and in the log. After the cause is eliminated, the operator starts the process again.

Where to look up the parameters

  • Water valve opening temperature — OPEN_VALVE_TANK_TEMP in Samovar_ini.h.
  • Temperature of the switch from warm-up to the working mode — CHANGE_POWER_MODE_STEAM_TEMP in Samovar_ini.h.
  • “Self-reflux” hold after the program ends — PROGRAM_DONE_AUTO_POWEROFF_MIN in Samovar_ini.h.
  • Enabling the UART power regulator and the warm-up heating element — the SAMOVAR_USE_POWER flag in Samovar_ini.h.
  • Pins of the water valve and the warm-up heating element — RELE_CHANNEL3 and RELE_CHANNEL4 in Samovar_pin.h.
  • Rectification statuses — SAMOVAR_STATUS_RECT_* in Samovar.h.
  • Program parsing — rect_program_parse_spec() in program_io.h.
  • Impurity detector — impurity_detector.h.
  • Column stabilization — alarm.h, the SAMOVAR_STATUS_RECT_STABILIZING handler.

Leave a Reply