[Deprecated] Xiaomi / Aqara ZigBee device drivers (possibly may no longer be maintained)

Makes sense. It does seem sort of gimmicky.

But I am running out of things to play with. :smile:

What I should do instead is something constructive - like learn how to sniff zigbee and write zigbee drivers. I can write a driver for anything I need in zwave, but have avoided custom drivers in zigbee for a long time. That would be handy, though.

1 Like

Lol, that's why I have 2, I wanted to play, the 36 button option is good but not always recognizes a face flip so you will get lost if you don't look it, then for some reason I must hit them hard on my wooden night tables to make the recognize the tap, so I ended using one face, shake and rotation to control my bedroom lamps.

1 Like

I have 3 cubes, they are mostly just fun to play with. One cube I have set to turn on/off and change colors on some Hue bulbs, depending on what is done with it. The grandkids thought that was cool :grin:

The original author worked wrote code to use the current face up data that is sent when the cube is flipped, slid, or knocked. So only rotation or shake gestures may have incorrect face up data. In my opinion it is way easier and quicker to just knock the cube to set the correct face. I feel whole point of the controller is to not have to go to a computer's/mobile device and start fiddling with virtual buttons.

Either way, if concerned about the face up status being out of sync, I think the "basic" Cube Mode is just fine. That's already 7 gesture functions right there, and it's very consistent once you learn how to do the gestures correctly.

They are fun to use. My 8-year-old daughter loves using it.

I figured more than the 7 gestures would overload my brain so I only use the basic mode, but wondered about the face getting out of sync. Sounds like an easy solution to that--thanks for the info!

1 Like

Does anyone know how to add a dashboard action item to silent Xiaomi smoke detector when it's triggered?

Continuing the discussion from [Release] Xiaomi / Aqara device drivers:

Answering my own question, here's how to disable the smoke detector when it's triggered.

  1. in RM, create a custom command and link it to the smoke detector's command - resetToClear()

  2. In Devices, create a virtual momentary switch

  3. In RM, create a trigger for the virtual momentary switch. When it is 'On', it will run the custom command created in step 1.

  4. In dashboard, add the virtual switch created in step 2.

When smoke detector is triggered, you can disable the siren through dashboard. :slight_smile:

1 Like

Hi @guyeeba,

I have just moved my QBKG11LM and QBKG12LM switches (with neutral) to your upgraded driver. It's really cool that you can separate the button from the switch!

Whilst the separation works fine, when the buttons are physically pushed on the parent wall switch the DH does not record which button was pressed. The following is outputted in the logs:

Unknown button state 0100 for endpoint 5
Unknown button state 0100 for endpoint 6

Any ideas?

All the best,
Mark

Hi, Mark,

unfortunately I cannot try it it right now, but I think it is caused by the 2.0.6 upgrade...

Please revert the byte order in button handler ("0001" to "0100" and "0002" to "0200", line 94 and 107), and most probably it will work again. :slight_smile:

I'll try to update the source on github tomorrow...

Thanks, and sorry for the inconvenience,
guyeeba

I’ve placed a humidity offset but it doesn’t work… placing 10, -10, 20 or anything else, the humidity value is just the same…

Can you test one thing for me?
Can you placed it in the freezer for a few mins 2/3 and see if temp changes?

[UPDATE] v0.8.2 of Xiaomi/Aqara Temperature Humidity Sensor device driver for Hubitat

Thanks to @ajeshm 's feedback, I discovered that the object used to store a user's custom humidity offset value was named incorrectly. This has been fixed, and I've taken this chance to update and fix a few more things in this driver.

The updated driver code can be grabbed from here.

Major Changes

  • Humidity offset value setting is now working correctly

  • Pressure events now use the officially supported Pressure Measurement capability
    Prior to this release, atmospheric/environment pressure reports were made using a custom attribute. A while back, Hubitat added official support for the PressureMeasurement capabliity. From a user perspective, there's no change in the attribute name (pressure) but an Aqara sensor should now show up in apps which can use pressure as part of an automation trigger / rule.

  • Temperature values are now reported in hundreths (0.01 precision)

  • The voltage range for Battery % has been changed
    The minimum / maximum voltage values used to calculate battery percentage have been changed from 2.5V min / 3.0V max to 2.9V min / 3.05V max. This means your reported battery percentages will change from what you have been seeing! It should not be a cause for alarm, however. Keep in mind that using the min / max voltage values to calculate a battery percentage only gives a very very rough estimate of battery health. Also, remember that the min / max voltage values can be changed in the preference settings in the device details page for each sensor.

Detailed Change List

  • corrected misspelled humidity offset setting object name so that humidity offset value now works correctly
  • switched from use custom attribute to officially supported PressureMeasurement capability to generate pressure value events
  • renamed object used for pressure offset value to pressureUnits
  • changed to use of location.temperatureScale to determine user's temperature scale setting, following Hubitat's environment sensor driver example
  • changed precision level of temperature event values from 0.1 (tenths) to 0.01 (hundredths)
  • fixed regression in default battery min/max voltage used to calculate battery level percentage - default values are now 2.9V minimum and 3.05V maximum
  • refactored portions of code
5 Likes

I believe I need to change a battery soon on this temp/humidity sensor... But it's still working fine... lol

Battery level is -10% (2.885 Volts)

:rofl:

But that’s helpful, actually. When the sensor working, please let me know what the last reported voltage was and the I can update the minimum voltage in the drivers to a lower value.

Ok I will keep an eye on voltages and as soon they are dead I will let you know :wink:

@veeceeoh @Somel
Just updated my driver and I'm getting the same. I did have min voltage of 2.8.
My last battery report was as follows.
image

@veeceeoh is the voltage reported by the device? Just asking as my oldest device (main door sensor) that I never swapped the battery and is on operation for over 20 months now has a reported voltage of 3.025...

If it is reported by the device.... damn this thing last as hell...

If you have custom set min / max values those will remain unchanged through any driver updates. It’s good to know that you also are seeing 2.885V on a working sensor.

Yes, I see similar values with my Door Window Sensors after more than 1.5 years.

I just thought I would change to the values you mentioned in your release notes.
I've changed it back now.
Just thought I would let you know.

Are these Aqara? My Aqara temp/humidity sensors started acting-up at 2.75 volts.