[DISC] Ram usage and flash size optimization (#2223)

Fix duplicate W and keep units and classes in flash
Use macro for discovery classes and units
[BREAKING] change gateway sensor unique id
module - parameter
Standardize the use of createDiscoveryFromList

Co-authored-by: Florian <1technophile@users.noreply.github.com>
This commit is contained in:
FlorianandFlorian authored and GitHub committed 2025-08-17 06:27:42 -05:00
1 parent 51bdc2d080
commit 6e6b54b05e
6 files changed
+588 -909

No files matched your search

+2 -2
View File
@@ -122,9 +122,9 @@ void pubOneWire_HADiscovery() {
(char*)("DS12B20_" + String(index + 1) + "_c").c_str(),
(char*)(ds1820_addr[index] + "_c").c_str(),
will_Topic,
"temperature",
HASS_CLASS_TEMPERATURE,
jsonTempc,
"", "", "°C",
"", "", HASS_UNIT_CELSIUS,
0, "", "", true, "",
"", "", "", "", false,
stateClassMeasurement // state class