Skip to content
This repository has been archived by the owner on May 17, 2021. It is now read-only.

Z-Wave: Added support for CENTRAL_SCENE #4431

Merged
merged 3 commits into from
Jun 17, 2016

Conversation

savageautomate
Copy link
Contributor

@cdjackson ,

To support the double tap, triple tap, hold and release notifications from the Homeseer HS-(WS|WD)-100+ dimmers and switches, central scene support is required. Both a scene number and key attribute are provided in the central scene data and these are used to determine which button and action were taken.

There may be a better/more appropriate name for the key argument. I don't have access to the Z-Wave documentation to determine the best name for this data value. I'll be happy to change the naming prior to merge if you can provide a more appropriate name for this field.

This implementation of central scene supports the following item configuration for the HomeSeer switches:


Switch  HS_WS100_SWITCH         "HS_WS100 Switch"  {zwave="2:command=switch_binary,refresh_interval=500"}

//-------------------------------------------------------------------
// SCENE 1 = TOP (UP) BUTTON
//-------------------------------------------------------------------
Switch  HS_WS100_ANY_TAP_UP      "HS_WS100 <UP> Any Tap"      { zwave="2:command=CENTRAL_SCENE,scene=1" }
Switch  HS_WS100_SINGLE_TAP_UP   "HS_WS100 <UP> Single Tap"   { zwave="2:command=CENTRAL_SCENE,scene=1,key=0" }
Switch  HS_WS100_RELEASE_UP      "HS_WS100 <UP> Release"      { zwave="2:command=CENTRAL_SCENE,scene=1,key=1" }
Switch  HS_WS100_HOLD_UP         "HS_WS100 <UP> Hold"         { zwave="2:command=CENTRAL_SCENE,scene=1,key=2" }
Switch  HS_WS100_DOUBLE_TAP_UP   "HS_WS100 <UP> Double Tap"   { zwave="2:command=CENTRAL_SCENE,scene=1,key=3" }
Switch  HS_WS100_TRIPLE_TAP_UP   "HS_WS100 <UP> Triple Tap"   { zwave="2:command=CENTRAL_SCENE,scene=1,key=4" }

//-------------------------------------------------------------------
// SCENE 2 = BOTTOM (DOWN) BUTTON
//-------------------------------------------------------------------
Switch  HS_WS100_ANY_TAP_DOWN    "HS_WS100 <DOWN> Any Tap"    { zwave="2:command=CENTRAL_SCENE,scene=2" }
Switch  HS_WS100_SINGLE_TAP_DOWN "HS_WS100 <DOWN> Single Tap" { zwave="2:command=CENTRAL_SCENE,scene=2,key=0" }
Switch  HS_WS100_RELEASE_DOWN    "HS_WS100 <DOWN> Release"    { zwave="2:command=CENTRAL_SCENE,scene=2,key=1" }
Switch  HS_WS100_HOLD_DOWN       "HS_WS100 <DOWN> Hold"       { zwave="2:command=CENTRAL_SCENE,scene=2,key=2" }
Switch  HS_WS100_DOUBLE_TAP_DOWN "HS_WS100 <DOWN> Double Tap" { zwave="2:command=CENTRAL_SCENE,scene=2,key=3" }
Switch  HS_WS100_TRIPLE_TAP_DOWN "HS_WS100 <DOWN> Triple Tap" { zwave="2:command=CENTRAL_SCENE,scene=2,key=4" }

Added to support Homeseer HS-WS100 switch and HS-WD100 dimmer double-tap, triple-tap, etc.
@cdjackson cdjackson self-assigned this Jun 7, 2016
@cdjackson
Copy link
Contributor

Are you using the Eclipse IDE? If so (or even if not) please can you ensure the formatter is applied.

@savageautomate
Copy link
Contributor Author

No I am using IntelliJ. Is there a specific formatter config/template for OpenHAB or you just want me to use the default built-in formatter settings?

Thanks!

@cdjackson
Copy link
Contributor

Yes - there is a formatter included in the IDE specific for ESH/OH2. I just note that a few things don’t look right - I’m not sure if InteliJ can import the Eclipse definitions?

@savageautomate
Copy link
Contributor Author

OK, I followed the install directions here: http://www.eclipse.org/smarthome/documentation/community/contributing.html

and loaded the ESH distribution of Eclipse and used it's formatter on the two primary files in this change set. Let me know if this is correct or if you are expecting something different. Thanks, Robert

@cdjackson cdjackson merged commit 5cc30b9 into openhab:master Jun 17, 2016
cdjackson added a commit to cdjackson/openhab1-addons that referenced this pull request Jun 20, 2016
* master:
  Zwave database 180616 (openhab#4483)
  Zwave database 180616 (openhab#4479)
  Add Aeon ZW112 - Door/Window Sensor 6 (openhab#4472)
  Include Aeon ZW112 - Door/Window Sensor 6 (openhab#4471)
  Z-Wave: Added support for CENTRAL_SCENE (openhab#4431)
  ZWave database update (openhab#4476)
  ZWave addition of clock command class (openhab#4468)

Signed-off-by: Chris Jackson <chris@cd-jackson.com>

# Conflicts:
#	bundles/binding/org.openhab.binding.zwave/database/linear/wa105dbz.xml
@savageautomate savageautomate deleted the zwave-central-scene branch July 6, 2016 20:44
cdjackson added a commit to cdjackson/openhab1-addons that referenced this pull request Aug 12, 2016
* master: (178 commits)
  Fix the generateDeviceId method. (openhab#4498)
  [modbus] Add support for int32_swap, uint32_swap and float32_swap data types (openhab#4251)
  Extend error logging on retry failure (openhab#4477)
  Changed timestamp of item insert from MySql server time to local Java… (openhab#4503)
  [mochadx10] Add binding to OH2 distro (openhab#4502)
  [mqtt] Add openhab-action-mqtt feature for OH2 install (openhab#4499)
  ZWave database update (openhab#4497)
  Fixes openhab#1003 (openhab#4162)
  [WeatherBinding] Add log messages for invalid configurations (openhab#4458)
  Network Health - Made log message more clear (openhab#4425)
  Update ZMNHSD (openhab#4490)
  Update clock command class and converter (openhab#4489)
  Updated modbus config template with serial example. Documented advanced connection parameters (openhab#4487)
  ZWave update WA105DBZ (openhab#4485)
  Zwave database 180616 (openhab#4483)
  Zwave database 180616 (openhab#4479)
  Add Aeon ZW112 - Door/Window Sensor 6 (openhab#4472)
  Include Aeon ZW112 - Door/Window Sensor 6 (openhab#4471)
  Z-Wave: Added support for CENTRAL_SCENE (openhab#4431)
  ZWave database update (openhab#4476)
  ...

# Conflicts:
#	bundles/binding/org.openhab.binding.zwave/database/products.xml
#	bundles/binding/org.openhab.binding.zwave/src/main/java/org/openhab/binding/zwave/internal/converter/ZWaveConverterHandler.java
#	bundles/binding/org.openhab.binding.zwave/src/main/java/org/openhab/binding/zwave/internal/protocol/commandclass/ZWaveCommandClass.java
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants