Skip to content

Commit d6db81c

Browse files
committed
CoCoHue 4.1.6
Fix for error when calling setEffect() with standard numeric parameter
1 parent b53ddfe commit d6db81c

File tree

4 files changed

+12
-10
lines changed

4 files changed

+12
-10
lines changed

CoCoHue-Latest-Bundle.zip

35 Bytes
Binary file not shown.

drivers/cocohue-group-driver.groovy

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,10 @@
1414
*
1515
* =======================================================================================
1616
*
17-
* Last modified: 2023-02-01
17+
* Last modified: 2023-05-03
1818
*
1919
* Changelog:
20+
* v4.1.6 - setEffect() parameter fix
2021
* v4.1.5 - Improved v2 brightness parsing
2122
* v4.0 - Add SSE support for push
2223
* v3.5.2 - setColor() fix (refactor code into library--was not previously)
@@ -1061,7 +1062,7 @@ void flashOff() { // library marker RMoRobert.CoCoHue_Flash_Lib, line 26
10611062
// ~~~~~ end include (5) RMoRobert.CoCoHue_Flash_Lib ~~~~~
10621063

10631064
// ~~~~~ start include (4) RMoRobert.CoCoHue_Effect_Lib ~~~~~
1064-
// Version 1.0.0 // library marker RMoRobert.CoCoHue_Effect_Lib, line 1
1065+
// Version 1.0.1 // library marker RMoRobert.CoCoHue_Effect_Lib, line 1
10651066

10661067
library ( // library marker RMoRobert.CoCoHue_Effect_Lib, line 3
10671068
base: "driver", // library marker RMoRobert.CoCoHue_Effect_Lib, line 4
@@ -1078,7 +1079,7 @@ void setEffect(String effect) { // library marker RMoRobert.CoCoHue_Effect_Lib,
10781079
if (id != null) setEffect(id.key) // library marker RMoRobert.CoCoHue_Effect_Lib, line 15
10791080
} // library marker RMoRobert.CoCoHue_Effect_Lib, line 16
10801081

1081-
void setEffect(Integer id) { // library marker RMoRobert.CoCoHue_Effect_Lib, line 18
1082+
void setEffect(Number id) { // library marker RMoRobert.CoCoHue_Effect_Lib, line 18
10821083
if (enableDebug == true) log.debug "setEffect($id)" // library marker RMoRobert.CoCoHue_Effect_Lib, line 19
10831084
sendBridgeCommand(["effect": (id == 1 ? "colorloop" : "none"), "on": true]) // library marker RMoRobert.CoCoHue_Effect_Lib, line 20
10841085
} // library marker RMoRobert.CoCoHue_Effect_Lib, line 21

drivers/cocohue-rgbw-bulb-driver.groovy

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,10 @@
1414
*
1515
* =======================================================================================
1616
*
17-
* Last modified: 2023-02-01
17+
* Last modified: 2023-05-03
1818
*
1919
* Changelog:
20+
* v4.1.6 - setEffect() parameter fix
2021
* v4.1.5 - Improved v2 brightness parsing
2122
* v4.0.2 - Fix to avoid unepected "off" transition time
2223
* v4.0 - Add SSE support for push
@@ -1039,7 +1040,7 @@ void flashOff() { // library marker RMoRobert.CoCoHue_Flash_Lib, line 26
10391040
// ~~~~~ end include (5) RMoRobert.CoCoHue_Flash_Lib ~~~~~
10401041

10411042
// ~~~~~ start include (4) RMoRobert.CoCoHue_Effect_Lib ~~~~~
1042-
// Version 1.0.0 // library marker RMoRobert.CoCoHue_Effect_Lib, line 1
1043+
// Version 1.0.1 // library marker RMoRobert.CoCoHue_Effect_Lib, line 1
10431044

10441045
library ( // library marker RMoRobert.CoCoHue_Effect_Lib, line 3
10451046
base: "driver", // library marker RMoRobert.CoCoHue_Effect_Lib, line 4
@@ -1056,7 +1057,7 @@ void setEffect(String effect) { // library marker RMoRobert.CoCoHue_Effect_Lib,
10561057
if (id != null) setEffect(id.key) // library marker RMoRobert.CoCoHue_Effect_Lib, line 15
10571058
} // library marker RMoRobert.CoCoHue_Effect_Lib, line 16
10581059

1059-
void setEffect(Integer id) { // library marker RMoRobert.CoCoHue_Effect_Lib, line 18
1060+
void setEffect(Number id) { // library marker RMoRobert.CoCoHue_Effect_Lib, line 18
10601061
if (enableDebug == true) log.debug "setEffect($id)" // library marker RMoRobert.CoCoHue_Effect_Lib, line 19
10611062
sendBridgeCommand(["effect": (id == 1 ? "colorloop" : "none"), "on": true]) // library marker RMoRobert.CoCoHue_Effect_Lib, line 20
10621063
} // library marker RMoRobert.CoCoHue_Effect_Lib, line 21

packageManifest.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
"packageName": "CoCoHue (Hue Bridge Integration)",
33
"minimumHEVersion": "2.2.9",
44
"author": "Robert Morris",
5-
"dateReleased": "2023-02-01",
5+
"dateReleased": "2023-05-04",
66
"communityLink": "https://community.hubitat.com/t/release-cocohue-hue-bridge-integration-including-scenes/27978",
7-
"releaseNotes": "NOTE: If upgrading from 3.x, open the CoCoHue app and hit \"Done\", download a hub backup beforehand, and vist the Community thread for more information.\n\n*Version 4.1.5, 4.1.4: Fix for v2 API level parsing when zero; Minor HTTP error handling tweaks, fix for missing attributes on v1 API motion sensors\n\nVersion 4.1: Add button device support (Hue Dimmer, Hue Tap, etc.). Version 4.1.3: Improve multiple-device eventstream (push) parsing. Version 4.1.1 and 4.1.2 further tweaks button event parsing.\n\n*Version 4.0.2, 4.0.1: Fix for on state of All Hue Lights group (if used); Fix for adding Bridge; fix for error when adding sensors.\n\nVersion 4.0:\n -Support for instant updates (eventstream/server-sent events [SSE]) from Hue Bridge--optional; opt-in from app preferences.\n - Minor bug fixes.\n - Version 4.0.1 contains a fix for bridge discovery or manual addition.\n\n * Version 3.5.2: setColor() fix for group driver\n\n* Version 3.5.1: Improved Bridge username request step; removed 'Light' capability from scenes so may work better with Alexa/etc. Internal code refactoring to use Hubitat library features (but precompiled, so you do NOT need to install any libraries at the present time--but let me know if anything broke in the process!)\n\n* Vesion 3.5: Implementation of new LevelPreset capability, including standard presetLevel() command; preliminary implementation of presetColor() and presetColorTemperature() (prestating preferences remain available but deprecated; please switch to commands, as these may be removed if/when standardized in future); addition of \"reachable\" attribute to bulbs and other devices; minor code cleanup.\n\n* Version 3.1.6 through 3.1.3: Fix runtime error with temperature offset on motion driver; ensure numeric sensor values not reported as strings; setLevel(0) now obeys specified transition time\n* Version 3.1.2: Added optional temperature offset to motion sensor driver\n *Version 3.1.1: Fix for setColorTemperature() not working without level in some cases\n *Version 3.1: Minor fixes (improved error handling for Bridge requests; more debug logging); additional optiona setColorTemperature() parameters; deprecation of prestaging options in preparation for future changes.\n *New in version 3.0: Experimental support for Hue motion sensors (with motion, lux, and temperature) and Hue Labs activators. HTTP error handling improvements. Fixes for CT, dimmable, and on/off drivers to match RGBW and group drivers in generating events only when Bridge heard back from. Options for alternate HTTP port (improves compatibility with third-party Bridge-type solutions like DeCONZ.)\n\nNOTE: Users upgrading from v1.x should follow instructions forum or on GitHub (parent app deprecatred but still available) and perform initial upgrade manually, not with HPM.",
7+
"releaseNotes": "NOTE: If upgrading from 3.x, open the CoCoHue app and hit \"Done\", download a hub backup beforehand, and vist the Community thread for more information.\n\n*Version 4.1.6: setEffect() numeric parameter fixes\n\n*Version 4.1.5, 4.1.4: Fix for v2 API level parsing when zero; Minor HTTP error handling tweaks, fix for missing attributes on v1 API motion sensors\n\nVersion 4.1: Add button device support (Hue Dimmer, Hue Tap, etc.). Version 4.1.3: Improve multiple-device eventstream (push) parsing. Version 4.1.1 and 4.1.2 further tweaks button event parsing.\n\n*Version 4.0.2, 4.0.1: Fix for on state of All Hue Lights group (if used); Fix for adding Bridge; fix for error when adding sensors.\n\nVersion 4.0:\n -Support for instant updates (eventstream/server-sent events [SSE]) from Hue Bridge--optional; opt-in from app preferences.\n - Minor bug fixes.\n - Version 4.0.1 contains a fix for bridge discovery or manual addition.\n\n * Version 3.5.2: setColor() fix for group driver\n\n* Version 3.5.1: Improved Bridge username request step; removed 'Light' capability from scenes so may work better with Alexa/etc. Internal code refactoring to use Hubitat library features (but precompiled, so you do NOT need to install any libraries at the present time--but let me know if anything broke in the process!)\n\n* Vesion 3.5: Implementation of new LevelPreset capability, including standard presetLevel() command; preliminary implementation of presetColor() and presetColorTemperature() (prestating preferences remain available but deprecated; please switch to commands, as these may be removed if/when standardized in future); addition of \"reachable\" attribute to bulbs and other devices; minor code cleanup.\n\n* Version 3.1.6 through 3.1.3: Fix runtime error with temperature offset on motion driver; ensure numeric sensor values not reported as strings; setLevel(0) now obeys specified transition time\n* Version 3.1.2: Added optional temperature offset to motion sensor driver\n *Version 3.1.1: Fix for setColorTemperature() not working without level in some cases\n *Version 3.1: Minor fixes (improved error handling for Bridge requests; more debug logging); additional optiona setColorTemperature() parameters; deprecation of prestaging options in preparation for future changes.\n *New in version 3.0: Experimental support for Hue motion sensors (with motion, lux, and temperature) and Hue Labs activators. HTTP error handling improvements. Fixes for CT, dimmable, and on/off drivers to match RGBW and group drivers in generating events only when Bridge heard back from. Options for alternate HTTP port (improves compatibility with third-party Bridge-type solutions like DeCONZ.)\n\nNOTE: Users upgrading from v1.x should follow instructions forum or on GitHub (parent app deprecatred but still available) and perform initial upgrade manually, not with HPM.",
88
"apps": [
99
{
1010
"id": "568bab8e-5c69-4800-a038-481026904c05",
@@ -63,7 +63,7 @@
6363
"name": "CoCoHue Group",
6464
"namespace": "RMoRobert",
6565
"location": "https://raw.githubusercontent.com/HubitatCommunity/CoCoHue/master/drivers/cocohue-group-driver.groovy",
66-
"version": "4.1.5",
66+
"version": "4.1.6",
6767
"required": true
6868
},
6969
{
@@ -87,7 +87,7 @@
8787
"name": "CoCoHue RGBW Bulb",
8888
"namespace": "RMoRobert",
8989
"location": "https://raw.githubusercontent.com/HubitatCommunity/CoCoHue/master/drivers/cocohue-rgbw-bulb-driver.groovy",
90-
"version": "4.1.5",
90+
"version": "4.1.6",
9191
"required": true
9292
},
9393
{

0 commit comments

Comments
 (0)