Tradfri dimmer

Ok, scratch that. I Reset and re-paired without removing and then hit configure.
Also commented back in some debug messages to see better. Now its working :+1:

Very smooth action!! Well done on that, its very, very good :smiley:

dev:61172019-12-23 17:00:41.067 debugiterate: stopped 100
dev:61172019-12-23 17:00:40.884 debugLEVEL_STOP_ONOFF_COMMAND
dev:61172019-12-23 17:00:40.386 debugiterate: fadeUp 100
dev:61172019-12-23 17:00:40.205 debugSetting level to 100
dev:61172019-12-23 17:00:40.184 debugiterate: fadeUp 90
dev:61172019-12-23 17:00:40.008 debugSetting level to 90
dev:61172019-12-23 17:00:39.995 debugiterate: fadeUp 80
dev:61172019-12-23 17:00:39.819 debugLEVEL_MOVE_ONOFF_COMMAND
dev:61172019-12-23 17:00:39.011 debugiterate: stopped 80
dev:61172019-12-23 17:00:38.818 debugLEVEL_STOP_ONOFF_COMMAND
dev:61172019-12-23 17:00:38.800 debugSetting level to 80
dev:61172019-12-23 17:00:38.784 debugiterate: fadeUp 70
dev:61172019-12-23 17:00:38.598 debugSetting level to 70
dev:61172019-12-23 17:00:38.589 debugiterate: fadeUp 60
dev:61172019-12-23 17:00:38.338 debugSetting level to 60
dev:61172019-12-23 17:00:38.324 debugiterate: fadeUp 50
dev:61172019-12-23 17:00:38.135 debugLEVEL_MOVE_ONOFF_COMMAND
dev:61172019-12-23 17:00:37.019 infoSwitch On
dev:61172019-12-23 17:00:37.018 debugLEVEL_MOVE_LEVEL_ONOFF_COMMAND 

The battery is way off, but that always was.
Its up and down like a yo-yo. I replaced the battery and now showing at 50%

Current States

  • battery : 50.0
  • level : 100
  • switch : on
1 Like

Update: I added a setting so that you can toggle a puck between dimmer and switch behavior. Turn off the "allow dimming" setting, and it will behave as a simple switch.

2 Likes

That driver looks neat! I'll have to try it out. Since you mentioned:

...this actually sounds like the perfect case for implementing it as a button device, where the user could then map the start of a turn to startLevelChange() and stopping to stopLevelChange() for devices that support this. (Or maybe held for the start of a "dimming" turn and released for the stop, and a regular pushed for a swift, "on/off" move, assuming these are all distinct? Then it would be usable with Advanced Button Controller...my imagination is going wild.)

I had mixed luck with this thing--it was so sensitive I couldn't tell what events I meant to make it do and which ones it was just doing because I happened to be typing on a keyboard vaguely near it. Thanks for your work! I'll give it another try now that someone has figured out more than I was ever able to.

1 Like

So, the tradfri dimmer is actually sending over a report about the speed that the dial is turning? What are the raw reports out of the device?

The Somfondsk remote does not do that. It simply reports when you begin turning the dial in one direction and then when you stop turning it. It doesn't matter how fast or slow you move the dimmer...as long as you keep moving it at the minimum speed it doesn't report the "stop" to the controller. But when it does, that is all that it reports to the controller.

Someone on ST used the difference between the start and stop to calculate the amount that the dimmer should change but I just used them as button pressed to use the native startChanging and stopChaning commands.

Could something similar be done with the Tradfri dimmer? Rather than use any report of "ramping" directly out of the device, simply use the beginning and ending of motion to trigger actions in HE. Might make the dimming a lot more intuitive. Just a thought.

No, it doesn't send anything about the speed. Just start and stop. In my code, I have two parameters that affect the "feel" of the dimming. One is the step size (in % of full brightness), and one is how many milliseconds in between steps. I have these set to something that felt good when used with my GE z-wave plus dimmers, but I will probably turn them into preferences, so that you can adjust them as you like.

