[RELEASE] Aqara High Precision Motion Sensor (RTCGQ13LM)

This is a new thread for the Aqara High Precision Motion Sensor, that are supported by the Aqara P1 Motion Sensor driver initially published here. As this driver supports several different modles of Aqara motion sensors, mixing the updates and the comments for the different devices is somewhat confusing for most of the forum users so it was decided to split the inital thread into several individual new threads.

The recommended method for installing this custom driver is to use the community Hubitat Package Manager (HPM), search for "Aqara P1 Motion Sensor" or by Tag 'Zigbee'.

For manual installation, the last stable version code is here: https://raw.githubusercontent.com/kkossev/Hubitat/main/Drivers/Aqara%20P1%20Motion%20Sensor/Aqara_P1_Motion_Sensor.groovy

Device Links
Aqara High Precision Motion Sensor RTCGQ13LM
Battery: 2 x CR2450
Supports: motion detection, battery voltage/percentage, detection interval configuration, motion sensitivity configuration
Price range: high

Review: link
Aqara site (in Chinese): link
Manual (in Chinese): link
AliExpress: link
Amazon .co.jp: link

Product Details:

  • Model: RTCGQ13LM
  • IPX5 waterproof
  • Operating Temperature: -10℃– +35°C
  • Cover Dimensions: 113 × 113 × 41 mm
  • Product Dimensions: 74 x 74 x 43.3mm
  • Wireless Protocol: Zigbee 3.0
  • Operating Humidity: 0% – 95%RH, non-condensing
  • Executive Standard: Q/QLML002-2020
  • Detection Distance: 5m
  • Detection Angle: about 60°
  • Detection Range: a circle with a diameter of 6m (at a distance of 5m)
  • Battery Type: 2 x CR2450
  • Battery Life: 6 year



Versions history

reserved #3

can you discuss the capability of Occupancy? I've not experienced a device with that ability before - motion sensors are so... meh. I'm hoping you tell me its more like a contact switch in regards to its state... What can you share with the class?

The 'occupancy' capability in the description was an incorrect translation. This is just a PIR motion sensor, but very sensitive when compared to the other PIR sensors that I have. I have it mounted in a bathroom, where I can't wire mains / DC-powered sensors on the ceiling. It replaced a previously used Z-wave motion sensor. The results are excellent - no more need to wave my hand while sitting still on the throne for a long time.. : )

Rather pricey though, I prefer FP1 where it is possible to have a power supply.


In order to achieve how have you configured the device?

I assume Motion Reset Timer needs to be blank? Otherwise the sensor will go inactive.

Well, 'sitting still' is not the most precise term... This is a PIR sensor, so slight movements are needed anyway to retrigger the motion state. This device is just more sensitive if compared to other PIR sensors, but it is not a mmWave radar.

These are my settings - I usually set up the 'Motion Reset Tumer' (this is the software reset to inactive) to be double or triple the value of the 'Motion Retrigger Interval' (this is the hardware timer inside the device) :

And this is a typical active/inactive events sequence :



I was about to turn off debug logging but saw this. Is this of any interest to you?

Thank you for the logs. There’s nothing unusual there, typically the Aqara devices send some internal data in a binary format which meaning is unknown and these are dumped in the debug logs.

The LQI and the RSSI would be of an interest, but the decoding shows unusual values.

The other interesting data is the NWK of the device that is used as a repeater. In your case the sensor is connected directly to HE hub. When the NWK is different than 0000, this is the short address of the repeater device. You can look up the device name in HE web page Setting -> Zigbee details. The device name unfortunately can not be displayed from a custom driver, seems like this is disabled because of security reasons.

Greetings, it’s me again.
Purchased this Aqara High Precision sensor. What driver should i be using? It pairs with the P1 driver. But that one does not seem to be working.

I went through the process of pairing multiple times, resetting to factory, default in pairing, multiple times, removing the batteries and pairing multiple times. It appears as though the device is paired correctly. And but it will not go active more than a couple of times.

I paired it to the E1 hub for a test and it worked fine.

Are you pairing it with a C-7 or C-8 hub?
I don't see something wrong in the Data or States screenshots ...
Are you pairing it very close to the hub? (from a distance less than 1 meter?).

Once paired, if you press shortly the button on the sensor, do you see any debug logs showing in the live logs?

Yes. I am pairing with a C7. Right in front of it within 1 meter. As you say, it seems paired correctly it just will not show activated more than twice after pairing. Here are some logs:

It seems like normal communication between the device and HE...
The screenshots cover a short period of time that follows the pairing and sending configuration parameters. Do you have anything in the live logs later?

Yes, thank you. See below. I have this set to retrigger in 5s. But as you can see it is in a small room with constant movement yet only triggers every 3-8 minutes.
At 5s, i am expecting it to react quickly with motion.

Here is the Aquara sitting next to a Hue motion sensor. I would expect the Aquara to be more responsive than the Hue.

Hello kkossev. Sorry to ask but I'm a new HE user and hope you can help me. I am trying to add RTCGQ13LM. I have followed the steps as described in HPM but I don't know what to do next. In the list of devices (Device Information , Type) the only Aqara that appears is Aqara Matter Contact Sensor P2. Where to find and add the correct driver for this device? I would appreciate help or a hint because this is not intuitive stuff in HE. Greetings. Alex

Hi @alex7 ,
The driver for RTCGQ13LM is this one, but it is called "Aqara P1 Motion Sensor", as this was the first Aqara motion sensor model that the driver was written for. Later, other models were added to the same driver.

If you have successfully installed the driver using the HPM, you will need to pair the RTCGQ13LM again to your hub, because this Aqara device requires specific initialization during the pairing process.

First, delete the already paired device ("REMOVE DEVICE" red button at the bottom of the device web page in HE). Then, start the pairing procedure again. This driver should be automatically selected.

Pair the sensor very close to the hub. Often, the first pairing is not successful - you will need to pair it again (without deleting it this time).

Hi kkosev,
thanks for your help. Unfortunately HPM didn't work despite many attempts and reinstalling and adding and removing the sensor. Only when I pasted the direct code for Aqara and installed it then it worked. Everything works but unfortunately the response time is very slow. I also have a wifi and cloud based system and it works light years faster for the time being . I'm trying to figure out in whose is the problem with hubitat lags in operation. Thanks again for your help with FP1