Hooking up the UVR1611 via BLNET

Hi @StephanChrist100

For my HA running on Intel NUC, I installed the BLnet Integration from HACS and configured my configuration.yaml like this :

#### UVR1611 Integration #######################################################
blnet:
  # Host address of your blnet
  resource: http://192.168.178.250
  # Poll interval in seconds (Optional, Default: 360)
  scan_interval: 60
  # Expert access password of the web-interface (Optional, Default: None)
  # password: 1234
  # Enable BLNet-Direct access (Broken, Optional, Default: False)
  use_ta: false
  # BLNet-Direct port (Optional, Default: 4000)
  # ta_port: 4000
  # Enable Web interface access (Optional, Default: True)
  # When set to false, switches are configured as sensors
  use_web: true
  # Webinterface port (Optional, Default: 80)
  # web_port: 80
  # Can-Node to be used (Optional, Default: None - doesn't change the current setting at the BLNET)
  can_node: 20

Countercheck this code with the settings of your BLnet.
I suppose there lies the error…

Hope this helps you.

@C64

Thank you for your reply, I appreciate it.

I have now also tried again with your configuration.yaml, where I have only entered the IP address of my BLnet. Same spectacle :

Home Assistant Core

2023-09-16 10:32:55.833 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration blnet which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant

2023-09-16 10:33:04.083 ERROR (MainThread) [homeassistant.setup] The blnet integration does not support YAML setup, please remove it from your configuration

2023-09-16 10:33:04.090 ERROR (MainThread) [homeassistant.setup] Setup failed for custom integration blnet: No setup or config entry setup function defined.

I run HA als on an Intel NUC, but what did you mean “i installed the BLnet Integration from HACS” ?
I install HACS and then i copy the 4 file in the components folder :
image

@C64
The configuration.yaml looks like this :

@C64

wenn ich die configurations.yaml so einstelle, dann bekomme ich folgendes :
image

I took the files which fit to V0.9.1.

Somehow I am going in circles here.

if you could describe briefly what to install and in what order, then I would be very grateful. ( I am a complete beginner :wink:

Hi @StephanChrist100
It seems you are missing the BLnet repository on your Home Assistant :wink:

You must install the BLnet integration as a custom repository in HACS!
To achieve this, follow these steps:

  • You must have HACS integration already installed.
  • Navigate to the HACS “INTEGRATION” page
  • On this page, click the 3 dots (top right corner of this page).
  • Select custom repositories (oder auf Deutsch: Benutzerdefinierte Repositories)
  • In the next program window you must enter the link to the Github repository for BLnet.
    Put in this link: https://github.com/nielstron/ha_blnet
  • Under Category select “INTEGRATION”
  • Click “ADD”.
  • Now the BLnet integration will be added to HACS and will appear under the HACS Integration page on your Home Assistant.
  • Possibly, you have to reload or reboot your system.

After that, I think your problem will be solved.
regards

@C64
Yeah, :+1: you are right. Now it looks much better, no fault message anymore. Now I struggling with the can node address and how to see values.
May you can let me know, where I can found the values, if it works.
But I’m so happy you help me.
Many thanks.

your welcome,

  • In your internet browser put in the IP of your BL-Net.
  • You will see the web front end of the BL-Net.
  • Go to “CAN-BUS”
  • There you will see the can node address of your BL-Net which you must define in your configuration.yaml

You can also check the LAN configuration of your BL-Net under “Ethernet”.
There, you can check the port configuration.
→ The BL-Net integration in Home Assistant usees port 80 by default !! If you use another port number, you must define it in the configuration.yaml (see my yaml code) !

Hope this helps.

@C64
now in HA no fault message anymore, everythings Looks fine, but i cannot seen any value.
in HA. I adjust the can node address to 1, because its shown in the blnet menu, like you show before. Where the sensors should be seen in HA ?

Sorry for so many question.

@C64
i found now in the protokoll
Dieser Fehler wurde von einer benutzerdefinierten Integration verursacht

Logger: homeassistant
Source: custom_components/blnet/init.py:146
Integration: BLNET (documentation)
First occurred: 09:55:24 (3 occurrences)
Last logged: 10:01:27

Error doing job: Future exception was never retrieved
Traceback (most recent call last):
File “/usr/local/lib/python3.11/concurrent/futures/thread.py”, line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/config/custom_components/blnet/init.py”, line 98, in fetch_data
return hass.data[“DATA_{}”.format(DOMAIN)].update()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/config/custom_components/blnet/init.py”, line 146, in update
data = self.blnet.fetch(self.node)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.11/site-packages/pyblnet/blnet.py”, line 87, in fetch
blnet_session.read_analog_values())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.11/site-packages/pyblnet/blnet_web.py”, line 194, in read_analog_values
data_raw = dom.text()
^^^^^^^^
AttributeError: ‘NoneType’ object has no attribute ‘text’

