-
1Hardcoded Settings in main.cpp / Installation
On first the Code Checks if Settings Uploaded as config.json in Spiffs Image, then starts first as Access Point (Captive Portal) to set these Settings if Settings not available at Boot.
Other Hand there are Five Settings they are hardcoded:
NTP Server Settings:
const char TIME_ZONE[] = "MEZ-1MESZ-2,M3.5.0/02:00:00,M10.5.0/03:00:00"; const char NTP_SERVER_POOL[] = "192.168.178.1";
Modbus Configuration, IP,Port,Unit:
esp32ModbusTCP cerbogx(100, { 192, 168, 178, 68 }, 502);
Holding Register and Register Format:
modbusData modbusRegisters[] = { "batteryvoltage", 840, 1, UFIX0, 0, 100 // Voltage };
Socket HTTP Request Parsing, change for another WLAN Power Socket Api:
int switchon(String ain); int switchoff(String ain)
MDNS Hostname, change for your local Network
MDNS.begin("switcher.fritz.box");
Other settings and Sync Times on NTP and other Delays are also Hardcoded at this time.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.