BSB-Lan integration

Awesome, that works perfectly, looks like I just had a few wrong quotation marks and slashes.
Even better than the JSON-examples, as this had a timing/status issue for me (switch set to off, but is reverted to on after a few secons, until the next sensor update is received).
I had expected this also here (as I currently only update the values every 30 secs. via MQTT), but in a first test that did not occur.
With this I might then be able to completely get rid of the JSON and only use MQTT.

1 Like

I am facing an issue with updating a value via MQTT with the input from a helper value.

I have an ipnut number to adjust the wanted temperature:

And I have the actual sensor (1610):

I have a working automation that adjusts the input number in case the sensor value is being changed.

But the other way around is not working.
My automation for this is:

alias: HWR - Trinkwasser Nennsollwert Ƥndern
description: ''
trigger:
  - platform: state
    entity_id: input_number.bsb_lan_trinkwasser_nennsollwert
condition: []
action:
  - service: mqtt.publish
    data:
      topic: BSB-LAN
      payload_template: S1610="{{ states('input_number.bsb_lan_trinkwasser_nennsollwert') }}"
mode: single

But now no matter to which value I adjust the input number, the MQTT publishes a value of 8.0 degrees!

I then change it back to 52 in BSB-LAN, the other automation adjusts the input number to 52 as expected, and a few secons later it goes again to 8 degrees! I change it a second time in BSB-LAN, then it remains at 52. So obviously the first automation having changed the input number back to 52 has again triggered the other automation that did another 8 degree publish.
I am puzzled where that value is coming from. The input number state is between 50 and 60. If I use a hard coded payload S1610=55 it changes correctly to 55 degrees, so it is just somehow that it gives back a value of 8 for the input number, even though this is nonsense. Does anyone have a clue what is wrong here?
This is my first try to change a temperature via MQTT.

EDIT: It does not work with

service: mqtt.publish
data:
  topic: BSB-LAN
  payload: S1610={{ states('input_number.bsb_lan_trinkwasser_nennsollwert') }}

So again just a minor quotation mark thing. Still I have no idea why before if used the right payload, but sent a completely wrong value.

As everything works really well so far with MQTT in both directions, also without the integration I meanwhile have a very satisfying setup.
Helps a lot to understand and optimise the heating, especially on warm water. As I always like to see results of others for inspiration:

3 Likes

Hi,
my connection to brƶtje is running since 2h and i tryed first home-assistet integration and see, it doeā€™nt work. I want to try it now your way, with mqtt. i have the latest version from bsb-lan 2.1.3 and mqtt is enabled. Can you share us some configurations for ha?

In BSB-LAN settings:

  • Enable MQTT with plain text
  • Maintain IP address of MQTT server (in my case same as HA)
  • Logging can be left deactivated (unintuitive, that is just logging on the device itself), but maintain log intervall (I have 30 secs) and the numbers of all parameters you want BSB-LAN to publish

In the settings of the MQTT integration, you can check if it generally gets messages of BSB-LAN, the status will then report ā€œonlineā€:

Then in the file editor you can define the sensors for the values you let BSB-LAN publish and also switches for the ones you want to change (grant BSB-LAN write access in its settings). Examples for that are in this thread and also in the BSB-LAN manual in chapter 8.

Update of BSBLAN integration is underway. It doesnā€™t support new firmware version yet but the library is rebuild so it would be quite easy to support multiple versions. If anyone wants to review the pull request?

2 Likes

Are you still working on the integration? If you need someone to test, Iā€™m happy to do that.

1 Like

If someone can check the pull request and do a review. Iā€™ll try to check if one of the developers has time. But if would be great if someone could do a review beforehand.

Is it still for that old version of BSB-LAN?

No/Yes, itā€™s mostly rewritten integration. Still using old firmware as this one is working. Want to push a lib for new version when this one is running properly. This will be a minor update. But the rewrite is quite big so I just need this version to be integrated in home assistant. When I have some extra time Iā€™ll start with hacs. This is taking too long :frowning:

4 Likes

Hi, I try to get through mqtt for example outside temp. I use this in configuration.yaml:

mqtt:
  sensor:
    - name: mqtt temp bsb
      state_topic: "BSB-LAN/8700"
      unit_of_measurement: Ā°C
      device_class: temperature

but state is always unknown. What Iā€™m doing wrong?

Have you set up the BSB-LAN device to publish that topic to your MQTT broker?

@foxx99 ,that 3600 interval means 1 hour, try to reduce it to 60 or 120 for testing.

Still ā€œunknownā€

Edit:
After restarting Windows, temperature just appear.

Can you provide the yaml code for sensor that works with climate entity?

New version of the integration is now in the beta of home assistant. This version does not yet support firmware higher than the v1.1
With a lib update I will implement compatibility with later firmwares. The library will automatically switch to the right parameters for retrieving the right info. Hopefully I can make a pull request soon. Maybe before release :crossed_fingers:

3 Likes

Have you heard about version 3.x?

2.2 is the latest? I didnā€™t make it before the release with a bump for the firmware in the library.

As I see yes, but there is a new way of translation in progress, if you havenā€™t read the discussion yet: