Skip to content
This repository has been archived by the owner on Dec 14, 2022. It is now read-only.

Commit

Permalink
feat: support for ac2958 (#43)
Browse files Browse the repository at this point in the history
  • Loading branch information
bosman authored Apr 27, 2021
1 parent 20da936 commit 3f221d3
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
1 change: 1 addition & 0 deletions custom_components/philips_airpurifier_coap/const.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
MODEL_AC2729 = "ac2729"
MODEL_AC2889 = "ac2889"
MODEL_AC2939 = "ac2939"
MODEL_AC2958 = "ac2958"
MODEL_AC3059 = "ac3059"
MODEL_AC3829 = "ac3829"
MODEL_AC3858 = "ac3858"
Expand Down
11 changes: 11 additions & 0 deletions custom_components/philips_airpurifier_coap/fan.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@
MODEL_AC2729,
MODEL_AC2889,
MODEL_AC2939,
MODEL_AC2958,
MODEL_AC3059,
MODEL_AC3829,
MODEL_AC3858,
Expand Down Expand Up @@ -152,6 +153,7 @@
MODEL_AC2729,
MODEL_AC2889,
MODEL_AC2939,
MODEL_AC2958,
MODEL_AC3059,
MODEL_AC3829,
MODEL_AC3858,
Expand Down Expand Up @@ -180,6 +182,7 @@ async def async_setup_platform(
MODEL_AC2729: PhilipsAC2729,
MODEL_AC2889: PhilipsAC2889,
MODEL_AC2939: PhilipsAC2939,
MODEL_AC2958: PhilipsAC2958,
MODEL_AC3059: PhilipsAC3059,
MODEL_AC3829: PhilipsAC3829,
MODEL_AC3858: PhilipsAC3858,
Expand Down Expand Up @@ -627,6 +630,14 @@ class PhilipsAC2939(PhilipsTVOCMixin, PhilipsGenericCoAPFan):
PRESET_MODE_TURBO: {PHILIPS_POWER: "1", PHILIPS_MODE: "T"},
}

class PhilipsAC2958(PhilipsGenericCoAPFan):
AVAILABLE_PRESET_MODES = {
PRESET_MODE_AUTO: {PHILIPS_POWER: "1", PHILIPS_MODE: "AG"},
PRESET_MODE_GENTLE: {PHILIPS_POWER: "1", PHILIPS_MODE: "GT"},
PRESET_MODE_SLEEP: {PHILIPS_POWER: "1", PHILIPS_MODE: "S"},
PRESET_MODE_TURBO: {PHILIPS_POWER: "1", PHILIPS_MODE: "T"},
}


class PhilipsAC3059(PhilipsTVOCMixin, PhilipsGenericCoAPFan):
AVAILABLE_PRESET_MODES = {
Expand Down

0 comments on commit 3f221d3

Please sign in to comment.