diff --git a/docs/Commands.md b/docs/Commands.md index 902775b210..cdf53b1c4d 100644 --- a/docs/Commands.md +++ b/docs/Commands.md @@ -1026,6 +1026,8 @@ NPResult|``
Set addr/data result fo NPPHRes|``
Set number of decimal places in results for PH value (resolution = `0..3`). NPCLRes|``
Set number of decimal places in results for CL value (resolution = `0..3`). NPIONRes|``
Set number of decimal places in results for ION value (resolution = `0..3`). +NPSetOption0Sensor data min/max validation and correction (ESP32 only)
`0` = disable correction
`1` = enable correction *(default)*. +NPSetOption1NeoPool Modbus connection statistics (ESP32 only)
`0` = disable statistics
`1` = disable statistics *(default)*. NPRead|`( )`
Read device 16-bit register (addr = `0..0x060F`, cnt = `1..30`). `` = `1` if omitted NPReadL|`( )`
Read device 32-bit register (addr = `0..0x060F`, cnt = `1..15`). `` = `1` if omitted NPWrite|` ( ...)`
Write device 16-bit register (addr = `0..0x060F`, data = `0..0xFFFF`). Use of `` max 10 times diff --git a/docs/NeoPool.md b/docs/NeoPool.md index 16907351e4..7dc9399013 100644 --- a/docs/NeoPool.md +++ b/docs/NeoPool.md @@ -203,6 +203,28 @@ Sensor data is sent via the Tasmota topic `tele/%topic%/SENSOR` in JSON format e "State": [0, 1, 0, 0, 0, 1, 0], "Aux": [0, 0, 1, 0], "Acid": 0 + }, + "Connection": { + "Time": "2024-08-14T15:00:00", + "MBRequests": 9040, + "MBNoError": 9039, + "MBIllegalFunc": 0, + "MBIllegalDataAddr": 0, + "MBIllegalDataValue": 0, + "MBSlaveError": 0, + "MBAck": 0, + "MBSlaveBusy": 0, + "MBNotEnoughData": 0, + "MBMemParityErr": 0, + "MBCRCErr": 0, + "MBGWPath": 0, + "MBGWTarget": 0, + "MBRegErr": 0, + "MBRegData": 0, + "MBTooManyReg": 0, + "MBUnknownErr": 0, + "MBNoResponse": 1, + "DataOutOfRange": 0 } }, "TempUnit": "C" @@ -268,12 +290,33 @@ Relay.Conductivity|(Bool) Conductivity relay state Relay.Heating|(Bool) Heating relay state Relay.UV|(Bool) UV relay state Relay.Valve|(Bool) Valve relay state +Connection|NeoPool Modbus connection statistics (ESP32 only, [NPSetOption1](#NPSetOption1) must be 1): +Connection.Time|(String) Start time statistics +Connection.MBRequests|(Int) Total ModBus queries +Connection.MBNoError|(Int) Responses without error +Connection.MBNoResponse|(Int) Missing responses +Connection.DataOutOfRange|(Int) Number of values outside the sensor range +Connection.MBIllegalFunc|(Int) Err 1: Illegal Function +Connection.MBIllegalDataAddr|(Int) Err 2: Illegal Data Address +Connection.MBIllegalDataValue|(Int) Err 3: Illegal Data Value +Connection.MBSlaveError|(Int) Err 4: Slave Error +Connection.MBAck|(Int) Err 5: Acknowledge but not finished (no error) +Connection.MBSlaveBusy|(Int) Err 6: Slave Busy +Connection.MBNotEnoughData|(Int) Err 7: Not enough minimal data received +Connection.MBMemParityErr|(Int) Err 8: Memory Parity error +Connection.MBCRCErr|(Int) Err 9: CRC error +Connection.MBGWPath|(Int) Err 10: Gateway Path Unavailable +Connection.MBGWTarget|(Int) Err 11: Gateway Target device failed to respond +Connection.MBRegErr|(Int) Err 12: Wrong number of registers +Connection.MBRegData|(Int) Err 13: Register data not specified +Connection.MBTooManyReg|(Int) Err 14: To many registers +Connection.MBUnknownErr|(Int) Unknown errors occured The JSON values `pH`, `Redox`, `Hydrolysis`, `Chlorine`, `Conductivity` and `Ionization` are only available if the corresponding module is installed in the device (the corresponding "Module" subkey must be `1`). The `Relay` subkeys `Acid`, `Base`, `Redox`, `Chlorine`, `Conductivity`, `Heating`, `UV` and `Valve` are only available if the related function is assigned to a relay. -To check which modules are installed use the `Module` value from SENSOR topic or query it manually by using the [NPControl command](#NPControl): +To check which modules are installed use the `Module` value from SENSOR topic or query it manually by using the [NPControl](#NPControl) command: ```json { @@ -334,6 +377,8 @@ NPResult|``
Set addr/data result format for read NPPHRes|``
Set number of decimal places in results for PH value (resolution = `0..3`). NPCLRes|``
Set number of decimal places in results for CL value (resolution = `0..3`). NPIONRes|``
Set number of decimal places in results for ION value (resolution = `0..3`). +NPSetOption0Sensor data min/max validation and correction function (ESP32 only)
`0` = disable correction
`1` = enable correction *(default)* +NPSetOption1NeoPool Modbus connection statistics (ESP32 only)
`0` = disable statistics
`1` = disable statistics *(default)* NPRead|`( )`
Read device 16-bit register (addr = `0..0x060F`, cnt = `1..30`). `` = `1` if omitted NPReadL|`( )`
Read device 32-bit register (addr = `0..0x060F`, cnt = `1..15`). `` = `1` if omitted NPWrite|` ( ...)`
Write device 16-bit register (addr = `0..0x060F`, data = `0..0xFFFF`). Use of `` max 10 times @@ -345,6 +390,13 @@ NPExec|Take over changes without writing to EEPROM. This comm NPSave|Write data permanently into EEPROM.
During the EEPROM write procedure the NeoPool device may be unresponsive to MODBUS requests, this process always takes less than 1 second.
Since this process is limited by the number of EEPROM write cycles, it is recommend to write all necessary changes to the registers and only then execute EEPROM write process using this command.
__Note: The number of EEPROM writes for Sugar Valley NeoPool devices is guaranteed 100,000 cycles. As soon as this number is exceeded, further storage of information can no longer be guaranteed__. See also|[`SetOption157`](Commands.md#setoption157) - Hide/Show sensitive data +!!! note + The setttings changed by commands [NPPHRes](#NPPHRes), [NPCLRes](#NPCLRes), [NPIONRes](#NPIONRes), [NPSetOption0](#NPSetOption0) + and [NPSetOption1](#NPSetOption1) are permanently stored only if firmware was compiled with USE_UFILESYS + (#define `USE_UFILESYS`, default enabled on ESP32 and disabled on ESP82xx). + Without USE_UFILESYS (default on ESP82xx), you can alternatively use a rule to set your defaults during system start, e. g.: + `Rule1 ON System#Init DO Backlog NPPHRes 1;NPCLRes 1;NPIonRes 1;NPSetOption0 1;NPSetOption1 0` + ### Examples !!! example