paulsteigel
New Member
It might be not relating to yours writing but for my case with 3 devices in 3 different places, hundred of km away from each other, I have 2 options:Right now I just enabled the OTA component. I will anyway need to modify /etc/hosts (GNU/Linux) since the DNS isn't really working at the moment.
I don't like too much that the OTA password is transmitted plaintext and no encryption/SSL/TLS takes places. Regardless if it's the ota: section, the ota_http: section or the webserver: section.
Granted I need to firewall down my garage (right now it's just doing ip_forwarding to my main LAN so I can access stuff). But security wise it's an absolute no-go.
EDIT 1: when trying to enable the webserver (mainly for debugging purposes), I am getting some errors:
Code:... Compiling .pioenvs/jk-bms-bat02/src/esphome/components/wifi/wifi_component_esp_idf.o Compiling .pioenvs/jk-bms-bat02/src/esphome/components/wifi/wifi_component_libretiny.o Compiling .pioenvs/jk-bms-bat02/src/esphome/components/wifi/wifi_component_pico_w.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/application.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/component.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/component_iterator.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/controller.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/entity_base.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/helpers.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/log.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/ring_buffer.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/scheduler.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/string_ref.o Compiling .pioenvs/jk-bms-bat02/src/esphome/core/util.o Compiling .pioenvs/jk-bms-bat02/src/main.o Linking .pioenvs/jk-bms-bat02/firmware.elf /root/.platformio/packages/toolchain-xtensa-esp32s3/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld: .pioenvs/jk-bms-bat02/src/main.o:(.literal._Z5setupv+0xd38): undefined reference to `esphome::web_server::WebServer::WebServer(esphome::web_server_base::WebServerBase*)' /root/.platformio/packages/toolchain-xtensa-esp32s3/bin/../lib/gcc/xtensa-esp32s3-elf/8.4.0/../../../../xtensa-esp32s3-elf/bin/ld: .pioenvs/jk-bms-bat02/src/main.o: in function `setup()': /root/ESPHome/esphome-jk-bms-can-1.17.4/.esphome/build/jk-bms-bat02/src/main.cpp:579: undefined reference to `esphome::web_server::WebServer::WebServer(esphome::web_server_base::WebServerBase*)' collect2: error: ld returned 1 exit status *** [.pioenvs/jk-bms-bat02/firmware.elf] Error 1 ========================================================================================= [FAILED] Took 41.70 seconds =========================================================================================
YAML relevant section:
YAML:web_server: port: 80 version: 2 # Version 1 displays as a table. Version 2 uses web components and has more functionality. Defaults to 2. log: true local: true # No internet/intranet required on the clients (all assets are inlined, compressed and served from flash) include_internal: true # Whether internal entities should be displayed on the web interface. Defaults to false ota: false auth: username: !secret web_server_username password: !secret web_server_password
1. Using OTA with 2 options:
+ Using NAT (i.e 8266
With this option I will have to use the use_address in the Wifi section. (use_address: [no ip dyn]);
+ using ota_http: a bit of problem to generate firmware (in legacy format), md5 hash and post to a webserver. I myself post it to my HA with additional web server installed via root ssh.
2. Using wireguard: installing wireguard is abit difficult but also worked!
Currently, I propose Olivier and his team to modify his ota_http to allow firmware update over the mqtt protocol (this can be best as it is easy and can be fully automated via the esphome's Install command) but they seems to be reluctantly to do so!
Regarding the improvement of charging, I am working on modifying Sleeper85 code (the old version) on 0x355 and 0x351 to simply focus on:
+ Create a script to handle the charging/discharging check using cell voltage (min/max) and check point set by user (such as 3.2 - 3.45) to start reducing charging current when max cell voltage is closing to 3.45 or OVP slider value set by user. Similarly will be applied for UVP. I prefer to use map() or PID to fine tune charging current.
+ On SOC reporting: stick to 99% (regardless JK SOC is 100 already) until 3.45 or max check point on OVP is reached. The same logic shall be applied while discharging: if voltage fall below 3.2 or checkpoint set by user while JK SOC is greater than the cutoff value for inverter, it will still set SOC to the cut off value to stop discharging. If SOC is fall below the Cutoff value but Cell minimum voltage is still greater than 3.2 or OVP value, it will report SOC of 1 point higher than the Cutoff value. By doing this, JK will reset its SOC to the nearly acceptable value.
Best
Ngoc