michtam / esphome-inode-reader Goto Github PK
View Code? Open in Web Editor NEWESPHome manifest to read values from iNode Energy Meter
License: MIT License
ESPHome manifest to read values from iNode Energy Meter
License: MIT License
Hi @michtam,
Can you help me get the correct calculations for an iNode Gas meter with Hall sensor (manufacturer_id 8290)?
https://inode.pl/iNode-Energy-Meter-Hall-sensor-p42
At the moment it outputs completely different numbers than it should.
This is from Passive BLE monitor.
This is what I get from ESPHome.
Thanks in advance for your help.
Whats is wrong ? i have Manufactoe ID 0x82 Inode with BT 5.1
esphome:
name: esp32_inode
platform: ESP32
board: nodemcu-32s
wifi:
ssid: ASUS_2.4
password: !secret password
ap:
ssid: "Esp32 BT Fallback Hotspot"
password: "JdytF7dpLgSs"
captive_portal:
#logger:
#api:
#web_server:
mqtt:
broker: 192.168.1.38
port: 1883
discovery: True
ota:
password: !secret ota_password
esp32_ble_tracker:
scan_parameters:
duration: 1s
active: false
on_ble_manufacturer_data_advertise:
- mac_address: "D0:F0:18:78:0B:C1"
manufacturer_id: "8290"
then:
- lambda: |-
ESP_LOGD("ble_adv", " 0 - %02X", (x[0] ) );
ESP_LOGD("ble_adv", " 1 - %02X", (x[1] ) );
ESP_LOGD("ble_adv", " 2 - %02X", (x[2] ) );
ESP_LOGD("ble_adv", " 3 - %02X", (x[3] ) );
ESP_LOGD("ble_adv", " 4 - %02X", (x[4] ) );
ESP_LOGD("ble_adv", " 5 - %02X", (x[5] ) );
ESP_LOGD("ble_adv", " 6 - %02X", (x[6] ) );
ESP_LOGD("ble_adv", " 7 - %02X", (x[7] ) );
ESP_LOGD("ble_adv", " 8 - %02X", (x[8] ) );
ESP_LOGD("ble_adv", " 9 - %02X", (x[9] ) );
ESP_LOGD("ble_adv", " 10 - %02X", (x[10] ) );
ESP_LOGD("ble_adv", " impulses hex - %02X:%02X", x[7], x[6] );
ESP_LOGD("ble_adv", " energy hex - %02X:%02X:%02X:%02X", x[5], x[4], x[3], x[2] );
ESP_LOGD("ble_adv", " power hex - %02X:%02X", x[1], x[0] );
ESP_LOGD("ble_adv", " bat&lgt hex - %02X", x[8] );
uint16_t impulses_raw = (x[6]) + (x[7] << 8);
uint16_t power_raw = (x[0]) + (x[1] << 8);
uint32_t energy_raw = (x[2]) + (x[3] << 8) + (x[4] << 16) + (x[5] << 24);
ESP_LOGD("ble_adv", " impulses_raw - %i", impulses_raw );
ESP_LOGD("ble_adv", " power_raw - %i", power_raw );
ESP_LOGD("ble_adv", " energy_raw - %i", energy_raw );
float power = float(power_raw)/float(impulses_raw) * 60.0 * 2500;
float energy = float(energy_raw)/float(impulses_raw);
id(inode_power).publish_state(power);
id(inode_energy).publish_state(energy);
id(inode_impulses).publish_state(impulses_raw);
sensor:
platform: ble_rssi
mac_address: "D0:F0:18:78:0B:C1"
name: "inode"
platform: uptime
id: socket_uptime
name: "Uptime"
icon: mdi:clock-outline
update_interval: 60s
platform: wifi_signal
id: socket_wifi_signal
name: "WiFi Signal"
update_interval: 30s
platform: template
name: "inode_power"
id: inode_power
unit_of_measurement: "W"
accuracy_decimals: 3
icon: "mdi:flash"
platform: template
name: "Total Energy"
id: inode_energy
unit_of_measurement: 'kWh'
accuracy_decimals: 3
icon: "mdi:flash"
platform: template
name: "Impulses"
id: inode_impulses
unit_of_measurement: 'imp/kWh'
accuracy_decimals: 0
platform: total_daily_energy
name: "Total Daily Energy"
power_id: inode_power
unit_of_measurement: kW
filters:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.