Okay...so, I'm confused why turning the dial fast vs turning it slow would affect how the dimmer performs. It seems that shouldn't affect it at all.

For example, I can imagine an ideal situation where the driver does a 1% step every 20 milliseconds. It would fade from 1% to 100% very smoothly over 2 seconds. In the real world (or at least in my mesh network), that would saturate the network, and it ends up not working really well. I tested a bunch of variations and settled on slightly larger steps, slightly less often.

Fast vs. slow does not affect the dimming rate. HOWEVER, within the firmware of the puck device itself, it registers it as a different event type if you do a large/fast twist. Instead of sending the "start fade change" command, it sends a "turn on" or "turn off" command. This happens inside the puck.

Think of it this way. There is a very short list of possible events that the puck is sending to Hubitat:

  • Fade up motion has started
  • Fade down motion has started
  • Fade motions have stopped
  • Turn on motion has started
  • Turn off motion has started
  • Turn on/off motion has completed (I'm ignoring this event. Don't need it.)

OH! Ok. You can't also tap on the puck? See, the Symphondsk remote only does level with the dial part and then supports single, double and tripple taps for the power commands. I didn't realize that the dimmer puck did that with the power. That's just weird. Like it was said earlier....very Swedish. LOL

That's for clarifying....I was toying with the idea of picking one up as they're cheap on eBay at the moment. Think I'll avoid that now.

No taps though. Only twisting motions.

That's the part that I didn't realize. Again...just weird. Probably why they developed the new ones.

The whole tradfri line feels like an experiment so far. I saw a Hubitat engineer in another thread saying that every IKEA device was implementing zigbee differently right now. Design by multiple teams, all doing their own proof-of-concept. So that’s not great right now.

On the other hand, they are cheap, and IKEA will traditionally keep successful products around forever. They’re a very different company than a Lowe’s or a Samsung. If they get it figured out and their protocols locked down, they could be a great long-term provider of cheap devices.

1 Like

So I just picked up a bunch of these (much more than I needed) because these are now down to 99 cents (!!!) at IKEA. Had some issues getting this to work but finally figured it out. Not sure if this was mentioned earlier but you need to make sure to manually set a level and duration value before the dimmer changes properly register, else you get a bunch of errors. I definitely had some issues trying to tie the dimmer controls to properly control my dimmer lights but I got something somewhat working ok.

What seems to be working best for me so far is to create a global variable that is set to the ikea dimmer's level value on change. Then on change, it will set my light's dimmer value to the value of the global variable.

Any other tips on how others are using this outside of on/off controls?

What driver are you using? I would recommend using an app like mirror instead of RM. It will be a lot faster.

Specifically I would recommend using "Switch Bindings" to bind the Tradfri puck to your light. This does a two-way binding, which is important. If you light changes due to some other app/process/Alexa/Google/etc, you want the Tradfri Puck driver to update its internal state to match the physical light.

1 Like

Thanks! I'll try them out.

Hi guys.

I recently picked up one of these to try to use as a remote for one of my bulbs.

I can connect the dimmer in hubitat, but i can't use it as a switch. The battery level is showing, but nothing when i tap the device. Any help in getting this to work would be appreciated.

Just to clarify, this thread is about the Round discontinued dimmer a.k.a. Puck Dimmer

It should work with this Driver.

Ranchitat - The last two devices you listed work with SmartThings and can be HubConnect'd to the Hubitat - if you have a SmartThings hub. I forgot that this part was needed and I had difficulties migrating my SmartThings hub to the new app. I couldn't get the new app to add the Ikea devices for some reason but I was able to reinstall the SmartThings Classic app to add the devices with no issues. I used WebCore on ST to use the 5-Button remote to switch between different controlled lights (with the left/right buttons) and then the Bright/Dim/Power buttons to work on the currently selected light. I haven't yet tried to migrate that process to Hubitat since I've just recently moved and my new house doesn't have the same light requirements that I had in the old one.