Home Assistant - Greenbono Aku jako elektroměr

tomas
Příspěvky: 317
Registrován: stř črc 06, 2022 12:52 pm

Re: Home Assistant - Greenbono Aku jako elektroměr

Příspěvek od tomas »

visis píše: pon pro 18, 2023 12:08 pm Akorát nevím jak. Píše, že zapojit jen 2 drátky, ale na waveshare jsou A+, B- a zem.
Pokud je ten převodník vedle Greenbona tak to bude fungovat i bez země, zvláště když je to v jedné skříni (na jedné DIN liště) tak tam nebude rozdíl zemních potenciálů. Případně Greenbono má svorku "zemně" - obrácené T.
jirisrba
Příspěvky: 1
Registrován: sob led 20, 2024 8:02 pm

Re: Home Assistant - Greenbono Aku jako elektroměr

Příspěvek od jirisrba »

greenbono jde napojit do HA i napřímo přes esphome. Používám esp8266 + max3485

Kód: Vybrat vše

uart:
  id: mod_bus
  tx_pin: GPIO1
  rx_pin: GPIO3
  baud_rate: 9600
  debug:
  
modbus_controller:
  - id: greenbono
    address: 1
    modbus_id: modbus_greenbono
    
sensor:
  - platform: modbus_controller
    modbus_controller_id: greenbono
    id: last_valid_u1
    name: ${friendly_name} LastValidU1
    address: 16
    unit_of_measurement: "V"
    register_type: read
    value_type: U_WORD
    accuracy_decimals: 0    
Adresy protokolu ModBus sedí s PDF, bez nějakého posunu. Funkce 0x4 = register_type: read
michalO
Příspěvky: 1
Registrován: ned bře 10, 2024 12:44 pm

Re: Home Assistant - Greenbono Aku jako elektroměr

Příspěvek od michalO »

jirisrba píše: sob led 20, 2024 8:06 pm greenbono jde napojit do HA i napřímo přes esphome. Používám esp8266 + max3485

Kód: Vybrat vše

uart:
  id: mod_bus
  tx_pin: GPIO1
  rx_pin: GPIO3
  baud_rate: 9600
  debug:
  
modbus_controller:
  - id: greenbono
    address: 1
    modbus_id: modbus_greenbono
    
sensor:
  - platform: modbus_controller
    modbus_controller_id: greenbono
    id: last_valid_u1
    name: ${friendly_name} LastValidU1
    address: 16
    unit_of_measurement: "V"
    register_type: read
    value_type: U_WORD
    accuracy_decimals: 0    
Adresy protokolu ModBus sedí s PDF, bez nějakého posunu. Funkce 0x4 = register_type: read
Dobrý deň prajem, vedeli by ste mi detailnejšie popísať ako vám to funguje? a ako ste to integrovali? Mám dosku ESP8266 a prevodník ppt to RS485 a požil som aj váš kód ale nedostávam ziadnu odpoved. Je potrebne ešte niečo nastaviť v Greenbone?
simier
Příspěvky: 3
Registrován: čtv dub 13, 2023 5:29 pm

Re: Home Assistant - Greenbono Aku jako elektroměr

Příspěvek od simier »

dobrý den, vyřešil jste to taky se pokouším mám esp8266 a tento převodník https://www.laskakit.cz/prevodnik-uart- ... 5--max485/ připojuji ho na 3,3V zkoušel jsem i na 5V a logický převaděč a to samé. Bliká pouze TX dioda na převodníku RX nebliká.

Kód: Vybrat vše

uart:
  id: mod_bus
  tx_pin: GPIO1
  rx_pin: GPIO3
  baud_rate: 9600
  debug:

modbus:
    id: modbus_greenbono    
    uart_id: mod_bus

modbus_controller:
    id: greenbono
    address: 1
    modbus_id: modbus_greenbono
    
sensor:
  - platform: modbus_controller
    modbus_controller_id: greenbono
    id: last_valid_u1
    name: ${friendly_name} LastValidU1
    address: 16
    unit_of_measurement: "V"
    register_type: read
    value_type: U_WORD
    accuracy_decimals: 0

Kód: Vybrat vše

