Dimming pocket outlet that remembers last set level?

Thanks, I’ll look into those. The ST one I bought is all but useless to me since it does not remember it’s last level setting.

1 Like

I’m actually glad you ask the question. I learned something too. I did not know that the ST ones did not do that.

Do you have a link to the model you have that does remember the level setting?

I got mine from eBay and I can’t go to that site here at work. Here is a link from Amazon but you might want to shop the model around as there might be a better price elsewhere.

1 Like

Thanks, I will.

Anyone know if there is a difference between the JASCO 45702 posted above and the GE 12718?

And on a side note, how you do post links that show the image and short description like that?

Just paste the URL and the image will follow. You can also drag and drop pictures from explorer/finder.

So don’t use the hyperlink button, just paste the url directly in the comments?

You could fix this with a custom DTH. I wrote this to simulate on/off fade dimming for GE ZigBee switches. I would guess this should work for you. Available from my jhamstead/jhamstead GitHub as well (updated there).

GitHub:
https://raw.githubusercontent.com/jhamstead/jhamstead/master/devicetypes/smartthings/enhanced-ge-zigbee-dimmer-power.src/enhanced-ge-zigbee-dimmer-power.groovy

As a note, when using the ZigBee attribute to turn on at a specific level, this changes the off behavior. When turning a switch off it will report the dimmer level as 0% but will turn on to the last level.

Also you may need to add this fingerprint:

fingerprint profileId: "0104", inClusters: "0000,0003,0004,0005,0006,0008,0B04,0B05", outClusters: "0019", manufacturer: "CentraLite", model: "4257050-ZHAC"

If you try this DTH out and this works for you, I can work on modifying the DTH to use he default on/off functions as fade to on/off is enabled in your device.

That way it more closely follows the default DTH.

Thanks for the DTH and the offer to modify one if needed. I did contact ST support about this dimmer not staying at the set level and they said mine is not working the way it should be. Let me hear back from them to see what they say/want to do first.

Quick question. When turning your outlet off does it go to 0% dim level? If it does, the turn on to level ZigBee attribute must be somehow set on your outlet. That would make your outlet behave like you are describing.

As a matter of fact, it does go to 0% then completely turns off.

Create a custom DTH based on the default and I’ll send some code for you to add to the refresh method. Run it once to disable that attribute and you should be good afterward. Give me a few to get it together. Got a 9 month old to put to bed.

I’ve just attached the entire DTH. Hopefully after you use this DTH and hit refresh, you will no longer have the issue. You should be able to go back to the default DTH afterward.

/**
 *  Copyright 2015 SmartThings
 *
 *  Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
 *  in compliance with the License. You may obtain a copy of the License at:
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 *  Unless required by applicable law or agreed to in writing, software distributed under the License is distributed
 *  on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License
 *  for the specific language governing permissions and limitations under the License.
 *
 *	SmartPower Dimming Outlet (CentraLite)
 *
 *	Author: SmartThings
 *	Date: 2013-12-04
 */
metadata {
	definition (name: "SmartPower Dimming Outlet", namespace: "smartthings", author: "SmartThings") {
		capability "Switch"
		capability "Switch Level"
		capability "Power Meter"
		capability "Configuration"
		capability "Refresh"
		capability "Actuator"
		capability "Sensor"
		capability "Outlet"

		fingerprint profileId: "0104", inClusters: "0000,0003,0004,0005,0006,0008,0B04,0B05", outClusters: "0019", manufacturer: "CentraLite", model: "4257050-ZHAC"

	}

	// simulator metadata
	simulator {
		// status messages
		status "on": "on/off: 1"
		status "off": "on/off: 0"

		// reply messages
		reply "zcl on-off on": "on/off: 1"
		reply "zcl on-off off": "on/off: 0"
	}

	tiles(scale: 2) {
		multiAttributeTile(name:"switch", type: "lighting", width: 6, height: 4, canChangeIcon: true){
			tileAttribute ("device.switch", key: "PRIMARY_CONTROL") {
				attributeState "on", label:'${name}', action:"switch.off", icon:"st.switches.switch.on", backgroundColor:"#79b821", nextState:"turningOff"
				attributeState "off", label:'${name}', action:"switch.on", icon:"st.switches.switch.off", backgroundColor:"#ffffff", nextState:"turningOn"
				attributeState "turningOn", label:'${name}', action:"switch.off", icon:"st.switches.switch.on", backgroundColor:"#79b821", nextState:"turningOff"
				attributeState "turningOff", label:'${name}', action:"switch.on", icon:"st.switches.switch.off", backgroundColor:"#ffffff", nextState:"turningOn"
			}
			tileAttribute ("device.level", key: "SLIDER_CONTROL") {
				attributeState "level", action:"switch level.setLevel"
			}
			tileAttribute ("device.power", key: "SECONDARY_CONTROL") {
				attributeState "power", label:'${currentValue} W'
			}
		}

		standardTile("refresh", "device.power", inactiveLabel: false, decoration: "flat", width: 2, height: 2) {
			state "default", label:'', action:"refresh.refresh", icon:"st.secondary.refresh"
		}

		main "switch"
		details(["switch", "refresh"])
	}
}

