Homepage Down Bottom AquariOS - Aquarium Operating System

Corals

Down Up Top Introduction

Device
In 2015, when I planned and built my lake Victoria tank, I had to decide how to control my custom made LED illumination. I settled on a cheap Arduino Mega 2560 microprocessor board and, apart from a few minor inconveniences, was very happy with its reliable performance. The main nuisance was the spartan LCD / keypad user interface, which mainly allowed to switch lightning modes. So in order to modify light intensity curves or adjust time, which at least had to be done twice a year due to daylight savings nonsense, a USB connection was required.

ESP32
Fortunately technology makes great strides, and we now have the ESP32, developed by Espressif Systems, which is faster, comes with much more memory and wireless connectivity, and is capable of running the FreeRTOS multitasking operating system. Above all the ESP32 development board is a true bargain. Put it on a solderless breadboard along with a PWM interface module, a small OLED or TFT (touch) display, a few resistors, wires and LEDs, and you get the light controller working for no more than 30 USD, which in my opinion represents excellent value for the money. A few dollars more and you own a device offering a mix of all in all 20 output channels to control an armada of light sources, pumps, heaters, feeders and ventilating fans in a flexible way even high-priced commercial products hardly provide.

Apart from a few push buttons (e.g. to start feeding mode manually) AquariOS is completely controllable through its WiFi interface. You only have to have a standard web browser without being urged to allow processing of potentially harmful active web contents. That means plain 'passive' HTML data, no need to use an external cloud service or install any proprietary software on your computer, thus no leakage of information. Or you may already run an MQTT home automation system, which can also take control, e.g. based on data coming from the digital and analog inputs AquariOS offers. System time is automatically retrieved from Internet NTP time servers and retained in a battery-backed real-time clock (RTC) component.

TFT
OLED
At the current stage AquariOS drives two 12-bit I2C devices, which are a PCA9685 16-channel PWM module and an MCP4728 4-channel digital-to-analog converter. Those 16 PWM outputs divide into 8 LED plus 4 pump channels, which are time driven, furthermore 4 temperature controlled heater / cooler on/off-switch channels, whereas all four DAC leads put out a DC signal to run voltage controlled devices, usually pumps. All output values are set five times a second (at 200 millisecond intervals), which enables you to fine tune your wave pumps according to your tank's metrics. The web interface makes it very easy to program individual pump power shapes right down to the last detail.

And there's support for two ADS1015 12-bit / ADS1115 16-bit I2C analog-to-digital converter modules with a maximum of 4 input channels in single-ended or differential mode, scanned in 1 second intervals with MQTT propagation. With appropriate analog sensors like water level or TDS probes attached they allow your home automation system to monitor your tank's status and react accordingly.

Most relevant real-time data as the current date & time, Feed Mode countdown in seconds, the temperature read from a selection of multiple attached DS18B20 thermal probes and output levels of all PWM / DAC channels can be shown at an SPI OLED display, the latter in hexadecimal format with the least significant digit removed and '··' / '**' representing 0x000 (minimum/off) resp. 0xFFF (maximum/on). Or you opt for a TFT display, supported since the 1.0.0 firmware release, to get additional real-time graphs of all pump output channels visualizing the power shapes you programmed. TFT touch screen capabilities add access to a GUI for altering important parameters directly, for example to activate feeder mode or switch lights altogether on or off.

Down Up Top Hardware

Board Schematic
The AquariOS device consists of only a few very cheap components, easily available on the Internet. In the following a list of the core components you may have to add dependent on your controller's future range of duty:

Shopping List
4 x 400 Point Mini Solderless Breadboard 3.35" x 2.16" USD 4.20
1 x Espressif Systems ESP32 WROVER Development Board USD 9.75
2 x LED-10-Segment-Bargraph-Display Fixed Tricolor B10RYG USD 8.00 (5 pcs)
1 x SSD1306 / SSH1106 SPI 128X64 OLED Display Module
or
ILI9341 (XPT2046) SPI 240X320 TFT (Touch) Display Module
USD 5.50
or
USD 6.50
1 x DS18B20 Waterproof 1-Wire Thermal Probe USD 2.00
1 x DS3231 RTC I²C Module with CR2032 Battery USD 3.00
1 x PCA9685 16-Channel 12-Bit PWM I²C Module USD 2.30
1 x MCP4728 4-Channel 12-Bit DAC I²C Breakout Module USD 7.00
2 x ADS1015 4-Channel 12-Bit ADC I²C Breakout Module
or
ADS1115 4-Channel 16-Bit ADC I²C Breakout Module
USD 7.00
or
USD 8.00
2 x MC33074PG OP-AMP 14DIP USD 8.20
1 x LM2596 3A DC-DC Step Down Power Module USD 1.20
1 x MT3608 2A DC-DC Step Up Power Module USD 0.80

Attention! AquariOS version 1.3.0 and above should run on all ESP32 WROVER-B and -E boards including at least 4 MB of PSRAM, whereas version 1.0.0 up to 1.2.0 may have issues with WROVER-E devices and certain PSRAM circuits resulting in a boot loop. Older WROOM modules are only fit for obsolete versions 0.9.x, which demand less memory. Furthermore, make sure that with the module you intend to use all required GPIO lines are accessible via connector pins.

To run the basic AquariOS system you need at least a 5 V power source. Either use a 5 V power supply unit or feed a DC-DC voltage converter with power from one of your devices like your light source or pump. With these 5 V entered through the ESP32 board's USB connector or '5V'/'VIN' pin you also get 3.3 V at its '3V3' pin, with the provided current usually being enough to power the OLED display, DS18B20 temperature sensors, DS3231 RTC, PCA9685 PWM and MCP4728 DAC module. But I urge you to avoid overloading the tiny voltage converter of your ESP board, which may otherwise end up in smoke! With the MCP4728 putting out a little above 2 V (2.048 V to be exact) and the PCA9685 generating a PWM amplitude of only about 2.5 V, additional higher voltages, which a DC-DC boost converter can provide, may be needed by both op-amps to control DC pumps and drive SSRs reliably.

Breadboard
No matter, even with such a small step-up converter integrated to supply the op-amps with 15 Vcc, current is expected to be less than 200 mA, way below the 500 mA allowed by USB 2.0 specifications. So a computer connected with the ESP board via a USB cable can be a sufficient power source. But the power supply to choose particularly depends on the equipment that has to be driven. For example a Fostek SSR-40DA used to interface a heater draws additional 40 mA. And with PWM driven high power LEDs you always have to decide on a more expensive power supply unit depending on number, voltage and current of the respective LEDs to be chained.

Within less that an hour the core system with a few LEDs indicating PWM output levels and the microcontroller attached to a common USB power adapter or your computer's USB port is built on a breadboard, ready for your first experiments.

Later on with everything working fine it's time to connect your terminal devices like PWM-driven light sources, voltage-controlled pumps or relay-switched heaters, coolers and feeders etc. with the controller unit. That's when you have to use a voltmeter to adjust amplification of all relevant op-amp outputs according to the needs of the attached DC-controlled pumps and solid-state relays.

Here's the interface parameter listing of a few DC-controllable aquarium pumps, most of which I found on the Internet:

Manufacturer Type Mode Voltage
Jebao / Jecod WP pumps
DC pumps
DC 0 .. 5 V
SW pumps
Coral Box DCA pumps
DC 0 .. 10 V
Maxspect / IceCap IceCap Gyre Interface Module DC 0 .. 10 V
Reef Octopus VarioS, Pulse 2, Pulse 4 DC 0 .. 10 V
Sicce XStream-E DC 0 .. 10 V
Speedwave DC pumps DC 0 .. 5 V
Tunze Turbelle Nanostream Electronic
    6040, 6055, 6095
Turbelle Stream Electronic
    6105, 6155, 6255,
    6150 (Stream 3/3+)
DC 0 .. 10 V
Waveline DC6000, DC12000, DC20000
WavePuck, WavePuck II
DC 0 .. 10 V

I have to make clear, that not all of these data are verified, which is why I urge you to do your own voltage metering with the devices you own before attaching them to the AquariOS system.

Printed Case Total Printed Case Panel
Though I run a breadboard-mounted AquariOS controller reliably for years now, it's better to keep the sensitive electronics protected within a case. You'll soon find here .STL-files to print a wall-mount home for your AquariOS controller built upon a 10 x 16 cm PCB.

Apart from access to the ESP's USB-connector and a cut-out for the DC power jack it has holes in the base plate ready for lots of screw-in mini-XLR sockets to connect all your devices. The display panel holds a 2.8" TFT touch screen on the left. In the middle there are 3 stacked 10-segment bargraph displays, masked for light = 8 * blue, pump = 8 * green and temperature = 4 * red. Below two 5 mm LEDs, the left one white as a pulsating sample heartbeat indicator, the right one as a power indicator. On the right the (red) feed button, finally the power switch and below the WiFi mode toggle (open = Station mode, closed = Access Point mode).

Down Up Top Firmware

In order to upload the AquariOS firmware to the ESP32 processor a USB connection with your Windows PC has to be established, managed by a CP210x USB to UART Bridge VCP Driver, which you may have to install. With the cable connection in place open the Windows Device Manager. There needs to be a 'Silicon Labs CP210x USB to UART Bridge (COMx)' entry at the 'Ports (COM & LPT)' section. Memorize its COM port number, which you later have to select within the ESP32 Flash Tool.

But at first I'd suggest to test communication. As development boards usually are preflashed with a program that sends some text through the USB interface, start a terminal program like Tera Term, set its serial port parameters to 8 data bits / no parity / 1 stop bit (8N1), no flow control, with 115200 baud, and try to connect with the ESP's COM port. If you receive weird characters vary baudrate until readable text is coming in.