INFO ESPHome 2025.3.3
INFO Reading configuration /config/esphome/esp1.yaml...
INFO Starting log output from 192.168.0.115 using esphome API
INFO Successfully connected to esp1 @ 192.168.0.115 in 0.006s
INFO Successful handshake with esp1 @ 192.168.0.115 in 2.716s
[22:46:07][I][app:100]: ESPHome version 2025.3.3 compiled on Apr 18 2025, 22:30:40
[22:46:07][C][wifi:600]: WiFi:
[22:46:08][C][wifi:428]:   Local MAC: C8:2B:96:1F:D8:BE
[22:46:08][C][wifi:433]:   SSID: [redacted]
[22:46:08][C][wifi:436]:   IP Address: 192.168.0.115
[22:46:08][C][wifi:439]:   BSSID: [redacted]
[22:46:08][C][wifi:441]:   Hostname: 'esp1'
[22:46:08][C][wifi:443]:   Signal strength: -54 dB ▂▄▆█
[22:46:08][C][wifi:447]:   Channel: 4
[22:46:08][C][wifi:448]:   Subnet: 255.255.255.0
[22:46:08][C][wifi:449]:   Gateway: 192.168.0.1
[22:46:08][C][wifi:450]:   DNS1: 192.168.0.1
[22:46:08][C][wifi:451]:   DNS2: 192.168.0.1
[22:46:08][C][logger:177]: Logger:
[22:46:08][C][logger:178]:   Max Level: DEBUG
[22:46:08][C][logger:179]:   Initial Level: DEBUG
[22:46:08][C][logger:181]:   Log Baud Rate: 115200
[22:46:08][C][logger:182]:   Hardware UART: UART0
[22:46:08][C][uart.arduino_esp8266:118]: UART Bus:
[22:46:08][C][uart.arduino_esp8266:119]:   TX Pin: GPIO1
[22:46:08][C][uart.arduino_esp8266:120]:   RX Pin: GPIO3
[22:46:09][C][uart.arduino_esp8266:122]:   RX Buffer Size: 256
[22:46:09][C][uart.arduino_esp8266:124]:   Baud Rate: 9600 baud
[22:46:09][C][uart.arduino_esp8266:125]:   Data Bits: 8
[22:46:09][C][uart.arduino_esp8266:126]:   Parity: NONE
[22:46:09][C][uart.arduino_esp8266:127]:   Stop bits: 1
[22:46:09][C][uart.arduino_esp8266:129]:   Using hardware serial interface.
[22:46:09][W][uart.arduino_esp8266:143]:   You're using the same serial port for logging and the UART component. Please disable logging over the serial port by setting logger->baud_rate to 0.
[22:46:09][C][modbus:165]: Modbus:
[22:46:09][C][modbus:167]:   Send Wait Time: 250 ms
[22:46:09][C][modbus:168]:   CRC Disabled: NO
[22:46:09][C][modbus_controller:349]: ModbusController:
[22:46:09][C][modbus_controller:350]:   Address: 0x01
[22:46:09][C][modbus_controller:351]:   Max Command Retries: 4
[22:46:09][C][modbus_controller:352]:   Offline Skip Updates: 0
[22:46:10][C][modbus_controller.sensor:010]: modbus_controller.sensorModbus Controller Sensor '${friendly_name} LastValidU1'
[22:46:10][C][modbus_controller.sensor:010]: modbus_controller.sensor  State Class: ''
[22:46:10][C][modbus_controller.sensor:010]: modbus_controller.sensor  Unit of Measurement: 'V'
[22:46:10][C][modbus_controller.sensor:010]: modbus_controller.sensor  Accuracy Decimals: 0
[22:46:10][W][component:237]: Component modbus_controller took a long time for an operation (139 ms).
[22:46:10][W][component:238]: Components should block for at most 30 ms.
[22:46:10][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:46:10][W][component:237]: Component uart took a long time for an operation (73 ms).
[22:46:10][W][component:238]: Components should block for at most 30 ms.
[22:46:10][C][captive_portal:089]: Captive Portal:
[22:46:11][W][component:237]: Component modbus_controller took a long time for an operation (139 ms).
[22:46:11][W][component:238]: Components should block for at most 30 ms.
[22:46:11][C][mdns:116]: mDNS:
[22:46:11][C][mdns:117]:   Hostname: esp1
[22:46:11][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:46:11][W][component:237]: Component uart took a long time for an operation (73 ms).
[22:46:11][W][component:238]: Components should block for at most 30 ms.
[22:46:11][C][esphome.ota:073]: Over-The-Air updates:
[22:46:11][C][esphome.ota:074]:   Address: esp1.local:8266
[22:46:11][C][esphome.ota:075]:   Version: 2
[22:46:11][C][esphome.ota:078]:   Password configured
[22:46:11][W][component:237]: Component modbus_controller took a long time for an operation (139 ms).
[22:46:11][W][component:238]: Components should block for at most 30 ms.
[22:46:11][C][safe_mode:018]: Safe Mode:
[22:46:11][C][safe_mode:019]:   Boot considered successful after 60 seconds
[22:46:12][C][safe_mode:021]:   Invoke after 10 boot attempts
[22:46:12][C][safe_mode:022]:   Remain in safe mode for 300 seconds
[22:46:12][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:46:12][W][component:237]: Component uart took a long time for an operation (73 ms).
[22:46:12][W][component:238]: Components should block for at most 30 ms.
[22:46:12][W][component:237]: Component modbus_controller took a long time for an operation (140 ms).
[22:46:12][W][component:238]: Components should block for at most 30 ms.
[22:46:12][C][api:140]: API Server:
[22:46:12][C][api:141]:   Address: esp1.local:6053
[22:46:12][C][api:143]:   Using noise encryption: YES
[22:46:12][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:46:12][W][component:237]: Component uart took a long time for an operation (74 ms).
[22:46:12][W][component:238]: Components should block for at most 30 ms.
[22:46:13][W][component:237]: Component modbus_controller took a long time for an operation (139 ms).
[22:46:13][W][component:238]: Components should block for at most 30 ms.
[22:46:13][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:46:13][W][component:237]: Component uart took a long time for an operation (72 ms).
[22:46:13][W][component:238]: Components should block for at most 30 ms.
[22:46:13][D][modbus_controller:039]: Modbus command to device=1 register=0x11 no response received - removed from send queue
[22:46:13][W][component:237]: Component modbus_controller took a long time for an operation (133 ms).
[22:46:13][W][component:238]: Components should block for at most 30 ms.
[22:47:10][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:47:10][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:47:11][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:47:11][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:47:11][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:47:11][D][modbus_controller:039]: Modbus command to device=1 register=0x10 no response received - removed from send queue
[22:48:10][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:48:10][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:48:11][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:48:11][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:48:11][D][uart_debug:114]: >>> 01:04:00:11:00:01:61:CF
[22:48:11][D][modbus_controller:039]: Modbus command to device=1 register=0x10 no response received - removed from send queue
Odpovědět

Zpět na „Home Assistant“