private getCLUSTER_LEVEL() { 0x0008 }
private getLEVEL_ATTR_ON_LEVEL() { 0x0011 }

// Parse incoming device messages to generate events
def parse(String description) {
	log.debug "description is $description"

	def event = zigbee.getEvent(description)
	if (!event) {
		log.warn "DID NOT PARSE MESSAGE for description : $description"
		log.debug zigbee.parseDescriptionAsMap(description)
	} else if (event.name == "power") {
		/*
			Dividing by 10 as the Divisor is 10000 and unit is kW for the device. Simplifying to 10 power level is an integer.
		*/
		event.value = event.value / 10
	}

	return event ? createEvent(event) : event
}

def setLevel(value) {
	zigbee.setLevel(value)
}

def off() {
	zigbee.off()
}

def on() {
	zigbee.on()
}

def refresh() {
	zigbee.onOffRefresh() + zigbee.levelRefresh() + zigbee.electricMeasurementPowerRefresh()
    return zigbee.writeAttribute(CLUSTER_LEVEL, LEVEL_ATTR_ON_LEVEL, 0x20, zigbee.convertToHexString(255,2))
}

def configure() {
	refresh() + zigbee.onOffConfig() + zigbee.levelConfig() + zigbee.electricMeasurementPowerConfig()
}

Okay, I installed your new DHT, edited the device to use it and hit Update. It still turns on at 100% no matter what the last set level was. Also, now when I turn it off it dims down 2% and pauses for just a second, then dims to 0% and off. Now when I turn it on, it dims up to 2% and then all the way up to 100% (the bulb is actually at 100% while the app does that little pause at 2%).

Switching back to the default DHT does the same thing.

1 Like

The pause is likely just that the current level is being reported back to the SmartThings hub. After an on command it sends the current level while it is fading on (which based on its internal clock is 2%) then there is a delay before it sends the next current level. By that time it is 100%.

Based on what I’ve seen with other ZigBee dimmers, your outlet is behaving like the on level attribute is set. According to ZigBee documentation setting the value to FF (255) is supposed to “disable” that attribute. You could always try zero instead of 255 in case they didn’t follow the standard correctly but overall I’m really at a loss.

If using that DTH and hitting refresh or a complete reset of the device didn’t clear up the problem, I’d definitely ask for an RMA.

Thanks for all the help trying to fix this. ST is sending me a new one, so I guess I’ll just use this one as a simple on and off outlet someplace.

There is also an attribute to change how long the fade on/off is. The reason I mention this is I don’t think this would work well for anything but a light. It may damage other electronics not receiving full power. You could change that fade time to 0 seconds but even so I’m not sure I’d recommend it elsewhere. @Nezmo

Well, in the shipment email ST sent me this evening, they included instructions for sending the bad outlet back to them. So I guess I will not get to keep this one to use as just and on/off outlet :frowning: Had I know that I probably would have just asked for a full return for a refund. I’ve since learned that there better priced options out there. Oh well.

Thanks again for all the help on this.