Here's what one of my boards transmits OOTB:
ets Jun  8 2016 00:22:57

rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0018,len:4
load:0x3fff001c,len:1324
load:0x40078000,len:7788
ho 0 tail 12 room 4
load:0x40080400,len:6448
entry 0x400806e8
scan start
scan done
5 networks found
1: Edelweiss (-61)*
2: Vodafone Hotspot (-85)
3: Vodafone Homespot (-85)
4: KabelBox-985B (-86)*
5: EZCast2-C9A2E7F6 (-94)*

Initializing SD card...initialization failed!

ESP32 Flash Tool
Now, as a stable connection with your ESP board is established, download the latest AquariOS 1.4.2 Firmware archive (with its PGP Signature file to check authenticity) from this site and extract the folder it contains to some place. Information on firmware changes can be found in the AquariOS History file.

Then download the Flash Download Tool from Espressif's ESP32 Tools Download page and also extract its contents. Start the 'flash_download_tool_3.9.2.exe' application, select ChipType 'ESP32' / WorkMode 'develop' and click the 'OK' button. In the window that now opens select files and set parameters according to the picture on the right. Finally - with the terminal connection closed - click 'START' to initiate the firmware upload.

Attention! With firmware versions prior to 1.1.6 AquariOS.bin started at 0x10000. Due to an extension of the NVS partition, that offset then was increased to 0x20000.

After flashing has finished reconnect your terminal program and press the 'EN' resp. 'RESET' button next to your ESP's USB connector to reset the controller and run the program.

As long as memory blocks aren't moved, preexisting settings survive firmware updates. Nevertheless it's good practice to backup your valuable configuration data to an external device from time to time, particularly after more extensive modifications.

Protocols of the optional erasing procedure as well as the flashing and boot process are listed below.

Erasing and flashing log:
*************************** START ****************************

test offset :  4096 0x1000
case ok
test offset :  32768 0x8000
case ok
test offset :  131072 0x20000
case ok
.
Uploading stub...
Running stub...
Stub running...
FLASH_CRYPT_CNT 0
ABS_DONE_0 False

*************************** END ****************************


*************************** START ****************************

test offset :  4096 0x1000
case ok
test offset :  32768 0x8000
case ok
test offset :  131072 0x20000
case ok
......
Uploading stub...
Running stub...
Stub running...
FLASH_CRYPT_CNT 0
ABS_DONE_0 False
Compressed 25728 bytes to 15797...
Compressed 3072 bytes to 106...
Compressed 1323184 bytes to 783044...

 is stub and send flash finish

*************************** END ****************************

Boot log (bare unconfigured board):
ets Jun  8 2016 00:22:57

