Git Product home page Git Product logo

ha-cc-jablotron-cloud's Introduction

Home_Assistant hacs_badge GitHub

buy me a coffee

Jablotron logo

Jablotron Cloud

HACS custom component for jablotron cloud integration

About

Integration works with MyJablotron web service available on https://www.jablonet.net/. It uses mobile API provided by JablotronPy library. It does not have full capabilities of web interface and some function are not yet supported by the integration. See the list of supported function below.

This component will set up the following platforms.

Platform Description
binary_sensor To show uncontrollable programmable gates (PG) .
switch To controll programmable gates (PG) .
alarm_control_panel To enable ARM/DISARM on individual sections.
sensor To support temperature and electricity sensors.

HACS Installation

  1. Add repository using "+Explore & download repositories" button in HACS inside integrations section
  2. Search for Jablotron Cloud in HACS
  3. Install
  4. In HA add new integration and select Jablotron Cloud.

Manual Installation

  1. Using the tool of choice open the directory (folder) for your HA configuration (where you find configuration.yaml).
  2. If you do not have a custom_components directory (folder) there, you need to create it.
  3. In the custom_components directory (folder) create a new folder called jablotron_cloud.
  4. Download all the files from the custom_components/jablotron_cloud/ directory (folder) in this repository.
  5. Place the files you downloaded in the new directory (folder) you created.
  6. Restart Home Assistant
  7. In the HA UI go to "Configuration" -> "Integrations" click "+" and search for "Jablotron Cloud"

Configuration is done in the UI

To configure integration please fill credentials you use to access your MyJablotron web page or mobile app.

Following fields needs to be filled:

Field Description
username Email associated with Jablotron cloud.
password Password use to login into the webpage.
pin Default pin to controll PG's. User pin can be entered for every section later but at least one pin is required.

Supported functionality

  1. Programmable gates - show status of every programmable gate in your system. PG can be created to signal any state you like by your Jablotron provider. It can indicate you for example that section is armed or that it is armed only partially. It can also tell you state of you garage door or window contact sensors. Most of PG's can be controlled to trigger some Jablotron action.
  2. Sections - every section is individual alarm control panel as it requires PIN codes to control it and can be ARMED (Armed Away) or PARTIALLY ARMED (Armed Home). Section also support friendly names defined in you cloud installation.

Known issues

  1. Data are updated only every 30s
  2. Arming and disarming has no delay to leave the house.
  3. First entity get it's real state ony after 30s. Then it works like any other entity.
  4. Integration does not listen for active alarms

Missing functionality - will be added

  1. Impulse counters
  2. Alarm event detection

Support

Jablotron logo

ha-cc-jablotron-cloud's People

Contributors

pigotka avatar fdegier avatar koky05 avatar

Stargazers

 avatar  avatar  avatar Domenico Rescigno avatar  avatar Matus Holka avatar Janne R. avatar  avatar Martin Kuneš avatar  avatar  avatar

Watchers

 avatar Michal Kapusnik avatar  avatar  avatar  avatar

Forkers

koky05

ha-cc-jablotron-cloud's Issues

Unable to retrieve session_id

Hi,

Jablotron Cloud has been working fine for me for a while now, but today this issue showed up out of nowhere:

2023-11-03 20:04:27.480 WARNING (MainThread) [homeassistant.config_entries] Config entry 'Jablotron Cloud' for jablotron_cloud integration not ready yet: Unable to retrieve session_id.; Retrying in background
2023-11-03 20:04:32.648 ERROR (MainThread) [custom_components.jablotron_cloud] Unexpected error fetching Jablotron data: Unable to retrieve session_id.
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 290, in _async_refresh
self.data = await self._async_update_data()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/jablotron_cloud/__init__.py", line 91, in _async_update_data
self.session_id = await self.hass.async_add_executor_job(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 96, in get_session_id
raise UnexpectedResponse("Unable to retrieve session_id.")
jablotronpy.jablotronpy.UnexpectedResponse: Unable to retrieve session_id.

Is this rate limiting by Jablotron or something else?

Unable to complete setup - stuck in HA at "starting configuration wizzard"

Hi All

I am very happy to see a possiblity to integrate jablotron into my home assistant. I have added Jablotron Cloud in HACS and tried to add the integration in HA. When I select it from the list of integrations it unfortunatley does not work. It gets stuck before the very fist screen loads. See this screenshot:

image

any suggestions?

Entities do not show up with multiple connected homes

Hi,
I tried your custom integration and everything seems to be fine but I don't have any entities being created. I do have 2 homes connected in my account. When I log into the Jablotron portal, I need to select a home first before accessing the panels and sections. Could this be related?

.

.

Unable to login

Hey,
I have been using this integration quite some time but since this week the integration fails. It says it fails to authenticate although the credentials are correct. Any other issues with this?

I saw the post about the new terms, but I can’t accept them anywhere if I login in the jablotron cloud…
Could this be the issue?

regards,

error while arming/disarming the alarm

error while arming/disarming the alarm

Core 2024.5.4
Supervisor 2024.05.1
Operating System 12.2

2024-05-18 14:57:50.479 WARNING (SyncWorker_2) [homeassistant.helpers.frame] Detected that custom integration 'jablotron_cloud' calls async_write_ha_state from a thread at custom_components/jablotron_cloud/alarm_control_panel.py, line 160: self.async_write_ha_state(), please report it to the author of the 'jablotron_cloud' custom integration
2024-05-18 14:57:50.480 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140587662372800] Unexpected exception
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 239, in handle_call_service
response = await hass.services.async_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2738, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2779, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 975, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1047, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/alarm_control_panel/init.py", line 175, in async_alarm_disarm
await self.hass.async_add_executor_job(self.alarm_disarm, code)
File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/jablotron_cloud/alarm_control_panel.py", line 160, in alarm_disarm
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1008, in async_write_ha_state
self.hass.verify_event_loop_thread("async_write_ha_state")
File "/usr/src/homeassistant/homeassistant/core.py", line 440, in verify_event_loop_thread
frame.report(
File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 162, in report
_report_integration(what, integration_frame, level, error_if_integration)
File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 203, in _report_integration
raise RuntimeError(
RuntimeError: Detected that custom integration 'jablotron_cloud' calls async_write_ha_state from a thread at custom_components/jablotron_cloud/alarm_control_panel.py, line 160: self.async_write_ha_state(). Please report it to the author of the 'jablotron_cloud' custom integration.

Infinite recursion when adding entry

Hi, I just installed the integration and added my user/pass/pin details. As nothing related to my system is shown I checked in the logs.

And it goes into an infinite recursion.

Any ideas? Thanks.

2023-06-12 20:57:24.172 ERROR (MainThread) [custom_components.jablotron_cloud.config_flow] Unexpected exception
Traceback (most recent call last):
File "/config/custom_components/jablotron_cloud/config_flow.py", line 59, in async_step_user
info = await validate_input(self.hass, user_input)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/jablotron_cloud/config_flow.py", line 34, in validate_input
await hass.async_add_executor_job(hub.get_session_id)
File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 88, in get_session_id
status, data = self._make_request(
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 66, in _make_request
self.set_cookies()
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 36, in set_cookies
session_id = self.get_session_id()
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 88, in get_session_id
status, data = self._make_request(
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 66, in _make_request
self.set_cookies()
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 36, in set_cookies
session_id = self.get_session_id()
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 88, in get_session_id
status, data = self._make_request(
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 66, in _make_request
self.set_cookies()
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 36, in set_cookies
session_id = self.get_session_id()
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 88, in get_session_id
status, data = self._make_request(
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 66, in _make_request
self.set_cookies()
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 36, in set_cookies
session_id = self.get_session_id()
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 88, in get_session_id
status, data = self._make_request(
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 66, in _make_request
self.set_cookies()
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 36, in set_cookies
session_id = self.get_session_id()
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 88, in get_session_id
status, data = self._make_request(
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 66, in _make_request
self.set_cookies()
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 36, in set_cookies
session_id = self.get_session_id()
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 88, in get_session_id
status, data = self._make_request(
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 66, in _make_request
self.set_cookies()
File "/usr/local/lib/python3.11/site-packages/jablotronpy/jablotronpy.py", line 36, in set_cookies
session_id = self.get_session_id()
^^^^^^^^^^^^^^^^^^^^^

(.....)\

File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 115, in post
return request("post", url, data=data, json=json, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/requests/api.py", line 59, in request
return session.request(method=method, url=url, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 589, in request
resp = self.send(prep, **send_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/requests/sessions.py", line 703, in send
r = adapter.send(request, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 454, in send
conn = self.get_connection(request.url, proxies)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/requests/adapters.py", line 356, in get_connection
conn = self.poolmanager.connection_from_url(url)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/poolmanager.py", line 299, in connection_from_url
return self.connection_from_host(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/poolmanager.py", line 246, in connection_from_host
return self.connection_from_context(request_context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/poolmanager.py", line 261, in connection_from_context
return self.connection_from_pool_key(pool_key, request_context=request_context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/poolmanager.py", line 282, in connection_from_pool_key
pool = self._new_pool(scheme, host, port, request_context=request_context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/poolmanager.py", line 214, in _new_pool
return pool_cls(host, port, **request_context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 949, in __init__
HTTPConnectionPool.__init__(
File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 191, in __init__
ConnectionPool.__init__(self, host, port)
File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 86, in __init__
self.host = _normalize_host(host, scheme=self.scheme)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/connectionpool.py", line 1111, in _normalize_host
host = normalize_host(host, scheme)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/util/url.py", line 300, in _normalize_host
b".".join([_idna_encode(label) for label in host.split(".")])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/util/url.py", line 300, in <listcomp>
b".".join([_idna_encode(label) for label in host.split(".")])
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/util/url.py", line 306, in _idna_encode
if name and any(ord(x) >= 128 for x in name):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/urllib3/util/url.py", line 306, in <genexpr>
if name and any(ord(x) >= 128 for x in name):
^^^^^^
RecursionError: maximum recursion depth exceeded while calling a Python object

Devices unavailable

Hello,

I’m using this integration in few automations but I frequently receive the status unavailable from several components. Is this a know issue or do I have to adjust polling intervals or something?

Controlling the sections/zones are no problem. Just if I want to check for the current state, it tells me it’s unavailable…
kind regards.

Can't login after update to 0.5.4

Update via HACS, had to drop the integration and add it again. Now it doesn't accept my email/password. I am getting "Invalid authentication" error. Verified the credentials work on https://www.jablonet.net/ and in my mobile app. I can see ony this in ha log:
2023-11-21 21:34:23.545 ERROR (ThreadPoolExecutor-9_0) [custom_components.jablotron100] State packet of unknown device (device 3): 55088075c000518b5609

No devices or entities

Hello, first of all thank's for your job.

I was able to install the integration and enter the credentials correctly without problems. But there is no way to show the devices and identities. Some help?

image

Unable to complete setup - Initializing - Retrying setup loop

I am unable to complete setup due to the following error:
Config entry 'Jablotron Cloud' for jablotron_cloud integration not ready yet; Retrying in background.

On the Integration page, the status is switching between Initializing - Retrying setup

image
image

My login credentials are correct and I have verified them by the following script, which returns all values:

import json
import requests, pickle

username = "MyUserName"
password = "MyPasswork"
cookiefile = "jabcookie"

class jablotron():

def _save_cookies(requests_cookiejar, filename):
    with open(filename, 'wb') as f:
        pickle.dump(requests_cookiejar, f)

def _load_cookies(filename):
    with open(filename, 'rb') as f:
        return pickle.load(f)

url1 = 'https://www.jablonet.net/ajax/login.php'
payload1 = {'login':  username,
          'heslo': password,
          'aStatus': '200',
          'loginType': 'Login'}
data1 = requests.post(url1, data=payload1)
_save_cookies(data1.cookies, cookiefile)

json = json.loads(data1.text)
reload = json['reload']
status = json['status']

if status == 200:
    service_id = reload.split('?service=')[1]
    
    url2 = 'https://www.jablonet.net/app/ja100?service=' + service_id
    data2 = requests.get(url2, cookies=_load_cookies(cookiefile))

    url3 = 'https://www.jablonet.net/app/ja100/ajax/stav.php'
    data3 = requests.get(url3, cookies=_load_cookies(cookiefile))
    print(data3.text)
else:
    print (f"No valid page, probably got redirected because of wrong password")

Any suggestions are welcomed.

0.6.0 does not log in when a user does not have any programmable gates

when trying to log in with the 0.6.0 version I only get:

2024-06-17 12:12:37.407 DEBUG (MainThread) [custom_components.jablotron_cloud] Preparing Jablotron data update coordinator
2024-06-17 12:12:39.433 DEBUG (MainThread) [custom_components.jablotron_cloud] Failed to get gates data for service <service id>
2024-06-17 12:12:39.433 DEBUG (MainThread) [custom_components.jablotron_cloud] Finished fetching Jablotron Cloud data in 2.025 seconds (success: False)

It fails on this line

calling the get_programmable_gates manually using jablotronpy library, it returns {'service-states': {'last-event-time': '2024-06-17T12:08:29+0200', 'service-name': '<name>'}, 'states': []} (with adding print(data) there) and raises the exception here

In the jablotron UI I only have 1 section and 1 keypad - previously I used the section to arm/disarm the alarm using this integration

No sensors and sections detected, only PGs

Hi,
I used the Jablotron Cloud for the very first time today so maybe I am doing something wrong.
I successfuly connect to my Jablotron Cloud account bu only PG outputs are discovered.
I hoped I could see status of individual motion sensors or at least status Armed/DIsarmed for the alarm (section).
But none of them is visible.
I also have two other equipment under MyJablotron (Coolbreeze and Volta) but thouse are not connected to alarm (anly ventilation and heating).
Thanks for the help.
Ondrej

Here is the log:
2023-11-25 09:17:20.039 DEBUG (MainThread) [custom_components.jablotron_cloud] Preparing Jablotron data update coordinator 2023-11-25 09:17:20.693 DEBUG (MainThread) [custom_components.jablotron_cloud] Opened new session: ohnatpftsnormpn57f3aog1t21 2023-11-25 09:17:23.038 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving programmable gates for 2215009 2023-11-25 09:17:23.264 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving sections for 2215009 2023-11-25 09:17:23.501 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving thermo devices for 2215009 2023-11-25 09:17:23.501 DEBUG (MainThread) [custom_components.jablotron_cloud] Service 2215009 discovered. Data: {'service': {'service-id': 2215009, 'cloud-entity-id': 'SERVICE_FUTURA2:2215009', 'name': 'FUTURA', 'service-type': 'FUTURA2', 'icon': 'VENTILATION', 'index': 1000000, 'level': 'FULL', 'status': 'ENABLED', 'visible': True, 'message': 'OK', 'event-last-time': '2023-11-25T09:17:02+0100', 'share-status': 'OWNER_SHARED', 'service-blocked': 'NONE', 'extended-states': [{'type': 'RECUPERATION_MODE_AUTO'}, {'type': 'RECUPERATION'}], 'notifications': 0}, 'gates': {}, 'sections': {}, 'thermo': {}} 2023-11-25 09:17:23.759 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving programmable gates for 2215014 2023-11-25 09:17:24.045 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving sections for 2215014 2023-11-25 09:17:24.269 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving thermo devices for 2215014 2023-11-25 09:17:24.270 DEBUG (MainThread) [custom_components.jablotron_cloud] Service 2215014 discovered. Data: {'service': {'service-id': 2215014, 'cloud-entity-id': 'SERVICE_VOLTA:2215014', 'name': 'VOLTA-E', 'service-type': 'VOLTA', 'icon': 'HEATING', 'index': 1000000, 'level': 'FULL', 'status': 'ENABLED', 'visible': True, 'message': 'OK', 'event-last-time': '2023-11-25T09:17:05+0100', 'share-status': 'OWNER_SHARED', 'service-blocked': 'NONE', 'extended-states': [{}, {'type': 'STANDBY'}], 'notifications': 0}, 'gates': {}, 'sections': {}, 'thermo': {}} 2023-11-25 09:17:26.566 DEBUG (MainThread) [custom_components.jablotron_cloud] Service 2285638 discovered. Data: {'service': {'service-id': 2285638, 'cloud-entity-id': 'SERVICE_JA100F:2285638', 'name': 'ALARM', 'service-type': 'JA100F', 'icon': 'JA100F', 'index': 1000000, 'level': 'FULL', 'status': 'ENABLED', 'visible': True, 'message': 'OK', 'event-last-time': '2023-11-18T08:53:34+0100', 'share-status': 'OWNER_SHARED', 'service-blocked': 'NONE', 'extended-states': [{'type': 'ARM', 'value': '1'}, {'type': 'DISARM', 'value': '0'}], 'notifications': 0}, 'gates': {'service-states': {'last-event-time': '2023-11-25T08:41:22+0100', 'service-name': 'ALARM'}, 'states': [{'cloud-component-id': 'PG-493753463', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753473', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753488', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753498', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753508', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753523', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753533', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753548', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753558', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753573', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753583', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753593', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753603', 'state': 'OFF'}, {'cloud-component-id': 'PG-493753613', 'state': 'OFF'}], 'programmableGates': [{'cloud-component-id': 'PG-493753463', 'name': 'PG výstup 1', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753473', 'name': 'PG výstup 2', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753488', 'name': 'PG výstup 3', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753498', 'name': 'PG výstup 4', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753508', 'name': 'PG výstup 5', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753523', 'name': 'PG výstup 6', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753533', 'name': 'PG výstup 7', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753548', 'name': 'PG výstup 8', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753558', 'name': 'PG výstup 9', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753573', 'name': 'Žaluzie-vše nahoru', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753583', 'name': 'Žaluzie-sever dolu', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753593', 'name': 'Žaluzie-západ dolu', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753603', 'name': 'Žaluzie-jih dolu', 'can-control': True, 'need-authorization': True}, {'cloud-component-id': 'PG-493753613', 'name': 'Žaluzie-východ dolu', 'can-control': True, 'need-authorization': True}]}, 'sections': {'service-states': {'last-event-time': '2023-11-25T08:41:22+0100', 'service-name': 'ALARM'}, 'states': [{'cloud-component-id': 'SEC-493752363', 'state': 'ARM'}], 'sections': [{'cloud-component-id': 'SEC-493752363', 'name': 'Rozkoš', 'can-control': True, 'need-authorization': True, 'partial-arm-enabled': False}]}, 'thermo': []} 2023-11-25 09:17:26.567 DEBUG (MainThread) [custom_components.jablotron_cloud] Finished fetching Jablotron data in 6.528 seconds (success: True) 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.alarm_control_panel] Jablotron discovered service: 2215009:FUTURA 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753463:PG výstup 1 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753473:PG výstup 2 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753488:PG výstup 3 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753498:PG výstup 4 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753508:PG výstup 5 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753523:PG výstup 6 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753533:PG výstup 7 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753548:PG výstup 8 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753558:PG výstup 9 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753573:Žaluzie-vše nahoru 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753583:Žaluzie-sever dolu 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753593:Žaluzie-západ dolu 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753603:Žaluzie-jih dolu 2023-11-25 09:17:26.568 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Jablotron discovered controllable programmable gate: PG-493753613:Žaluzie-východ dolu 2023-11-25 09:17:27.745 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving programmable gates for 2215009 2023-11-25 09:17:28.025 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving sections for 2215009 2023-11-25 09:17:28.622 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving thermo devices for 2215009 2023-11-25 09:17:28.821 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving programmable gates for 2215014 2023-11-25 09:17:29.041 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving sections for 2215014 2023-11-25 09:17:29.288 DEBUG (MainThread) [custom_components.jablotron_cloud] There was a problem receiving thermo devices for 2215014 2023-11-25 09:17:31.274 DEBUG (MainThread) [custom_components.jablotron_cloud] Finished fetching Jablotron data in 4.703 seconds (success: True) 2023-11-25 09:17:31.274 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753473', 'state': 'OFF'} 2023-11-25 09:17:31.274 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753488', 'state': 'OFF'} 2023-11-25 09:17:31.275 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753498', 'state': 'OFF'} 2023-11-25 09:17:31.275 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753508', 'state': 'OFF'} 2023-11-25 09:17:31.275 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753523', 'state': 'OFF'} 2023-11-25 09:17:31.275 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753533', 'state': 'OFF'} 2023-11-25 09:17:31.276 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753548', 'state': 'OFF'} 2023-11-25 09:17:31.276 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753558', 'state': 'OFF'} 2023-11-25 09:17:31.276 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753573', 'state': 'OFF'} 2023-11-25 09:17:31.276 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753583', 'state': 'OFF'} 2023-11-25 09:17:31.276 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753593', 'state': 'OFF'} 2023-11-25 09:17:31.277 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753603', 'state': 'OFF'} 2023-11-25 09:17:31.277 DEBUG (MainThread) [custom_components.jablotron_cloud.switch] Updating programmable gate with data: {'cloud-component-id': 'PG-493753613', 'state': 'OFF'}

Can't control PG JA-111N

Hi, when pushing PG switch I get message unable to control component.

Logger: homeassistant.components.websocket_api.http.connection
Source: custom_components/jablotron_cloud/switch.py:104
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 18:41:11 (8 occurrences)
Last logged: 19:29:07

[139824495184096] Unable to control component
[139824445895392] Unable to control component
[139824469031664] Unable to control component
[139824497106256] Unable to control component
[139824446255504] Unable to control component
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 199, in handle_call_service
await hass.services.async_call(
File "/usr/src/homeassistant/homeassistant/core.py", line 1849, in async_call
task.result()
File "/usr/src/homeassistant/homeassistant/core.py", line 1889, in _execute_service
await cast(Callable[[ServiceCall], Awaitable[None]], handler.job.target)(
File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 226, in handle_service
await service.entity_service_call(
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 798, in entity_service_call
future.result() # pop exception if have
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 980, in async_request_call
await coro
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 838, in _handle_entity_call
await result
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1034, in async_turn_on
await self.hass.async_add_executor_job(ft.partial(self.turn_on, **kwargs))
File "/usr/local/lib/python3.10/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
File "/config/custom_components/jablotron_cloud/switch.py", line 104, in turn_on
bridge.control_programmable_gate(self._service_id, self._gate_id, True)
File "/usr/local/lib/python3.10/site-packages/jablotronpy/jablotronpy.py", line 379, in control_programmable_gate
return self.control_component(service_id=service_id, component_id=component_id, state=state, control_pg=True)
File "/usr/local/lib/python3.10/site-packages/jablotronpy/jablotronpy.py", line 365, in control_component
raise UnexpectedResponse("Unable to control component")
jablotronpy.jablotronpy.UnexpectedResponse: Unable to control component

Failed to get gates data 151695

Hi,

V 0.6.1

The integration shows the following error : Failed setup, will retry: Failed to get gates data 151695.

2024-06-19 09:36:39.199 DEBUG (MainThread) [custom_components.jablotron_cloud] Preparing Jablotron data update coordinator
2024-06-19 09:36:41.341 DEBUG (MainThread) [custom_components.jablotron_cloud] Failed to get gates data for service 151695
2024-06-19 09:36:41.342 DEBUG (MainThread) [custom_components.jablotron_cloud] Finished fetching Jablotron Cloud data in 2.142 seconds (success: False)

For completeness (if related), I have two homes on the same account.

Best regards,,

Manu

How to get states of window contact sensors?

Window contact sensors have been mentioned under "Supported functionality", but in a quite unclear way. I got the integration working and now see the PG outputs, but nothing concerning window contact sensors. I would have hoped to find one sensor entity for each window in HA.

Jablotron communication stops during the night, USB in sleep mode (proxmox server)?

It looks like my Jablotron-HA communication stops during the night. As all other HA communication have no problems during the night and the Jablotron is connected by a USB port, I have the feeling the USB port goes into a sort of standby/sleep/hibernation mode.
I am running HA on a proxmox server. Who can help me debugging my system? How can I check /ebug the USB port communication settings?

Alarm entities often unavailable, need to reload integration to recover

Hi,

the Jablotron integration does not show the alarm state very often. Sometimes it recovers, but sometimes it keeps disconnected.
If the integration is reloaded, the alarm entities shows immediatelly current state again.

Logger: custom_components.jablotron_cloud
Source: helpers/update_coordinator.py:296
Integration: Jablotron Cloud ([documentation](https://github.com/Pigotka/ha-cc-jablotron-cloud), [issues](https://github.com/Pigotka/ha-cc-jablotron-cloud/issues))
First occurred: 15. listopadu 2023 v 14:49:27 (56 occurrences)
Last logged: 08:26:27

Timeout fetching Jablotron data
Logger: custom_components.jablotron_cloud.alarm_control_panel
Source: custom_components/jablotron_cloud/alarm_control_panel.py:205
Integration: Jablotron Cloud ([documentation](https://github.com/Pigotka/ha-cc-jablotron-cloud), [issues](https://github.com/Pigotka/ha-cc-jablotron-cloud/issues))
First occurred: 04:45:37 (118 occurrences)
Last logged: 08:14:31

States data not found
Logger: custom_components.jablotron_cloud
Source: custom_components/jablotron_cloud/__init__.py:103
Integration: Jablotron Cloud ([documentation](https://github.com/Pigotka/ha-cc-jablotron-cloud), [issues](https://github.com/Pigotka/ha-cc-jablotron-cloud/issues))
First occurred: 04:40:27 (2 occurrences)
Last logged: 04:40:58

Failed to get services!

Unexpected error for call_service at pos 2

HA version:

Core: 2024.5.0
Supervisor:2024.04.4
Operating System:12.2
Frontend:20240501.0

Error:

Error executing script. Unexpected error for call_service at pos 2: Detected that custom integration 'jablotron_cloud' calls async_write_ha_state from a thread at custom_components/jablotron_cloud/alarm_control_panel.py, line 160: self.async_write_ha_state(). Please report it to the author of the 'jablotron_cloud' custom integration.
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 501, in _async_step
await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 736, in _async_call_service_step
response_data = await self._async_run_long_action(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 699, in _async_run_long_action
return await long_task
^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2738, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2779, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 975, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1047, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/alarm_control_panel/init.py", line 175, in async_alarm_disarm
await self.hass.async_add_executor_job(self.alarm_disarm, code)
File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/jablotron_cloud/alarm_control_panel.py", line 160, in alarm_disarm
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1008, in async_write_ha_state
self.hass.verify_event_loop_thread("async_write_ha_state")
File "/usr/src/homeassistant/homeassistant/core.py", line 440, in verify_event_loop_thread
frame.report(
File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 162, in report
_report_integration(what, integration_frame, level, error_if_integration)
File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 203, in _report_integration
raise RuntimeError(
RuntimeError: Detected that custom integration 'jablotron_cloud' calls async_write_ha_state from a thread at custom_components/jablotron_cloud/alarm_control_panel.py, line 160: self.async_write_ha_state(). Please report it to the author of the 'jablotron_cloud' custom integration.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.