Closed sjampeter closed 6 months ago
Please post the appdaemon log while this issue happens
i posted the requested logs.
It looks like the brightness value is None
can you see this in the developer tools on homeassistant too?
hmm. i dont think that this is the issue here. the light works perfect white one nspanel. the problem occurs when i want to put the same entitie on the second panel.
Each panel has a separate appdaemon instance, they are isolated from each other.
It probably doesn't make a lot of sense to dig deeper into this, as the next release will be no longer based on appdaemon.
Would you try the new backend? #1058
Note that the list style sleepBrightness is currently not implemented - you can use an input_number instead with an automation.
hmm. i will look into it. will take a bit of time to try this. i will inform you with my findings. thanks...
the new backend seems to work fine. issue resolved. thanks for the fast response.
PROBLEM DESCRIPTION
I would like to use multiple panels with some of the same light-entities and some different light entities. when putting the same light- entitie in both configurations, the panels get locked.
REQUESTED INFORMATION
[x] Provide your apps.yaml (or your config):
nspanel-2: module: nspanel-lovelace-ui class: NsPanelLovelaceUIManager config: panelRecvTopic: "tele/NSPanel_keuken/RESULT" panelSendTopic: "cmnd/NSPanel_keuken/CustomSend" model: eu sleepTimeout: 0 sleepBrightness:
time: "7:00:00" value: 10
time: "23:00:00" value: 0 locale: "nl_NL" screensaver: entities:
entity: weather.inieuw133 icon: mdi:home-thermometer-outline
entity: weather.buienradar type: 0
entity: weather.buienradar type: 1
entity: weather.buienradar type: 2
entity: weather.buienradar type: 3
entity: sensor.temperatuur_woonkamer_si7021_2 icon: mdi:temperature-celsius
cards:
cards:
type: cardEntities entities:
entity: light.woonkamer_spotjes_bank name: spotjes bank
title: Lichten woonkamer
type: cardThermo entity: climate.bijkeuken title: Airco bijkeuken
type: cardQR title: Guest Wifi qrCode: "WIFI:S:##################;T:WPA;P:#################;;" entities:
Log output here: `2023-12-27 13:53:01.849455 WARNING nspanel-2: ------------------------------------------------------------ 2023-12-27 13:53:07.087472 INFO nspanel-2: MQTT callback for: {'topic': 'tele/NSPanel_keuken/RESULT', 'wildcard': None, 'payload': '{"CustomRecv":"event,sleepReached,cardEntities"}'} 2023-12-27 13:53:07.090487 INFO nspanel-2: Received Message from Screen: event,sleepReached,cardEntities 2023-12-27 13:53:07.094621 INFO nspanel-2: Button Press Event; entity_id: cardEntities; button_type: sleepReached; value: None 2023-12-27 13:53:07.097699 INFO nspanel-2: Sending MQTT Message: pageType~screensaver 2023-12-27 13:53:07.102798 INFO nspanel-1: Sending MQTT Message: timeout~15 2023-12-27 13:53:07.114708 INFO nspanel-2: Sending MQTT Message: timeout~5 2023-12-27 13:53:07.241869 INFO nspanel-1: Sending MQTT Message: weatherUpdate
~���~38066~INIEUW133~9.8��C~���~12703~do~11.0��C~���~12703~vr~12.0��C~���~12703~za~11.0��C~���~12703~zo~10.0��C~���~17299~temperatuur woonkamer SI7021.2~19.20 ��C 2023-12-27 13:53:07.254559 INFO nspanel-1: Sending MQTT Message: statusUpdate~~ 2023-12-27 13:53:07.277600 INFO nspanel-2: Sending MQTT Message: weatherUpdate~���~38066~INIEUW133~9.8��C~���~12703~do~11.0��C~���~12703~vr~12.0��C~���~12703~za~11.0��C~���~12703~zo~10.0��C~���~17299~temperatuur woonkamer SI7021.2~19.20 ��C 2023-12-27 13:53:07.292981 INFO nspanel-2: Sending MQTT Message: statusUpdate~~ 2023-12-27 13:53:07.321214 INFO nspanel-2: Sending MQTT Message: timeout~5 2023-12-27 13:53:07.383481 INFO nspanel-2: Sending MQTT Message: weatherUpdate~���~38066~INIEUW133~9.8��C~���~12703~do~11.0��C~���~12703~vr~12.0��C~���~12703~za~11.0��C~���~12703~zo~10.0��C~���~17299~temperatuur woonkamer SI7021.2~19.20 ��C 2023-12-27 13:53:07.388696 INFO nspanel-2: Sending MQTT Message: statusUpdate~~ 2023-12-27 13:54:00.119186 INFO nspanel-1: Sending MQTT Message: time~13:54~ 2023-12-27 13:54:00.135703 INFO nspanel-2: Sending MQTT Message: time~13:54~ 2023-12-27 13:54:07.376535 INFO nspanel-2: Sending MQTT Message: timeout~5 2023-12-27 13:54:07.380550 INFO nspanel-1: Sending MQTT Message: timeout~15 2023-12-27 13:54:07.482789 INFO nspanel-1: Sending MQTT Message: weatherUpdate~���~38066~INIEUW133~9.8��C~���~12703~do~11.0��C~���~12703~vr~12.0��C~���~12703~za~11.0��C~���~12703~zo~10.0��C~���~17299~temperatuur woonkamer SI7021.2~19.23 ��C 2023-12-27 13:54:07.492976 INFO nspanel-1: Sending MQTT Message: statusUpdate~~ 2023-12-27 13:54:07.505839 INFO nspanel-2: Sending MQTT Message: weatherUpdate~���~38066~INIEUW133~9.8��C~���~12703~do~11.0��C~���~12703~vr~12.0��C~���~12703~za~11.0��C~���~12703~zo~10.0��C~���~17299~temperatuur woonkamer SI7021.2~19.23 ��C 2023-12-27 13:54:07.512247 INFO nspanel-2: Sending MQTT Message: statusUpdate~~ 2023-12-27 13:54:49.166845 INFO nspanel-2: MQTT callback for: {'topic': 'tele/NSPanel_keuken/RESULT', 'wildcard': None, 'payload': '{"CustomRecv":"event,buttonPress2,screensaver,bExit,1"}'} 2023-12-27 13:54:49.170231 INFO nspanel-2: Received Message from Screen: event,buttonPress2,screensaver,bExit,1 2023-12-27 13:54:49.176410 INFO nspanel-2: Button Press Event; entity_id: screensaver; button_type: bExit; value: 1 2023-12-27 13:54:49.218446 INFO nspanel-2: Sending MQTT Message: pageType~cardEntities 2023-12-27 13:54:49.226476 INFO nspanel-2: Sending MQTT Message: timeout~5 2023-12-27 13:54:49.241676 WARNING nspanel-2: ------------------------------------------------------------ 2023-12-27 13:54:49.242161 WARNING nspanel-2: Unexpected error in worker for App nspanel-2: 2023-12-27 13:54:49.243303 WARNING nspanel-2: Worker Ags: {'id': '1f4ebabd54a54f7caffe0c21f3a2bedd', 'name': 'nspanel-2', 'objectid': 'cdbf74debbc54e95b171d0fbcc044d27', 'type': 'event', 'event': 'MQTT_MESSAGE', 'function': <bound method LuiMqttListener.mqtt_event_callback of <luibackend.mqtt.LuiMqttListener object at 0x7f2223a8fa10>>, 'data': {'topic': 'tele/NSPanel_keuken/RESULT', 'wildcard': None, 'payload': '{"CustomRecv":"event,buttonPress2,screensaver,bExit,1"}'}, 'pin_app': True, 'pin_thread': 1, 'kwargs': {'topic': 'tele/NSPanel_keuken/RESULT', '__thread_id': 'thread-1'}} 2023-12-27 13:54:49.243548 WARNING nspanel-2: ------------------------------------------------------------ 2023-12-27 13:54:49.247579 WARNING nspanel-2: Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/appdaemon/threading.py", line 1095, in worker funcref(args["event"], data, self.AD.events.sanitize_event_kwargs(app, args["kwargs"])) File "/homeassistant/appdaemon/apps/nspanel-lovelace-ui/luibackend/mqtt.py", line 57, in mqtt_event_callback self._controller.button_press(entity_id, btype, value) File "/homeassistant/appdaemon/apps/nspanel-lovelace-ui/luibackend/controller.py", line 234, in button_press self._pages_gen.render_card(self._current_card) File "/homeassistant/appdaemon/apps/nspanel-lovelace-ui/luibackend/pages.py", line 739, in render_card self.generate_entities_page(navigation, card.title, card.entities, card.cardType, temp_unit) File "/homeassistant/appdaemon/apps/nspanel-lovelace-ui/luibackend/pages.py", line 428, in generate_entities_page command += self.generate_entities_item(item, cardType, tempUnit) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/homeassistant/appdaemon/apps/nspanel-lovelace-ui/luibackend/pages.py", line 253, in generate_entities_item color = self.get_entity_color(entity, ha_type=entityType, overwrite=colorOverride) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/homeassistant/appdaemon/apps/nspanel-lovelace-ui/luibackend/pages.py", line 102, in get_entity_color color = rgb_brightness(color, attr.brightness) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/homeassistant/appdaemon/apps/nspanel-lovelace-ui/luibackend/helper.py", line 34, in rgb_brightness brightness = int(scale(brightness,(0,255),(70,255))) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/homeassistant/appdaemon/apps/nspanel-lovelace-ui/luibackend/helper.py", line 9, in scale return ((val - src[0]) / (src[1]-src[0])) * (dst[1]-dst[0]) + dst[0]