rst:0x1 (POWERON_RESET),boot:0x3f (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:7056
load:0x40078000,len:14832
load:0x40080400,len:3748
entry 0x40080678
I (27) boot: ESP-IDF v4.3-dirty 2nd stage bootloader
I (27) boot: compile time 19:50:59
I (27) boot: chip revision: 1
I (60) boot.esp32: SPI Speed      : 40MHz
I (60) boot.esp32: SPI Mode       : DIO
I (60) boot.esp32: SPI Flash Size : 4MB
I (62) boot: Enabling RNG early entropy source...
I (68) boot: Partition Table:
I (71) boot: ## Label            Usage          Type ST Offset   Length
I (79) boot:  0 nvs              WiFi data        01 02 00009000 00016000
I (86) boot:  1 phy_init         RF data          01 01 0001f000 00001000
I (93) boot:  2 factory          factory app      00 00 00020000 001e0000
I (101) boot: End of partition table
I (105) esp_image: segment 0: paddr=00020020 vaddr=3f400020 size=55a9ch (350876) map
I (257) esp_image: segment 1: paddr=00075ac4 vaddr=3ffb0000 size=08698h ( 34456) load
I (273) esp_image: segment 2: paddr=0007e164 vaddr=40080000 size=01eb4h (  7860) load
I (277) esp_image: segment 3: paddr=00080020 vaddr=400d0020 size=c6a4ch (813644) map
I (612) esp_image: segment 4: paddr=00146a74 vaddr=40081eb4 size=1c5f4h (116212) load
I (672) esp_image: segment 5: paddr=00163070 vaddr=50000000 size=00010h (    16) load
I (697) boot: Loaded app from partition at offset 0x20000
I (697) boot: Disabling RNG early entropy source...
I (709) psram: This chip is ESP32-D0WD
I (709) spiram: Found 32MBit SPI RAM device
I (709) spiram: SPI RAM mode: flash 40m sram 40m
I (714) spiram: PSRAM initialized, cache is in low/high (2-core) mode.
I (721) cpu_start: Pro cpu up.
I (725) cpu_start: Starting app cpu, entry point is 0x400818e0
I (0) cpu_start: App cpu up.
I (1618) spiram: SPI SRAM memory test OK
I (1626) cpu_start: Pro cpu start user code
I (1626) cpu_start: cpu freq: 160000000
I (1626) cpu_start: Application information:
I (1629) cpu_start: Project name:     AquariOS
I (1634) cpu_start: App version:      1
I (1638) cpu_start: Compile time:     Nov 20 2021 20:05:17
I (1644) cpu_start: ELF file SHA256:  35c6755090a3bfe0...
I (1651) cpu_start: ESP-IDF:          v4.3-dirty
I (1656) heap_init: Initializing. RAM available for dynamic allocation:
I (1663) heap_init: At 3FFAE6E0 len 00001920 (6 KiB): DRAM
I (1669) heap_init: At 3FFBFAD8 len 00020528 (129 KiB): DRAM
I (1676) heap_init: At 3FFE0440 len 00003AE0 (14 KiB): D/IRAM
I (1682) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM
I (1689) heap_init: At 4009E4A8 len 00001B58 (6 KiB): IRAM
I (1695) spiram: Adding pool of 4096K of external SPI memory to heap allocator
I (1703) spi_flash: detected chip: gd
I (1707) spi_flash: flash io: dio
I (1713) cpu_start: Starting scheduler on PRO CPU.
I (0) cpu_start: Starting scheduler on APP CPU.
I (1722) spiram: Reserving pool of 32K of internal memory for DMA/internal allocations

********************************
* AquariOS Aquarium Controller *
*  Version 1.3.0 - 2021-11-20  *
*  (c) Christian Danner, 2021  *
********************************

ESP32 IDF version: v4.3-dirty
ESP Chip Hardware: Model ESP32 * Revision 1 * 2 Cores * WiFi(bgn)|BT|BLE * 4 MB external SPI Flash Memory
Available RAM 4395719 bytes
Main thread running on core 0

I (1812) LIB: Opening Non-Volatile Storage (NVS) ...
I (1822) LIB: NVS opened
NV-RAM Statistics: NamespaceCount = 1, UsedEntries = 1, FreeEntries = 2771, TotalEntries = 2772
NV-RAM Statistics (namespace 'storage'): UsedEntryCount = 1
I (1832) LIB: NVS closed
I (1832) LIB: Opening Non-Volatile Storage (NVS) ...
I (1832) LIB: NVS opened
I (1842) LIB: NVS key 'cfg_tps_addr_a' not found, returning 0x0000000000000000
I (1852) LIB: NVS closed
I (1852) LIB: Opening Non-Volatile Storage (NVS) ...
I (1852) LIB: NVS opened
I (1862) LIB: NVS key 'cfg_tps_addr_b' not found, returning 0x0000000000000000
I (1872) LIB: NVS closed
I (1872) LIB: Opening Non-Volatile Storage (NVS) ...
I (1872) LIB: NVS opened
I (1882) LIB: NVS key 'cfg_tps_addr_c' not found, returning 0x0000000000000000
I (1892) LIB: NVS closed
I (1892) LIB: Opening Non-Volatile Storage (NVS) ...
I (1892) LIB: NVS opened
I (1902) LIB: NVS key 'cfg_tps_addr_d' not found, returning 0x0000000000000000
I (1912) LIB: NVS closed
I (1912) LIB: Opening Non-Volatile Storage (NVS) ...
I (1912) LIB: NVS opened
I (1922) LIB: NVS key 'cfg_dsp_devi' not found, returning 0x03
I (1922) LIB: NVS closed
I (1932) LIB: Opening Non-Volatile Storage (NVS) ...
I (1932) LIB: NVS opened
I (1942) LIB: NVS key 'cfg_i2c_rtc' not found, returning 0x00
I (1942) LIB: NVS closed
I (1952) LIB: Opening Non-Volatile Storage (NVS) ...
I (1952) LIB: NVS opened
I (1952) LIB: NVS key 'cfg_i2c_pwm' not found, returning 0x00
I (1962) LIB: NVS closed
I (1962) LIB: Opening Non-Volatile Storage (NVS) ...
I (1972) LIB: NVS opened
I (1972) LIB: NVS key 'cfg_i2c_dac' not found, returning 0x00
I (1982) LIB: NVS closed
I (1982) LIB: Opening Non-Volatile Storage (NVS) ...
I (1992) LIB: NVS opened
I (1992) LIB: NVS key 'cfg_fed_dura' not found, returning 0x0708
I (2002) LIB: NVS closed
I (2002) LIB: Opening Non-Volatile Storage (NVS) ...
I (2012) LIB: NVS opened
I (2012) LIB: NVS key 'cfg_ttd_ival' not found, returning 0x0032
I (2022) LIB: NVS closed
I (2022) LIB: Opening Non-Volatile Storage (NVS) ...
I (2032) LIB: NVS opened
I (2032) LIB: NVS key 'cfg_mqt_port' not found, returning 0x075b
I (2042) LIB: NVS closed
I (2042) LIB: Opening Non-Volatile Storage (NVS) ...
I (2042) LIB: NVS opened
I (2052) LIB: NVS key 'cfg_mqt_ival' not found, returning 0x012c
I (2052) LIB: NVS closed
Function 'esp_event_loop_create_default' ... Done: 0
I (2062) I2CDEVS: I2cInterfaceInit ...
I (2072) I2CDEVS: i2c_master_init ...
I (2072) I2CDEVS: i2c_master_init - i2c_param_config ...
I (2082) I2CDEVS: ... i2c_master_init - i2c_param_config succeeded
I (2082) I2CDEVS: i2c_master_init - i2c_driver_install ...
I (2092) I2CDEVS: i2c_driver_install succeeded
I (2102) I2CDEVS: I2C Semaphore set
I (2102) I2CDEVS: ... i2c_master_init - i2c_driver_install
I (2112) I2CDEVS: ... i2c_master_init
I (2112) I2CDEVS: ... I2cInterfaceInit
I (2112) AquariOS: Scanning I2C bus ...
********************* I2C-Scanner *********************
*      0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f *
* 00: ++ ++ ++ -- -- -- -- -- -- -- -- -- -- -- -- -- *
* 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- *
* 20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- *
* 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- *
* 40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- *
* 50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- *
* 60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- *
* 70: -- -- -- -- -- -- -- -- ++ ++ ++ ++ ++ ++ ++ ++ *
*******************************************************
I (2192) AquariOS: ... I2C bus scanned
I (2202) AquariOS: LCD Display Initialization
I (2202) LIB: Opening Non-Volatile Storage (NVS) ...
I (2202) AquariOS: Display Init (LOB) ...
SPI: Display device added to SPI bus (2)
I (2212) LIB: NVS opened
SPI: Display device attached, speed=40000000, bus uses native pins
SPI: Touchscreen device added to SPI bus (2)
I (2222) LIB: NVS key 'cfg_dat_tzon' not found, returning 'CET-1CEST,M3.5.0,M10.5.0/3'
SPI: Touchscreen device attached, speed=2500000
SPI: TFT Display Init ...
I (2242) LIB: NVS closed
I (2202) AquariOS: Initializing Pump interface
Timezone set to 'CET-1CEST,M3.5.0,M10.5.0/3'
Memo '01:00:00 Init Pump Interface ...' queued
I (2262) AquariOS: I2C RTC not present
I (2262) PA: Pump Semaphore created
System time not yet initialized
I (2272) PP: Pump Controller Semaphore set
Setting system time manually to 2000/01/01-00:00:00
I (2282) LIB: Opening Non-Volatile Storage (NVS) ...
System time Sat Jan  1 08:00:00 2000
I (2292) LIB: NVS opened
I (2292) LIB: Opening Non-Volatile Storage (NVS) ...
I (2292) PP: ppFlash2Aut: Reading 72 bytes of aut flash blob data from key 'pp_aut'
I (2302) LIB: NVS opened
I (2312) LIB: Error (0x1102) reading data of NVS key 'pp_aut'
I (2312) LIB: NVS key 'cfg_dat_inet' not found, returning 0x01
I (2322) PP: ppFlash2Aut: Error reading 72 bytes of aut flash blob data from key 'pp_aut', 72 bytes available
I (2322) LIB: NVS closed
I (2332) LIB: NVS closed
I (2342) PP: Error reading Pump Program parameters from NV-RAM
I (2352) PS: Pump Shape Semaphore set
I (2352) LIB: Opening Non-Volatile Storage (NVS) ...
I (2362) LIB: NVS opened
I (2362) PS: psFlash2Aut: Reading 1125 bytes of aut flash blob data from key 'ps_aut'
I (2372) LIB: Error (0x1102) reading data of NVS key 'ps_aut'
I (2372) PS: psFlash2Aut: Error reading 1125 bytes of aut flash blob data from key 'ps_aut', 1125 bytes available
I (2392) LIB: NVS key 'ps_nam_a' not found, returning ''
I (2392) LIB: NVS key 'ps_nam_b' not found, returning ''
I (2402) LIB: NVS key 'ps_nam_c' not found, returning ''
I (2402) LIB: NVS key 'ps_nam_d' not found, returning ''
I (2412) LIB: NVS key 'ps_nam_e' not found, returning ''
I (2422) LIB: NVS key 'ps_nam_f' not found, returning ''
I (2422) LIB: NVS key 'ps_nam_g' not found, returning ''
I (2432) LIB: NVS key 'ps_nam_h' not found, returning ''
I (2432) LIB: NVS key 'ps_nam_i' not found, returning ''
I (2442) LIB: NVS key 'ps_nam_j' not found, returning ''
I (2452) LIB: NVS key 'ps_nam_k' not found, returning ''
I (2452) LIB: NVS key 'ps_nam_l' not found, returning ''
I (2462) LIB: NVS key 'ps_nam_m' not found, returning ''
I (2462) LIB: NVS key 'ps_nam_n' not found, returning ''
I (2472) LIB: NVS key 'ps_nam_o' not found, returning ''
I (2482) LIB: NVS closed
I (2482) PS: Error reading Pump Shape Automation parameters from NV-RAM
I (2492) LIB: Opening Non-Volatile Storage (NVS) ...
I (2492) LIB: NVS opened
I (2502) PA: paFlash2Aut: Reading 1500 bytes of aut flash blob data from key 'pa_aut'
I (2502) LIB: Error (0x1102) reading data of NVS key 'pa_aut'
I (2512) PA: paFlash2Aut: Error reading 1500 bytes of aut flash blob data from key 'pa_aut', 1500 bytes available
I (2522) LIB: NVS key 'pa_nam_a' not found, returning ''
I (2532) LIB: NVS key 'pa_nam_b' not found, returning ''
I (2532) LIB: NVS key 'pa_nam_c' not found, returning ''
I (2542) LIB: NVS key 'pa_nam_d' not found, returning ''
I (2542) LIB: NVS key 'pa_nam_e' not found, returning ''
I (2552) LIB: NVS key 'pa_nam_f' not found, returning ''
I (2562) LIB: NVS key 'pa_nam_g' not found, returning ''
I (2562) LIB: NVS key 'pa_nam_h' not found, returning ''
I (2572) LIB: NVS key 'pa_nam_i' not found, returning ''
I (2572) LIB: NVS key 'pa_nam_j' not found, returning ''
I (2582) LIB: NVS closed
I (2582) PA: Error reading Temperature Automation parameters from NV-RAM
I (2592) AquariOS: Initializing Light interface
Memo '08:00:00 Init Light Interface ...' queued
I (2602) LA: Light Semaphore created
I (2602) LP: Light Program Semaphore set
I (2612) LIB: Opening Non-Volatile Storage (NVS) ...
I (2622) LIB: NVS opened
I (2622) LP: lpFlash2Aut: Reading 176 bytes of aut flash blob data from key 'lp_aut'
I (2632) LIB: Error (0x1102) reading data of NVS key 'lp_aut'
I (2632) LP: lpFlash2Aut: Error reading 176 bytes of aut flash blob data from key 'lp_aut', 176 bytes available
I (2642) LIB: NVS closed
I (2652) LP: Error reading Light Program parameters from NV-RAM
I (2652) LS: Light Season Semaphore set
I (2662) LIB: Opening Non-Volatile Storage (NVS) ...
I (2662) LIB: NVS opened
I (2672) LS: lsFlash2Aut: Reading 750 bytes of aut flash blob data from key 'ls_aut'
I (2682) LIB: Error (0x1102) reading data of NVS key 'ls_aut'
I (2682) LS: lsFlash2Aut: Error reading 750 bytes of aut flash blob data from key 'ls_aut', 750 bytes available
I (2692) LIB: NVS key 'ls_nam_a' not found, returning ''
I (2702) LIB: NVS key 'ls_nam_b' not found, returning ''
I (2702) LIB: NVS key 'ls_nam_c' not found, returning ''
I (2712) LIB: NVS key 'ls_nam_d' not found, returning ''
I (2722) LIB: NVS key 'ls_nam_e' not found, returning ''
I (2722) LIB: NVS key 'ls_nam_f' not found, returning ''
I (2732) LIB: NVS key 'ls_nam_g' not found, returning ''
I (2732) LIB: NVS key 'ls_nam_h' not found, returning ''
I (2742) LIB: NVS key 'ls_nam_i' not found, returning ''
I (2752) LIB: NVS key 'ls_nam_j' not found, returning ''
I (2752) LIB: NVS closed
I (2762) LS: Error reading Light Season parameters from NV-RAM
I (2762) LIB: Opening Non-Volatile Storage (NVS) ...
I (2772) LIB: NVS opened
I (2772) LA: laFlash2Aut: Reading 1000 bytes of aut flash blob data from key 'la_aut_dat'
I (2782) LIB: Error (0x1102) reading data of NVS key 'la_aut_dat'
I (2792) LA: laFlash2Aut: Error reading 1000 bytes of aut flash blob data from key 'la_aut_dat', 1000 bytes available
I (2802) LIB: NVS key 'la_nam_a' not found, returning ''
I (2802) LIB: NVS key 'la_nam_b' not found, returning ''
SPI: ... TFT Display Init done
I (2862) LIB: NVS key 'la_nam_c' not found, returning ''
I (2862) LIB: NVS key 'la_nam_d' not found, returning ''
I (2862) LIB: NVS key 'la_nam_e' not found, returning ''
SPI: Maximum display RAM read speed = 1000000
SPI: Speed changed to 26666666
I (2882) LIB: NVS key 'la_nam_f' not found, returning ''
I (2882) LIB: NVS key 'la_nam_g' not found, returning ''
I (2902) LIB: NVS key 'la_nam_h' not found, returning ''
I (2902) LIB: NVS key 'la_nam_i' not found, returning ''
I (2902) LIB: NVS key 'la_nam_j' not found, returning ''
I (2902) LIB: NVS closed
I (3152) AquariOS: Display Setup (None) ...
I (3152) LA: Error reading Light Automation parameters from NV-RAM
I (3152) AquariOS: Scanning for WiFi Access Points ...
Memo '08:00:00 Scan Wifi APs ...' queued
I (3162) AquariOS: ******** NetIF object created ********
I (3182) wifi:wifi driver task: 3ffda244, prio:23, stack:3584, core=0
I (3182) system_api: Base MAC address is not set
I (3182) system_api: read default base MAC address from EFUSE
I (3192) wifi:wifi firmware version: c7d0450
I (3192) wifi:wifi certification version: v7.0
I (3192) wifi:config NVS flash: enabled
I (3202) wifi:config nano formating: disabled
I (3202) wifi:Init data frame dynamic rx buffer num: 32
I (3212) wifi:Init management frame dynamic rx buffer num: 32
I (3212) wifi:Init management short buffer num: 32
I (3222) wifi:Init static tx buffer num: 16
I (3222) wifi:Init tx cache buffer num: 32
I (3222) wifi:Init static rx buffer size: 1600
I (3232) wifi:Init static rx buffer num: 10
I (3232) wifi:Init dynamic rx buffer num: 32
I (3242) wifi_init: rx ba win: 6
I (3242) wifi_init: tcpip mbox: 32
I (3242) wifi_init: udp mbox: 6
I (3252) wifi_init: tcp mbox: 6
I (3252) wifi_init: tcp tx win: 5744
I (3262) wifi_init: tcp rx win: 5744
I (3262) wifi_init: tcp mss: 1440
I (3262) wifi_init: WiFi/LWIP prefer SPIRAM
I (3272) wifi_init: WiFi IRAM OP enabled
I (3272) wifi_init: WiFi RX IRAM OP enabled
I (3282) AquariOS: ******** WiFi Init done ********
I (3292) AquariOS: ******** WiFi Mode set ********
I (3292) phy_init: phy_version 4670,719f9f6,Feb 18 2021,17:07:07
W (3302) phy_init: failed to load RF calibration data (0x1102), falling back to full calibration
I (3462) wifi:mode : sta (30:ae:a4:43:3c:3c)
I (3472) wifi:enable tsf
I (3472) AquariOS: ******** WiFi started ********
I (3472) AquariOS: ******** WiFi Scan started ********
I (5522) AquariOS: ******** Event Handler ... ********
I (5522) AquariOS: Event WIFI_EVENT_SCAN_DONE
******************** WiFi-Scanner ************************************
**** >>>>>>>  1 Access Point found  <<<<<<<
**** SSID                               RSSI  AUTH-MODE
**** Edelweiss                           -68  WIFI_AUTH_WPA2_PSK
**********************************************************************
Memo '08:00:03 Scan Wifi: 1 AP found' queued
I (5552) AquariOS: ******** ... Event Handler ********
I (5572) AquariOS: ******** WiFi Scan done ********
I (5572) wifi:flush txq
I (5572) wifi:stop sw txq
I (5572) wifi:lmac stop hw txq
I (5572) AquariOS: ******** WiFi stopped ********
I (5582) wifi:Deinit lldesc rx mblock:10
I (5592) AquariOS: ******** WiFi Deinit done ********
I (5592) AquariOS: ******** NetIF object destroyed ********
Memo '08:00:03 Start Wifi AP mode ...' queued
I (5602) AquariOS: Starting WiFi in Access Point Mode ...
Memo '08:00:03 Wifi AP Start ...' queued
MAC: 0xACACACACACAC -> Array 'ac:ac:ac:ac:ac:ac'
Starting WiFi ...
I (5632) wifi:wifi driver task: 3ffda3f8, prio:23, stack:3584, core=0
I (5632) wifi:wifi firmware version: c7d0450
I (5632) wifi:wifi certification version: v7.0
I (5632) wifi:config NVS flash: enabled
I (5632) wifi:config nano formating: disabled
I (5642) wifi:Init data frame dynamic rx buffer num: 32
I (5642) wifi:Init management frame dynamic rx buffer num: 32
I (5652) wifi:Init management short buffer num: 32
I (5652) wifi:Init static tx buffer num: 16
I (5662) wifi:Init tx cache buffer num: 32
I (5662) wifi:Init static rx buffer size: 1600
I (5662) wifi:Init static rx buffer num: 10
I (5672) wifi:Init dynamic rx buffer num: 32
I (5672) wifi_init: rx ba win: 6
I (5682) wifi_init: tcpip mbox: 32
I (5682) wifi_init: udp mbox: 6
I (5682) wifi_init: tcp mbox: 6
I (5692) wifi_init: tcp tx win: 5744
I (5692) wifi_init: tcp rx win: 5744
I (5702) wifi_init: tcp mss: 1440
I (5702) wifi_init: WiFi/LWIP prefer SPIRAM
I (5702) wifi_init: WiFi IRAM OP enabled
I (5712) wifi_init: WiFi RX IRAM OP enabled
Function 'esp_wifi_init' ... Done: 0
Function 'esp_wifi_set_storage' ... Done: 0
Function 'esp_wifi_set_mode' ... Done: 0
Function 'esp_wifi_set_mac' ... Done: 0
I (6822) AquariOS: WiFi AP Host Name set
I (6822) wifi:mode : softAP (ac:ac:ac:ac:ac:ac)
I (6832) wifi:Total power save buffer number: 8
I (6832) wifi:Init max length of beacon: 752/752
I (6832) wifi:Init max length of beacon: 752/752
I (6842) AquariOS: ******** Event Handler ... ********
I (6842) AquariOS: Event WIFI_EVENT_AP_START
Memo '08:00:04 Wifi AP started' queued
I (6852) AquariOS: Creating TCP Server task (tcp_server) ...
I (6852) AquariOS: ... Creation of TCP Server task (tcp_server) succeeded
I (6852) AquariOS: SSL server context create ...
I (6862) AquariOS: Creating MQTT Client task (mqtt_client) ...
I (6872) AquariOS: ... SSL server context created
I (6872) AquariOS: ... Creation of MQTT Client task (mqtt_client) succeeded
I (6882) LIB: Opening Non-Volatile Storage (NVS) ...
I (6882) AquariOS: ******** ... Event Handler ********
I (6882) AquariOS: task_mqt_client: Starting task ...
I (6892) LIB: NVS opened
Memo '08:00:04 Wifi AP Start done' queued
I (6912) LIB: NVS key 'cfg_sta_cert' not found, returning ''
I (6912) LIB: Opening Non-Volatile Storage (NVS) ...
I (6922) LIB: NVS closed
I (6912) AquariOS: ... WiFi started in Access Point Mode
I (6922) AquariOS: SSL server context - Set Server Certificate ...
I (6922) LIB: NVS opened
I (6942) AquariOS: ... SSL server context - Server Certificate NOT set
Memo '08:00:04 Wifi AP mode started' queued
I (6952) AquariOS: SSL server context - Set Server Certificate ...
I (6952) LIB: NVS key 'cfg_mqt_burl' not found, returning '192.168.3.101'
I (6962) AquariOS: ... SSL server context - Server Certificate set
I (6972) LIB: NVS closed
USETASKNOTIFICATIONS set!
I (6982) LIB: Opening Non-Volatile Storage (NVS) ...
I (6982) AquariOS: SSL server context - Set Server Private Key ...
I (6992) LIB: NVS opened
I (6982) TA: Temperature Semaphore created
I (6992) LIB: NVS key 'cfg_mqt_user' not found, returning ''
I (7002) AquariOS: ... SSL server context: Server Private Key set
I (7012) LIB: NVS closed
I (7002) TD: Temperature Device Semaphore set
I (7022) LIB: Opening Non-Volatile Storage (NVS) ...
I (7022) AquariOS: ... SSL server certificate & key set from ROM
I (7032) LIB: NVS opened
I (7022) LIB: Opening Non-Volatile Storage (NVS) ...
I (7042) LIB: NVS key 'cfg_mqt_pwrd' not found, returning ''
I (7042) AquariOS: SSL server create socket ...
I (7042) LIB: NVS opened
I (7052) LIB: NVS closed
I (7052) AquariOS: ... SSL server socket created
I (7062) LIB: NVS key 'td_addr_a' not found, returning 0x0000000000000000
I (7062) LIB: Opening Non-Volatile Storage (NVS) ...
I (7062) AquariOS: SSL server socket bind ...
I (7072) LIB: NVS key 'td_bias_a' not found, returning 0.000000
I (7082) LIB: NVS opened
I (7082) AquariOS: ... SSL server socket bound to port 443
I (7092) LIB: NVS key 'td_slop_a' not found, returning 0.000000
I (7102) AquariOS: SSL server socket listen ...
I (7102) LIB: NVS key 'cfg_mqt_clid' not found, returning 'aquarios'
I (7112) LIB: NVS key 'td_addr_b' not found, returning 0x0000000000000000
I (7122) LIB: NVS closed
I (7122) AquariOS: ... Listening to SSL server socket
I (7122) LIB: NVS key 'td_bias_b' not found, returning 0.000000
Memo '08:00:04 Starting MQTT Client ...' queued
I (7132) AquariOS: SSL server create ...
I (7142) LIB: NVS key 'td_slop_b' not found, returning 0.000000
I (7152) AquariOS: Starting MQTT Client Init ...
I (7152) AquariOS: ... SSL server created
I (7162) LIB: NVS key 'td_addr_c' not found, returning 0x0000000000000000
I (7172) AquariOS: ########## Available RAM 4188187 bytes ##########
I (7172) AquariOS: Starting MQTT Client (url 'mqtt://192.168.3.101' - port 1883 - id 'aquarios' - user '' - pwrd '') ...
I (7172) LIB: NVS key 'td_bias_c' not found, returning 0.000000
I (7192) AquariOS: SSL server socket ready to accept client ... ################################################################################
I (7192) AquariOS: MQTT Client started
I (7202) LIB: NVS key 'td_slop_c' not found, returning 0.000000
Memo '08:00:04 MQTT Client started' queued
I (7222) LIB: NVS key 'td_addr_d' not found, returning 0x0000000000000000
I (7232) AquariOS: task_mqt_client: Deleting task ...
I (7232) LIB: NVS key 'td_bias_d' not found, returning 0.000000
I (7192) LIB: Opening Non-Volatile Storage (NVS) ...
I (7252) LIB: NVS key 'td_slop_d' not found, returning 0.000000
I (7252) LIB: NVS opened
I (6982) AquariOS: Starting MQTT Client Publish task ...
I (7262) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (7262) LIB: NVS key 'td_addr_e' not found, returning 0x0000000000000000
I (7282) LIB: NVS closed
I (7292) LIB: NVS key 'td_bias_e' not found, returning 0.000000
I (7292) AquariOS: MQTT Event Handler: MQTT_EVENT_BEFORE_CONNECT, msg_id = 65087
I (7302) LIB: NVS key 'td_slop_e' not found, returning 0.000000
I (7312) LIB: NVS key 'td_addr_f' not found, returning 0x0000000000000000
I (7282) LIB: Opening Non-Volatile Storage (NVS) ...
I (7322) LIB: NVS key 'td_bias_f' not found, returning 0.000000
I (6982) AquariOS: Starting MQTT Client Subscribe task ...
I (7332) LIB: NVS key 'td_slop_f' not found, returning 0.000000
I (7322) LIB: NVS opened
I (7342) LIB: NVS key 'td_addr_g' not found, returning 0x0000000000000000
I (7332) LIB: Opening Non-Volatile Storage (NVS) ...
I (7352) LIB: NVS key 'td_bias_g' not found, returning 0.000000
I (7342) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (7362) LIB: NVS key 'td_slop_g' not found, returning 0.000000
I (7362) LIB: NVS opened
I (7382) LIB: NVS key 'td_addr_h' not found, returning 0x0000000000000000
I (7372) LIB: NVS closed
I (7392) LIB: NVS key 'td_bias_h' not found, returning 0.000000
I (7382) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (7402) LIB: NVS key 'td_slop_h' not found, returning 0.000000
I (7412) LIB: NVS closed
I (7412) TD: tdFlash2Params: Flash data read
I (7422) LIB: NVS closed
I (7422) TD: Temperature Device Parameters read from NV-RAM
I (7432) TP: Temperature Program Semaphore set
I (7432) LIB: Opening Non-Volatile Storage (NVS) ...
I (7442) LIB: NVS opened
I (7442) TP: tpFlash2Aut: Reading 88 bytes of aut flash blob data from key 'tp_aut'
I (7452) LIB: Error (0x1102) reading data of NVS key 'tp_aut'
I (7462) TP: tpFlash2Aut: Error reading 88 bytes of aut flash blob data from key 'tp_aut', 88 bytes available
I (7472) LIB: NVS closed
I (7472) TP: Error reading Temperature Program parameters from NV-RAM
I (7482) TS: Temperature Season Semaphore set
I (7482) LIB: Opening Non-Volatile Storage (NVS) ...
I (7492) LIB: NVS opened
I (7492) TS: tsFlash2Aut: Reading 1000 bytes of aut flash blob data from key 'ts_aut'
I (7502) LIB: Error (0x1102) reading data of NVS key 'ts_aut'
I (7512) TS: tsFlash2Aut: Error reading 1000 bytes of aut flash blob data from key 'ts_aut', 1000 bytes available
I (7522) LIB: NVS key 'ts_nam_a' not found, returning ''
I (7522) LIB: NVS key 'ts_nam_b' not found, returning ''
I (7532) LIB: NVS key 'ts_nam_c' not found, returning ''
I (7542) LIB: NVS key 'ts_nam_d' not found, returning ''
I (7542) LIB: NVS key 'ts_nam_e' not found, returning ''
I (7552) LIB: NVS key 'ts_nam_f' not found, returning ''
I (7552) LIB: NVS key 'ts_nam_g' not found, returning ''
I (7562) LIB: NVS key 'ts_nam_h' not found, returning ''
I (7572) LIB: NVS key 'ts_nam_i' not found, returning ''
I (7572) LIB: NVS key 'ts_nam_j' not found, returning ''
I (7582) LIB: NVS closed
I (7582) TS: Error reading Temperature Season parameters from NV-RAM
I (7592) LIB: Opening Non-Volatile Storage (NVS) ...
I (7592) LIB: NVS opened
I (7602) TA: taFlash2Aut: Reading 600 bytes of aut flash blob data from key 'ta_aut'
I (7612) LIB: Error (0x1102) reading data of NVS key 'ta_aut'
I (7612) TA: taFlash2Aut: Error reading 600 bytes of aut flash blob data from key 'ta_aut', 600 bytes available
I (7622) LIB: NVS key 'ta_nam_a' not found, returning ''
I (7632) LIB: NVS key 'ta_nam_b' not found, returning ''
I (7642) LIB: NVS key 'ta_nam_c' not found, returning ''
I (7642) LIB: NVS key 'ta_nam_d' not found, returning ''
I (7652) LIB: NVS key 'ta_nam_e' not found, returning ''
I (7652) LIB: NVS key 'ta_nam_f' not found, returning ''
I (7662) LIB: NVS key 'ta_nam_g' not found, returning ''
I (7672) LIB: NVS key 'ta_nam_h' not found, returning ''
I (7672) LIB: NVS key 'ta_nam_i' not found, returning ''
I (7682) LIB: NVS key 'ta_nam_j' not found, returning ''
I (7682) LIB: NVS closed
I (7692) TA: Error reading Temperature Automation parameters from NV-RAM
I (7692) AquariOS: ########## Available RAM 4191427 bytes ##########
Memo '08:00:05 Temp Dev scan ...' queued
ds18b20_scan_devices ...
ds18b20_scan_devices searching pin 21 ...
... ds18b20_scan_devices
I (7712) TD: No DS18B20 temperature devices detected!
Memo '08:00:05 Temp Dev (0) scan done' queued
I (7722) AquariOS: No DS18B20 temperature devices detected!
I (17202) AquariOS: Ticker: Time readjusted
////////////////////////////// Data Type #3 for MQTT Publishing (0) queued ///////////////////////////
Feed Duration data (Data Type 3, Remaining 0 of Total 180) for MQTT Publishing queued
MQT: Publishing Queue received Data Type 3 Data message
E (17312) TRANS_TCP: [sock=55] select() timeout
E (17312) MQTT_CLIENT: Error transport connect
I (17322) LIB: Opening Non-Volatile Storage (NVS) ...
I (17322) LIB: NVS opened
I (17332) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (17332) LIB: NVS closed
I (17342) AquariOS: MQTT Event Handler: MQTT_EVENT_ERROR
I (17342) LIB: Opening Non-Volatile Storage (NVS) ...
I (17352) LIB: NVS opened
I (17352) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (17362) LIB: NVS closed
I (17362) AquariOS: MQTT Event Handler: MQTT_EVENT_DISCONNECTED
MQT: Feed Duration data received
MQT: Feed Duration data (remaining 0 of total 180 [s]) received:
{
        "vers": "1.0",
        "time": 946710015,
        "name": "Feed Duration Remaining [s]",
        "type": "fc",
        "load": {
                "valu": 0,
                "totl": 180
        }
}
W (17392) MQTT_CLIENT: Publish: Losing qos0 data when client not connected
I (17402) AquariOS: Successfully sent MQTT publish message (#0)
I (27372) LIB: Opening Non-Volatile Storage (NVS) ...
I (27372) LIB: NVS opened
I (27372) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (27372) LIB: NVS closed
I (27372) AquariOS: MQTT Event Handler: MQTT_EVENT_BEFORE_CONNECT, msg_id = 65087
E (37392) TRANS_TCP: [sock=55] select() timeout
E (37392) MQTT_CLIENT: Error transport connect
I (37392) LIB: Opening Non-Volatile Storage (NVS) ...
I (37392) LIB: NVS opened
I (37392) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (37402) LIB: NVS closed
I (37412) AquariOS: MQTT Event Handler: MQTT_EVENT_ERROR
I (37412) LIB: Opening Non-Volatile Storage (NVS) ...
I (37422) LIB: NVS opened
I (37422) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (37432) LIB: NVS closed
I (37432) AquariOS: MQTT Event Handler: MQTT_EVENT_DISCONNECTED
I (47442) LIB: Opening Non-Volatile Storage (NVS) ...
I (47442) LIB: NVS opened
I (47442) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (47442) LIB: NVS closed
I (47442) AquariOS: MQTT Event Handler: MQTT_EVENT_BEFORE_CONNECT, msg_id = 65087
E (57462) TRANS_TCP: [sock=55] select() timeout
E (57462) MQTT_CLIENT: Error transport connect
I (57462) LIB: Opening Non-Volatile Storage (NVS) ...
I (57462) LIB: NVS opened
I (57462) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (57472) LIB: NVS closed
I (57482) AquariOS: MQTT Event Handler: MQTT_EVENT_ERROR
I (57482) LIB: Opening Non-Volatile Storage (NVS) ...
I (57492) LIB: NVS opened
I (57492) LIB: NVS key 'cfg_mqt_tpic' not found, returning 'home/aquarios'
I (57502) LIB: NVS closed
I (57502) AquariOS: MQTT Event Handler: MQTT_EVENT_DISCONNECTED
...

Down Up Top Configuration

Information Configuration
The AquariOS device has no buttons to set network parameters directly. Restart it while the WiFi mode switch is closed (or its pin isn't connected yet) and it creates an Access Point (SSID 'AquariOS', passphrase 'W3tW3tW3t') your computer can connect with. Be aware that everybody within reach who has knowledge of that publicly available passphrase is able to log into your AquariOS system! So try to leave the Access Point mode ASAP after entering your router's credentials!

Please consider that the integrated web server cooperates best with the Mozilla Firefox browser. Other web browsers may have issues, e.g. timeout problems due to a slow response by the underpowered ESP32 server hardware.

The AquariOS device's IP address https://192.168.1.1 leads to the 'Info' page holding data about hard- and software status and a button to start a TFT screen dump to your computer.

Either click the 'Config' button or enter https://192.168.1.1/cf directly to get to your AquariOS Controller's Configuration page. Being there enter your router's SSID and passphrase and click 'Set'. You may also override the device's MAC address, which is presented in the usual LSB to MSB order. The least significant bit is always set to '0', the flag for unicast addressing. Enter '000000000000' to use the device's genuine MAC address.

If you intend to use the webserver with an individual HTTPS/SSL certificate, AquariOS accepts files containing a certificate ('-----BEGIN CERTIFICATE----- ... -----END CERTIFICATE-----') with an associated private key ('-----BEGIN RSA PRIVATE KEY----- ... -----END RSA PRIVATE KEY-----') in .PEM format. Use the 'Browse ...' button to select the respective file, then click 'Upload Server Certificate & Key'. With a system restart these changes take effect.

Finally restart AquariOS, now with the WiFi mode button released, to make it connect with your WLAN router in order to get Internet access. When it succeeds and finds a way to one of the many 'pool.ntp.org' NTP servers on the Internet the LCD screen will present you the correct date and time after a few seconds. Apart from the system startup process time gets resynchronized with an NTP server each day at 03:10 and 15:10 local time.

Now set the timezone of your location at 'Date & Time'. Valid text entries for many regions worldwide can be found at the OpenWRT Project website. Click the Timezone database link to get there. In case AquariOS has no Internet access, this is also the place where you can set your local time manually.

It's strongly advisable to attach a battery-powered DS3231 real-time clock (RTC) module to the I²C bus, that keeps track of the time beyond a system reboot, e.g. caused by a power outage, even while there's no Internet connnection.

As already mentioned, AquariOS controls external devices through a 16-channel PWM module (PCA9685) and a 4-channel digital-analog-converter module (MCP4728), and supports up to two analog-to-digital input converter modules (ADS1015), all of which also communicate with the processor through its I²C interface. Those devices' 1-byte standard addresses are 0x68 (DS3231), 0x40 (PCA9685), 0x60 (MCP4728) and 0x48 / 0x49 (ADS1015), to be entered in 2-digit hexadecimal format (like '68', '40', '60', '48' or '49'). Enter '00' to deactivate the respective device.

With a range from 24 up to 1526 Hz you can adapt the PCA9685's output frequency to your devices' needs. And, if activated by entering an I²C address above, for every analog-digital converter you use its type (12 bit ADS1015 or 16 bit ADS1115) has to be set.

At 'Feed Mode' select the time interval [mm:ss] AquariOS remains in Feed Mode after pressing the according button on your device. Below you'll read how to configure light and pumps to run specific feed programs during that period of time.

With DS18B20 OneWire temperature probes attached to your system, select which of them provide the data displayed at the OLED / TFT screen and the web interface's header line. The header line temperature comes from the sensor at 'Address 1'.

Apart from the (adjusted) temperature sensor input the TFT screen can also display the targeted temperature for each of the 4 output ports. At 'Temperature Target Display' you define at which intervals the temperature table switches to that port's setpoint value, for one second at a time, with the background color turning from red (actual value) to blue (target value). An interval of '00:00' suppresses, whereas '00:01' constantly shows target temperatures.

The next paragraph deals with the MQTT configuration, where at least the broker's network address as well as port, and, if required, username and password have to be entered. The 'Publishing Interval' parameter represents the cycle time of temperature publishing, where '00:00' means no publishing at all.

The 'Reset Data Tables' buttons are there to clear the respective parameter tables as a whole, for example to start a new setup from scratch. Accidentally clicking on one of these buttons does no harm, as to activate that section the checkbox in the upper left corner first has to be ticked. Furthermore all tables' contents are still stored in non-volatile memory. Go to that particular page and click 'Save' to make your changes permanent or press 'Load' to restore the original dataset. So feel free to play with pump shapes or other parameters, the starting point is just one click away.

On the other hand, with a 'Factory Reset' the non-volatile memory is completely erased, which means, that apart from table data and probe calibration variables all parameters at the Config page including your network connection credentials have to be reentered. As long as you don't restart the device, you can afterwards repopulate NV-RAM with the table data currently used by the system by clicking the respective 'Save' buttons. But at first you should reenter network access data to avoid later-on having to restart AquariOS in Access Point Mode to get access.

Finally, by clicking the 'Restart' button the device would get rebooted.

Down Up Top Light

Light Automation
AquariOS programming bases on time anchor points within a 24-hour day, each combined with an associated weekday set defining the days that time is valid. At such anchor points you set certain parameters like the illumination power. AquariOS now interpolates the intercurrent values following a direct line between the anchor points and forwards the calculated results to the output channels.

With light programming the 'Automation' table doesn't look very complex, as there only time anchor values (Weekday(s) / Time) along with their corresponding power resp. light intensities have to be entered. Intensities are stored as 1-byte values, which is why numbers are shown in hexadecimal notation (0..255 => 00..FF). Processing is then done with the entered 8-bit power values extended to the 12-bit range (0..4095 / 000..FFF) supported by the PWM / DAC output interfaces, which allows smooth transitions.

Such anchor - value(s) sets are organized in channels, which on the 'Prog'ram page you finally can assign to output devices. Entering a meaningful name on the top right of each channel's page makes life much easier.

In order to copy a data line up to the input line, where it's editable, select the corresponding 'Chan'nel and 'Item' number and click 'Get'. After modifying parameters press 'Set', which rearranges the table, sorted in ascending order based on 'Time' with all inactive entries ('Weekday' set to 'Never') gathered at the bottom. Be aware, that for permanent storage you have to click 'Save' as well, as otherwise your changes are gone at the latest with a system restart.

To create a backup file of your table contents at your computer click 'Download'. You get an hexadecimal ASCII file for a later reupload ('Browse...' / 'Upload').

Light Program
After defining all light intensity curves you can assign the newly created light automation channels to PWM output ports. The port numbers here (1..8) represent port 1..8 of your PWM module.

First specify the type of your lamp, which may either be On/Off or Variable. With 'On/Off', relevant for devices that don't support dimming, all power values above zero result in an 'FF' intensity, which means the output is continuously on, avoiding the rectangular pulse wave signal typical for PWM, which you get with 'Variable'.

With 'Mode' you have the choice to deactivate the entry and exclude it from using the port ('Inactive'), set the port continuously to '00' ('Off') or 'FF' ('On'), specify a fixed intensity directly with the 'Fix Powr' parameter ('Fixed') or select an Automation channel at 'Aut Chan' ('Auto').

Mark 'Feed Auto' to switch to the corresponding 'Feed Chan' Automation Mode while Feed Mode is manually activated.

By checking 'Sun Acti' you activate the (still rudimentary) Sun / Cloud Simulation. There brightness is in- or decreased to the percentage defined at 'Sun Pcnt'. The center of this change is defined by the 'Sun Dist' time interval, starting at midnight repeating all day long. From this center the 'Sun Hold' interval extends to both sides with the 'Sun Ramp' interval added also to the beginning and the end of the simulation period. The example with 'Sun Dist' at '00:15:00.0', 'Sun Ramp' as well as 'Sun Hold' at '00:01:00.0' and 'Sun Pcnt' at 200 results, starting at an intensity of 40, in 40 at 13:13:00.0 continuously increasing up to 80 at 13:14:00.0, held till 13:16:00.0, then decreasing to the initial 40 at 13:17:00.0. Sun / Cloud Simulation is deactivated while in feed mode.

Light Season
There are situations, where light intensity has to be changed gradually over a longer time period. Either you consider to implement seasonal variations in illumination. Or you have to ramp up intensity over weeks to slowly acclimate sensitive corals to a new environment without risking bleaching due to overexposure to light. That's where you need the 'Light Season' module.

Simply design a series of anchor points during the course of a year, each of which defines a dimming factor ranging from 0% (dark) up to a maximum of 250% (2½ times the underlying light intensity).

Here the time axis represents a full year, which is divided into 12 months of equal length measured in time units. Anchor points now have to be located on a time grid of tenths of a month, where '1.0' means January 1st 00:00.0, with each tenth adding 365/120 = 3.04 (within leap years 366/120 = 3.05) days up to 3 days before New Year's Eve ('12.9'). There's a Fractional Months Calculator to help with such date conversions.

Finally assign that rule to a 'Light Program' by selecting the according channel at 'Ssn Chan' with the 'Ssn Acti' box being checked. To shift the curve on the time axis increase the 'Ssn Ysft' value above the '0.0' months default. So to move the curve a quarter of a year to the right enter '3.0' (months). In case you use the Fractional Months Calculator be aware to subtract '1' from the resulting fractional value, as shifting starts from '0', meaning no shifting at all.

Light Season Moon
A simple method to simulate moon phases would be to create a list of alternating '0' and '100' percent values at half monthly intervals and assign that schedule to an adequately dimmed light channel.

Down Up Top Pump

Pump Shape
First of all, BE CAUTIOUS! Not every tank is built to tolerate the stress caused by water continuously swashing back and forth!

Pump configuration is very similar to light programming. You only have one further layer to create pump power shapes, which then are performed in infinite loops up to the next Pump Automation time anchor.

TFT Screen Dump
When designing shapes you have to put together time slices of variable widths measured in tenths of seconds ('Duration'), also with a 200 millisecond granularity. With each of these slices you define the power at the beginning of that interval ('Power') and the method to move from that starting level to the starting level of the next slice ('Mode'). 'Hold' means you hold the given power value until you reach the next slice, where it then changes rapidly. With 'Direct' there's a smooth transition. 'Off' deactivates the table entry. And there are some 'Random' modes to come.

The 'Position' parameter is there to rearrange entries within your list. Select 'Chan'nel and 'Item', set 'Position' to the item number where that entry has to be inserted, finally click 'Set'.

Be aware that item number 1 only runs once after starting the loop, which, reaching its end, always jumps back to position 2. By changing the duration of that entry slice you can easily shift the following loop relative to other shapes.

Pump Automation
At the Pump Automation page shapes are arranged to pump timetables to be run day by day. Each time interval, represented by a line, starts at the defined Weekday set / time, continuing until the time anchor that follows.

Select one of the shapes you previously created and specify the percentual intensity and offset at the beginning ('Scal Beg' / 'Offs Beg') and the end ('Scal End' / 'Offs End') of the interval. The 'Scale' parameter is there to compress (below 100) or stretch (above 100) the previously designed shape. A negative value inverts the curve. In addition, with a positive or negative 'Offset' that curve can be shifted up resp. down the given percentage of the total range. That's particularly important to lift an inverted, negative graph into positive territory.

You achieve maximum flexibility by extending all of your pump shapes to the full 00..FF range and later on rescaling and shifting these curves at the 'Pump Automation' table according to your respective needs. For example, if a minimum of 25% output has to be guaranteed throughout a full-scale shape program, enter these 25% as the Offset of that shape, which you then also have to scale down to 75% of its size to make it still fit into the given power range.

Finally decide, whether you need to delay the shape, for example to create waves or gyres by synchronizing the pump with others.

Pump Program
Now you have to assign Pump Programs to the ports, where your pumps are attached. Pump Ports 1..4 are mapped to PWM ports 9..12. Ports 5..8 feed the analog outputs A..D (voltage range 0V to 2.048V) with their downstream operational amplifiers adjusted to the requirements of the connected pumps.

As with the light configuration you have to enter whether it's an On/Off device or a variable speed DC pump.

Most pumps don't immediately start up with only minimum voltage on the control wire. Tunze DC pumps for example need at least about 30 percent of their maximum voltage to spin in stable rotation. Below that you risk overheating and accelerated attrition due to an eccentric wobbling impeller. And there may be situations, where the maximum pump throughput has to be restricted for whatever reason. AquariOS accommodates such requirements, as it allows to transpose the calculated power values into a narrower power band defined by the upper and lower 'Powr Range' parameter, where the '00' .. 'FF' preset means no change.

Now, with such an output transition in action, you have to decide, whether at zero power the pump has to remain spinning at idle speed, or to be stopped. The former would be better for short periods to avoid stressing on-off cycles, while the latter saves energy and prevents wear during longer inactivities. Select device type 'VariOn' to always keep power within 'Powr Range', and 'VariOff' to regulate power down to zero when the lower border of that range is reached (or in other words deactivate 'Powr Range' calculations at zero).

Be aware, that the on-screen display doesn't reflect the output modifications resulting from 'Powr Range' calculations, which are only done to compensate device weaknesses approaching the targeted output waveform.

Mode can once again be 'Inactive', 'Off', 'On', 'Fixed' (with 'Fix Powr' defining intensity) and 'Auto'matic (channel at 'Aut Chan').

Check 'Feed Auto' if certain pumps have to work differently while in feed mode and select the Pump Automation channel ('Feed Chan') that then has to be used.

Down Up Top Temperature

Temperature Control
Add cheap DS18B20 OneWire temperature sensors and AquariOS can also vary water temperature according to your animals' needs. Shallow-water inhabitants for example may benefit from a nocturnal temperature drop. Or place one of the sensors next to your expensive LED equipment to control a fan.

At first a new sensor has to be adjusted. Set 'Bias' to shift the calibration curve up or down, 'Slope' to change, well, its slope.

Temperature Program
The Temperature Program works similar to the Light and Pump Program page. Select 'Mode' ('Inactive', 'Off', 'On', 'Fixed' / 'Fix Temp', 'Auto' / 'Aut Chan')), 'Port' number (1..4 corresponding PWM output 13..16) and device 'Type' ('Heater' or 'Cooler'). With 'Offset' you can shift your target temperature up or down.

Temperature Chart Comparison
'Hyst'eresis defines the temperature range, within which the on/off status of the output doesn't change. Where with a mechanic bimetal thermostat integrated into a heater unit a low number of switch cycles is important to protect the movable parts from wear, with solid-state relays (SSRs) to be used with AquariOS it's just the opposite. To avoid changes in temperature that put a great strain on the device, a narrow hysteresis range resulting in many short on/off-cycles has to be chosen.

The temperature chart demonstrates that difference. While on the left up to 15:00 an SSR driven by AquariOS controls power supply to an Eheim-Jäger 3606 150 W heater in a 125 l / 33 gal tank (hysteresis 0.0°C), later-on that heater is directly connected to the electrical grid and thereby controlled by its internal bimetal thermostat, resulting in noticeable temperature swings.

For each channel the LCD display shows '·' for inactive, '-' for off ('|' within hysteresis range) and '+' for on ('X' within hysteresis range).

When, with a 'Heater' device type selected, temperature falls below the target minus hysteresis value, power is turned on with the display showing '+'. As temperature now rises, at and above target value display changes to 'X' indicating hysteresis range, where heating still continues. If it falls back below the hysteresis range you'll once again see '+'. Finally, at target temperature, power is turned off with the display indicator switching to '-'. When with the now inactive device temperature falls back into hysteresis range '|' is shown until it comes below target temperature minus hysteresis, where the heater is activated again.

The same goes with the 'Cooler' type. Above target temperature plus hysteresis value the chiller unit gets powered till temperature falls down to target temperature with the indicator showing '+' above hysteresis range and 'X' within that range above target temperature. With the device finally switching off at target temperature, again '-' is shown changing to '|' with temperature rising into hysteresis range.

As there's always the chance the system fails, some precautions have to be taken. Plug solely heaters with an integrated mechanic thermostat into your AquariOS controller and set them to a temperature a little above the range AquariOS has to take care of. And add another independent heater to the tank, activated at a temperature below the AquariOS range. That way you avoid cooking or freezing the living beings in your aquarium.

Temperature Automation
Temperature Automation curves have to be set up similar to Light Automation. Enter a 'Weekday' set / 'Time' combination and the targeted 'Temp'erature and click 'Set'. To make your configuration permanent click 'Save'. That's it.

Temperature Chart AquariOS
The graph on the left shows temperatures measured while running an automation program with four time-temperature anchors defined (00:00 - 25.5°C / 03:00 - 25.5°C / 12:00 - 27.0°C / 15:00 - 27.0°C).

With an hysteresis of 0.1°C the shape of the curve isn't as smooth as the waveform in the chart above. On the other hand that wider range results in on-off cycles of about 10 minutes length, whereas with a 'zero tolerance' hysteresis of 0.0°C there are about 10 switching cycles per minute, requiring the usage of an electronic switch like an SSR.

Temperature Season
In order to reflect seasonal changes in our living beings' natural habitats it may be necessary to vary water temperature throughout the year. Apart from freshwater scenarios, where temperature fluctuations may be drastic, even the behavior of reef biotope inhabitants is considerably influenced by this environmental parameter. So, for instance, spawning of Acropora species seems to be triggered and thereby synchronized by a rapid seasonal rise in ocean temperature.

To experience the sequence of seasons with your tank you just have to define a series of temperature correction values, each in a range of ±20.0°C, at the 'Temperature Season' table similar to the 'Light Season' page. Activate that dataset at the 'Temperature Program' page, 'Ssn Acti' and 'Ssn Chan', for a given entry. There you may also shift the curve by fractions of a month with the 'Ssn Ysft' (Season Year Shift) parameter and/or mute/boost/invert the correction value by using the 'Ssn Scal' (Season Scaling) (±125%) percentage value.

Down Up Top Input

Input Program
Apart from temperature probes addressed above there are four analog input channels to collect status information, forwarded at one second intervals. They allow you to attach devices like light dependent resistors (aka photoresistors), fluid level sensors, water leak detectors or TDS / pH meter probes to the system, whose voltage readings then are propagated through the MQTT interface.

The inputs are provided by a mix of up to two 12-bit ADS1015 and/or 16-bit ADS1115 analog-digital converters, each of which offers four signal lines, which can be used as either two differential, four single-ended or a mix of one differential plus two single-ended separate inputs. AquariOS then is capable of processing four of those data lines. ADS1015's 12 bit readings are extended to 16 bit by filling the lowest nibble proportionally.

The ADS1x15's I²C address is determined by the voltage fed to its address (ADR) input pin. That pin tied to Ground (GND) gives an I²C address of 0x48, by connecting it with the supply voltage (VCC) of 3.3 V it's 0x49. Enter the selected address(es) at the AquariOS Config web page, and, further below, select the ADC device type(s) (12-bit ADS1015 or 16-bit ADS1115) you installed.

Now configure signal processing at the Input Program page. For each processing line select the device (1 or 2) and its signal input pins to be used, either differential (0:1|0:3|1:3|2:3) or single-ended with GND as its reference (0:GND|1:GND|2:GND|3:GND).

Be aware, that this ADC is only capable of measuring voltage levels between GND and VCC, which here are +3.3 V. Therefore in single-ended mode referencing GND level, only positive electrical potentials can be read, resulting in values between 0/0x0000 and 32767/0x7FFF. To gain the ADC's full resolution, ranging from -32768/0x8000 to +32767/0x7FFF, differential mode with the reference line's potential somewhere between GND and VCC has to be chosen. For example, when selecting an amplification leading to a full-scale range of ±2.048 V in differential mode and feeding the reference input with +1.024 V the converter's capabilities can be maxed out with probe input levels ranging from 0 up to 2048 mV, resulting in readings between -32768 and +32767. That also means, that by choosing an amplification above the 3.3 V boundary (full-scale range ±4.096 or ±6.144 V), bit resolution is reduced accordingly due to the converter's inability to return readings higher than the value that represents VCC.

Attention! To avoid damage, analog input voltages must never fall below or exceed the absolute minimum/maximum rating of GND - 0.3 V ... VCC + 0.3 V, means -0.3 V ... +3.6 V with the given VCC supply voltage of 3.3 V. Currents have to be limited to 10 mA.

Active input lines are scanned at 200 ms intervals with these voltage levels then arithmetically averaged over the five samples taken each second. Thereafter a linear data correction according to the input's Bias and Slope parameter is applied to the resulting mean value.

The MQTT parameter set defines the conditions that have to be complied for data publishing and the MQTT channel that's used for the respective signal.

Input Screen
Near the top right corner of the TFT screen input processing information is shown in real time. The column on the right lists raw signal levels in four-digit hexadecimal format (8000/8001 .. FFFF/0000/0001 .. 7FFE/7FFF) with '::::' representing an inactive input channel and '????' indicating data acquisition problems. With MQTT activated (MQTT mode different from 'Never') the MQTT channel number assigned is shown on the left. Between those two columns a '<' sign shows up when the incoming signal met the MQTT propagation criterion and thereby triggered the sending of a respective data packet.

Down Up Top MQTT

MQTT Dashboard
With version 1.0.5 an MQTT interface was introduced, a first step towards an easy integration into home automation systems providing command sets to obtain status data and control processing.

TFT Screen Dump - Manual Power
That also means, for less complex configuration tasks you no longer have to deal with the heavyweight web interface. A few clicks using your smartphone for example may stop all pumps and increase light intensity to make maintenance work more comfortable.

Furthermore there's a manual light and pump power mode only accessible through the MQTT interface. When a channel gets into manual mode the background color of its readout on the TFT screen turns orange.

Imagine, now you're capable of creating an individual graphical user interface that best suits your needs! The demo dashboard presented here was built by using the freely available Node-RED development tool.

Table of MQTT commands and data returned
Direction Topic Payload Description
Name Data
System
Subscribed sc/set rst Restarts AquariOS system
Date & Time
Subscribed dc/set cardinal [milliseconds since epoch, only seconds valid] Sets system date & time
dc/net Induces retrieval from NTP server
dc/get Induces dc/ret publishing
Published dc/ret name Timestamp [ms since epoch (19700101 0000 UTC)] Published system date & time
type dd
valu cardinal
Temperature
Published td/ret name Temperature [°C] Published temperature of active probes (0..3)
type td
chan cardinal
valu float
Input
Published id/ret name Input Published input signal levels of active probes
type id
chan cardinal
raw integer
adj integer
Feed Control
Subscribed fc/set [ina|act|aut] Sets Feed Mode: ina:Inactive | act:Active | aut:Count-Down Automation
Published fc/ret name Feed Duration Remaining [s] Published remaining feed duration
type fd
valu cardinal
Light Control
Subscribed lc/set [aut|min|max] Sets Light Mode: aut:Automatic | min:Minimum (Dark) | max:Maximum (Bright)
Light Program
Subscribed lp/sav Saves Light Program data to non-volatile RAM
lp/lod Loads / restores Light Program data from non-volatile RAM
lp/set chan cardinal [0..7] Sets Light Program dataset (item 0..7), implies 'lp/get [0..7]'
mode cardinal [0..4] Mode: 0:Inactive | 1:Off | 2:On | 3:Fixed | 4:Auto
devi cardinal [0..1] Device Type: 0:On/Off | 1:Variable
port cardinal [0..7] Port Number [0..7]
fxpw cardinal [0..255] Fixed Power
auch cardinal [0..9] Automation Channel Number
ssac boolean [false|true] Seasonal Adjustment Activation Switch: false:Inactive | true:Active
ssch cardinal [0..19] Seasonal Adjustment Channel Number
ssys cardinal [0..119] Seasonal Adjustment 120th Of Year Shift
feac boolean [false|true] Feed Mode Activation Switch: false:Inactive | true:Active
fech cardinal [0..9] Feed Mode Channel Number
sact boolean [false|true] Sun/Cloud Simulation Activation Switch: false:Inactive | true:Active
sdst cardinal [0..863998] Sun/Cloud Simulation Event Distance [10th Of Seconds]
srmp cardinal [0..863998] Sun/Cloud Simulation Ramping Time [10th Of Seconds]
shld cardinal [0..863998] Sun/Cloud Simulation Holding Time [10th Of Seconds]
spct cardinal [0..300] Sun/Cloud Simulation Power Percentage
lp/get cardinal [0..7] Initiates publishing of a Light Program dataset (item 0..7)
Published lp/ret name Light Program Published Light Program dataset (item 0..7)
type lp
Payload similar to 'chan' .. 'spct' described above
Light Manual Override
Subscribed lm/set chan cardinal [0..7] Sets Light Manual Override data (item 0..7), implies 'lm/get [0..7]'
mode boolean [false|true] (optional)     Mode: false:Inactive | true:Active
powr cardinal [0..4095] (optional)     Light Power
lm/get cardinal [0..7] Initiates publishing of a Light Manual dataset (item 0..7)
Published lm/ret name Light Manual Override Published Light Manual Override data (item 0..7)
type lm
Payload similar to 'chan' .. 'powr' described above
Pump Manual Override
Subscribed pm/set chan cardinal [0..7] Sets Pump Manual Override data (item 0..7), implies 'pm/get [0..7]'
mode boolean [false|true] (optional)     Mode: false:Inactive | true:Active
powr cardinal [0..4095] (optional)     Pump Power
pm/get cardinal [0..7] Initiates publishing of a Pump Manual dataset (item 0..7)
Published pm/ret name Pump Manual Override Published Pump Manual Override data (item 0..7)
type pm
Payload similar to 'chan' .. 'powr' described above


As shown above, the MQTT interface refers to the internal item (channel-, port- etc.) numbers starting with '0'. It's up to the developer of the user interface resp. MQTT dashboard, to translate these values into the common 1+ numbering used on-screen and with the web interface.

A command to be sent to AquariOS either consists of

Topic dm net
Payload

a bare topic,

Topic home/aquarios/dm/set
Payload 1582931367000

a topic with a plain payload containing data

Topic home/aquarios/lp/set
Payload {
  "chan":  4,
  "port":  4,
  "devi":  1,
  "mode":  4,
  "fxpw":  63,
  "auch":  4,
  "ssac":  true,
  "ssch":  1,
  "ssys":  73,
  "feac":  false,
  "fech":  4,
  "sact":  true,
  "sdst":  6000,
  "srmp":  1200,
  "shld":  600,
  "spct":  75
}

or a topic with a JSON formatted payload containing a more complex dataset. With data processing <SPC>, <CR> and <LF> characters are ignored. So it's allowed to put all parameters in a single line.

Topic home/aquarios/lp/ret
Payload {
  "vers":  "1.0",
  "time":  1582925077,
  "name":  "Light Program",
  "type":  "lp",
  "load":  {
    "chan":  4,
    "port":  4,
    "devi":  1,
    "mode":  4,
    "fxpw":  63,
    "auch":  4,
    "ssac":  true,
    "ssch":  1,
    "ssys":  73,
    "feac":  false,
    "fech":  4,
    "sact":  true,
    "sdst":  6000,
    "srmp":  1200,
    "shld":  600,
    "spct":  75
  }
}

Data published by AquariOS are also formatted as JSON text blocks. There's an envelope section containing interface version ('vers'), timestamp ('time'), block type description ('name') and block type ID ('type'), followed by a payload section ('load') containing the data to be transmitted.

All messages are sent with QoS 0 ('at most once') and the Retained flag not set.

Currently the MQTT interface reflects only a few aspects of the AquariOS system, but with time further functionality will be added.

Down Up Top Support

You're welcome to contact me directly by mail, preferably PGP encrypted.

With questions resp. suggestions of common interest you may even choose to join the recently created support thread at the Reef2Reef forum. That's also a great place to tell us about the device(s) you built yourself. And there you will find competent advice on further aquarium controller topics not related to this project.

Down Up Top !!! Important Notes !!!

AQUARIOS IS A WORK IN PROGRESS, DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL. IT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHOR OR COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THIS WORK OR THE USE OR OTHER DEALINGS IN IT.

Down Up Top And now ... Action!


Up Top

Copyright © Christian Danner, 2022.

Homepage: www.danner-net.de
EMail: aquarios@danner-net.de