Hi,
regardless of the error messages in your next post, which unfortunately I can’t really help with because I don’t know what they mean exactly and what causes them, you will find the BLnet sensors like all other sensors in HA, if the integration is installed correctly and well configured.
Either you place an entity card and select the BLnet entities there or place a card “by entity” where you can select the desired entities and let HA generate the card itself.
But since there is still an error in your HA, I think that something is still wrong and therefore no entities are available.
I think the BLnet integration programmer could be more helpful here…, sorry
regards,

File “/usr/local/lib/python3.11/site-packages/pyblnet/blnet_web.py”, line 194, in read_analog_values
data_raw = dom.text()
^^^^^^^^
AttributeError: ‘NoneType’ object has no attribute ‘text’

This error should be handled internally to bubble up as “BLNET could not be reached” and simply means that the BLNET could not be reached - either the IP Adress is wrong or the port or it simply does not respond in time or…

@StephanChrist100 I just noticed you must be using an outdated version of this custom component (the one linked in the main post which I can’t seem to update anymore). Please set up the custom component via HACS from this repository: GitHub - nielstron/ha_blnet: BLNET custom component for Home Assistant

@nielstron
@C64
OK, thank you for your answers. Yes, maybe i mess the system up, which change the files a couple times and so on. As im on the beginning with HA, i will shortly install the HA complete new. But may i can ask the right procedure :

  • first install HACS, restart
  • then directly install the custom integration blnet, from your link you show in the last post, restart
  • enter the settings in the configurations.yaml, restart
  • thats it , right ?

can i ignore the hacs.jason File, or i have to copy it somewhere ?

For now, i updatetd the files to the latest, i install the custom integration new, i have no fault messages, accept # it takes longer the 10 sec. , but i never seen any value from the UVR1611.

I will test the Blnet, if the old system still can read datas. i Have the feeling the BLNet could be the problem (?).

Hi Stephan,

Yes that’s the right way to install HACS and the BLnet integration.
If you install the BLnet integration via HACS by using the custom repository function, where you have to put in the github link, there is no need to add any files by hand to your Home Assistant !!

For the last part of your message, whith the wayting time…, is that after reinstalling Home Assistant or still on your old system?

If your BLnet works fine, with access via web browser and shows the needed data there, I think that the BLnet is ok.

One question to be on the safe side…
You have no access restricion configured via firewall in yout network…!?

@C64
I just reinstalled everything, same thing again. No error messages except when I turn off the BLnet. Then I get error messages that say that the BLnet is not accessible. the Blnet is accessible via the web, but noticeable is that the scheme (GRAPHIK) can not be loaded…It seems for me the Bl-Net is not working anymore…

Just for info an clarification…
does you have designed a graphic and uploaded them with the appropriated data file (think it’s an xml file) to your BLnet?
Without that, you cannot see a scheme on the web page from your BLnet!
But that will not be an issue for the integration of your BLnet in Home Assistant.

@C64 yes, around 10 years ago, i loaded a scheme on the web-page at the BLnet, since i startet with HA it works perfectly, now not anymore. Until last week i collect the datas with the old datenx tool and send them to mqtt, even that is not working anymore. Everythings strange. I believe the integration is fine - no error message until i switch off the Blnet.

If you suspect a problem with the BL-net, then I would perform a factory reset on the BL-Net and reconfigure it.
But before beginning, be sure that you still have all the programs you need, as well as your personal project file of your UVR project.
Also be sure that these programs can run on your PC (operating system used), because BL-net and the required tools are quite old and may perhaps no longer run on the latest operating system…!

For reset see:

@C64
@nielstron
1 step forward again : the BL-Net is working again, like it should, reason i adjust the BLnet Can adress back to 62, meanwhile may i playing around and set it to 1. Now i see the scheme again and also values in the menu of can address 1 which is the UVR1611.
However, still no values in the HA, but also no fault messages regarding the BL-Net.
Again, where exactly should i find the values, should something popup when the value are read ?


Or should new device found ?

@C64
@nielstron
if i set the can-node to 20 in configuration.yaml, i can see in the BL-net that is also set the 20 - so the HA did control the BL-Net, but still no values…
now, i have the feeling, that i dont now, how to read the values in HA.