Skip to content

Commit

Permalink
Merge branch 'slyglif-main'
Browse files Browse the repository at this point in the history
  • Loading branch information
imhotep committed Jan 26, 2025
2 parents 113b8ec + c995da8 commit e1161d6
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 5 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
- Unifi Access Intercom (UA-Intercom) :x: (partial/experimental support)
- Unifi Access Hub Enterprise (UAH-Ent) :x: (partial/experimental support)
- Unifi Gate Hub (UGT) :x: (partial/experimental support)
- Unifi Access Ultra :x: (partial/experimental support)
- Unifi Access Ultra (UA-Ultra) :x: (partial/experimental support)
- Unifi Access Door Mini (UA-Hub-Door-Mini) :x: (unsupported - use polling)

# Getting Unifi Access API Token
- Log in to Unifi Access and Click on Security -> Advanced -> API Token
Expand Down
15 changes: 13 additions & 2 deletions custom_components/unifi_access/hub.py
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,11 @@ def _handle_UGT_config_update(self, update, device_type):
changed_doors.append(existing_door)
return changed_doors

def _handle_IGNORED_config_update(self, update, device_type):
"""Handle unknown hub types."""
_LOGGER.debug("UniFi Access Hub type %s ignored", device_type)
_LOGGER.debug("%s", update)

def _handle_UNKNOWN_config_update(self, update, device_type):
"""Handle unknown hub types."""
_LOGGER.critical("UniFi Access Hub type %s unknown", device_type)
Expand All @@ -444,14 +449,20 @@ def _handle_config_update(self, update, device_type):
return self._handle_UAH_config_update(update, device_type)
case "UAH-DOOR":
return self._handle_UAH_config_update(update, device_type)
case "UA-Intercom":
return self._handle_UAH_config_update(update, device_type)
case "UAH-Ent":
return self._handle_UAH_Ent_config_update(update, device_type)
case "UA-ULTRA":
return self._handle_UAH_Ent_config_update(update, device_type)
case "UGT":
return self._handle_UGT_config_update(update, device_type)
case "UA-G2":
return self._handle_IGNORED_config_update(update, device_type)
case "UA-G2-PRO":
return self._handle_IGNORED_config_update(update, device_type)
case "UA-G3":
return self._handle_IGNORED_config_update(update, device_type)
case "UA-Intercom":
return self._handle_IGNORED_config_update(update, device_type)
case _:
return self._handle_UNKNOWN_config_update(update, device_type)

Expand Down
4 changes: 2 additions & 2 deletions custom_components/unifi_access/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@
"requirements": [
"websocket-client==1.8.0"
],
"version": "1.2.5"
}
"version": "1.2.6"
}

0 comments on commit e1161d6

Please sign in to comment.