I don’t think the Senec provides those values. In the past, you could open up vars.html and check all the different parameters the system is giving out, but access to those files has since been stripped. Senec is working hard to make the life of us very hard.
I’d suggest to access your solar inverter directly - it can probably provide you with much more and accurate values than the senec system.
Hi, what do you mean by “solar inverter directly”?
The senec battery box is connected to our network and provides a simple web interface, were I can see the values od all 3 mpp’s.
I am now trying to define a scraper to extract the values from this page, but that does not yet work
Anyone here that could help extracting the MPP data from the senec system?
Scraper from the Webpage or the Vars.html? Or maybe the JSON from lala.cgi ?
You mean something like:
curl -d "{\"PV1\":{}}" http://YOUR_IP/lala.cgi
I am one step further:
- sensor:
unique_id: senec001
name: senec_mpp_test
command: 'curl -d "{\"PV1\":{}}" http://192.168.1.247/lala.cgi'
scan_interval: 300
value_template: "{{ value_json.value }}"
json_attributes:
- PV1
and I get this in the sensor:
friendly_name: senec_mpp_test
PV1:
ERROR_STATE_INT:
- u3_00000000
- u3_00000000
INTERNAL_INV_ERROR_TEXT:
- st_
- st_
*-------- cut ------------*
MPP_AVAIL: u8_03
MPP_CUR:
- fl_40AF53F8
- fl_41274BC7
- fl_4102F1AA
MPP_POWER:
- fl_44E20E1D
- fl_451515D8
- fl_44CF41B3
MPP_VOL:
- fl_43A69169
- fl_4366D894
- fl_434AAD0F
POWER_RATIO: fl_42C80000
Any hints for the MPP_POWER values and these in a right format?
One more Step:
command_line:
- sensor:
unique_id: senec002
name: senec_mpp
command: 'curl -d "{\"PV1\":{}}" http://192.168.1.247/lala.cgi'
scan_interval: 60
value_template: "{{ value_json.PV1.MPP_POWER[1] }}"
json_attributes:
- result
but still no right number:
fl_43F54001
could that be: IEEE-754 ?
How can I convert this in decimal?
Seems to work with this:
Commandline sensor - json - value in IEEE-754(?) to decimal?
Hi there,
since I needed some more detailed information, I started to develop a new integration, targeting the Senec V3 devices.
Currently supported features:
- Set and update the Host/IP of the Senec V3 device in your local network
- Set and update the update interval of the sensors
- Use data for the Home Assistant Energy Dashboard
Example of currently provided data:
- Device information like the system state, operating hours, number of installed batteries, number of available mpps
- Battery information like the number of cyles, current fuel charge, charging/discharging power
- Temperature information for the mcu, case, battery (for each battery module)
- Energy data like current pv production (sum and for each provided mpp), house consumption, grid data
A quick disclaimer: I’m sharing the integration, since it probably helps to get some desired data. But please keep in mind, that this is my first integration for HomeAssistant and my first python project at the same time. The integration is in a very early development phase and currently just a prof of concept regarding the functionality. Several things like a propper error handling have to be added. Use this experimental integration at own risk.
Hi all,
if you like to some local experiments (like making MMP’s data available in HA or connect your build-in inverters and directly access the available data) - have fun with this fork I have created in the past month to get frequent (5sec) data from your HomeV3 - as usual - do all on your won risk!
do you want to join forces? - on the one hand it’s a bit sad, that on the original repro there seams to be no activity in the last year - and I agree - there is the “need for more data (more frequent)” - so when my Senec was installed at the basement, I did more or less exactly the same as you did - also with identical challenges - first python project - first ha integration project.
In the latest version I also integrated access to the internal inverts (if you will wire them to your LAN)
let me know what you think…
@marq24 , sure lets try to set up something together.
Just to be honest in advance: I currently don’t have a lot of time. So I can’t promise to spend much time on this topic, even if I would love to.
I updated the integration.
- Now its possible to request data via https to reflect the latest changes of Senec
- During Setup you can select which sensors/data you would like to receive from the device (first poc)
Hi,
first of all thank you for your effort.
Your version number looks a bit risky to me.
Why you used 0.0.2-alpha?
Is it based on the fork from marq24 or from the original one
Have you changed more than the https access?
Has anyone else checked this version?
Thx for your feedback.
Hi @HA0815 ,
as mentioned above I developed the integration as my first python project, since there was no better solution. Nevertheless I decided to unpublish my repository and to contribute at the work of @marq24.
Working together we hopefully will be able to develop and maintain one good integration rather than several “hobby” projects.
Therefore I would recommend using the following integration: GitHub - marq24/ha-senec-v3: SENEC.Home V2.x/V3/V4 Integration for Home Assistant
Is the switch possible without loosing existing data?
Hi all
yesterday I switched to the fork of marq24 and io-debug.
I had issues to install the integration within HACS (whyever), but manually replacing the senec folder in custom_components was successfully.
They used the same existing variable names, so I still have my history of the “old” integration.
Also the HTTPS works perfect ==> deletion of the old integration + new created with HTTPS
The additional parameters (e.g. solar power per MPP) are very helpfull to me.
However I have one issue: all energy parameters (unit = kWh) show VARIABLE_NOT_FOUND.
@marq24 & @io-debug could you please help to figure out why this is the case?
(most likely I can create new template variables, but would be good to get the parameters directly from the senec hardware)
@Fugazzy: Have you already installed the component and do you also have the issue mentioned above that the energy parameters show “VARIABLE_NOT_FOUND” ?
Yes, that is an issue with the new version of the Senec firmware.
There is a workaround in the issues part on GitHub of this integration.
Found it thx: