Kerui Motion sensor

Hi,
bought a KERUI motion sensor from Ali express.

RFXMNGR shows in log that device is sending

Problem is: Vera plugin is NOT creating the device …

Any ideas?
thanks
Uri



Packettype = Security1
subtype = X10 security
Sequence nbr = 1
id1-3 = 39B6B0 decimal:3782320
status = Motion
battery level = OK
Signal level = 7 -64dBm


Packettype = Security1
subtype = X10 security
Sequence nbr = 2
id1-3 = 39B6B0 decimal:3782320
status = Motion
battery level = OK
Signal level = 7 -64dBm


Packettype = Security1
subtype = X10 security
Sequence nbr = 3
id1-3 = 39B6B0 decimal:3782320
status = Motion
battery level = OK
Signal level = 7 -64dBm


Packettype = Security1
subtype = X10 security
Sequence nbr = 4
id1-3 = 39B6B0 decimal:3782320
status = Motion
battery level = OK
Signal level = 7 -64dBm

It would be helpful if you could do one or both of these things with the RFXtrx connected to your Vera, debug enabled for the RFXtrx and activating the motion sensor:

  1. Look in the Vera log to find out if any messages are posted in response to the sensor
  2. While activating the sensor watch the RFXtrx settings page, noticing what shows up at the bottom after “Last received message:”. The first three pieces of the message are important. The first two are probably 08 20. What is the third piece?

Hi,
did as you suggested - results are:

last word received as logged by RFXTRX plugin:
08 20 00 6E 39 B6 B0 04 79

Vera log file shows:

02/25/18 12:30:34.860 Device_Variable::m_szValue_set device: 1051 service: urn:rfxcom-com:serviceId:rfxtrx1 variable: LastReceivedMsg was: 08 20 00 6E 39 B6 B0 04 79 now: 08 20 00 6F 39 B6 B0 04 79 #hooks: 0 upnp: 0 skip: 0 v:(nil)/NONE duplicate:0 <0x75b1a520>
02 02/25/18 12:30:34.967 luup_log:1051: RFXtrx: warning: decodeSecurityDS command not yet implemented: 4hex=34 <0x75b1a520>

02 02/25/18 12:30:38.001 Generic_IP_Camera_Manager::ReturnImage /etc/cmh-lu/cam_offline.jpg=4112 <0x7591a520>
02 02/25/18 12:30:38.001 Generic_IP_Camera_Manager::REQ_Image 30 retry 0 return:7 httpresp:0 last 1/1 known error 0 return /etc/cmh-lu/cam_offline.jpg test 0 <0x7591a520>
02 02/25/18 12:30:38.002 Device_Basic::AddPoll 30 poll list full, deleting old one <0x7591a520>
06 02/25/18 12:30:38.003 Device_Variable::m_szValue_set device: 30 service: urn:micasaverde-com:serviceId:HaDevice1 variable: PollRatings was: 0.00 now: 0.00 #hooks: 0 upnp: 0 skip: 0 v:(nil)/NONE duplicate:1 <0x7591a520


I think it says "luup_log:1051: RFXtrx: warning: decodeSecurityDS command not yet implemented: 4hex=34 "

Does this help?
thanks
Uri

OK - the RFXtrx plugin code doesn’t expect the status that’s being reported by the Kerui device. The plugin sees your device as a door/window sensor. Is this a PIR sensor or a Door/Window sensor? What is the model number? I have a Kerui door/window sensor with a model number of D026. The plugin doesn’t really handle this device either.

ok…

I have two devices:

  1. the one I sent the codes :
    https://www.aliexpress.com/item/KERUI-433Mhz-Wireless-Intelligent-PIR-Motion-Sensor-Detector-For-GSM-PSTN-Home-Alarm-System-without-antenna/32249576391.html?spm=2114.10010108.1000013.2.456c1ccdX0rWyU&traffic_analysisId=recommend_2088_1_90158_iswistore&scm=1007.13339.90158.0&pvid=6a92add3-9122-47a2-ad29-abcc3bab48ca&tpp=1

  2. another one :
    https://www.aliexpress.com/item/Wireless-Infrared-Detector-Curtain-Sensor-PIR-Detector-Burglar-Alarm-System-Detector/32704459468.html?spm=a2g0s.13010208.99999999.265.hkPtHW

this one shows log:

luup_log:1051: RFXtrx: debug: Received message: 08 20 00 09 D6 48 70 04 69 <0x74346520>
06 02/25/18 21:13:44.866 Device_Variable::m_szValue_set device: 1051 service: urn:rfxcom-com:serviceId:rfxtrx1 variable: LastReceivedMsg was: 08 20 00 08 D6 48 70 04 79 now: 08 20 00 09 D6 48 70 04 69 #hooks: 0 upnp: 0 skip: 0 v:(nil)/NONE duplicate:0 <0x74346520>
50 02/25/18 21:13:44.917 luup_log:1051: RFXtrx: debug: decodeSecurityDS: 0 altid=D/D64870 status=4 <0x74346520>
02 02/25/18 21:13:44.918 luup_log:1051: RFXtrx: warning: decodeSecurityDS command not yet implemented: 4hex=34 <0x74346520>
50 02/25/18 21:13:44.919 luup_log:1051: RFXtrx: debug: cmds: D/D64870 BatteryLevel 100 <0x74346520>


is there anything you can do to make it work ?

much appreciated…
Thanks
Uri

Right now there isn’t anything you can do to make this be seen and automatically created by the plugin. You might be able to add the device manually but the plugin still will not recognize the status being sent. I will have to modify the plugin code to make it work. The problem is that the device is being seen as a door sensor but the status being sent is that of a motion sensor. I’ll see if I can just respond to that status in the door sensor code. I’ll respond here when I have updated code.

Hi,

if there’s anything you can do to make it work - it will be great.
this sensors are operating both on batteries as well as 5V micro USB, and are very cheap and reliable.

also - how can I add it as “door sensor” ?
trying to add through the plugin interface is not working for me… do you have any hints ?

A lot of thanks,
Uri

Again, there is nothing you can do at this point. Even if you could add it as a door sensor, the message it sends will still be sending a status that the plugin does not handle. I hope to have something you can try sometime tomorrow.

thanks a lot for all you help… I appreciate your efforts…
Uri

OK, upload the attached file. The changes should only impact the receipt of motion messages that appear to come from door sensors. Let me know how it works for you.

Hi
tried and got some errors… I suspect I’m using an old version of the plugin (from vesternet…)

can you point me to the latest plugin version files ?
Thansk a lot

Uri

You can download them from this post: http://forum.micasaverde.com/index.php/topic,52229.0.html

ok… now on the right plugin version -

I get error in log:

Device_Variable::m_szValue_set device: 1067 service: urn:rfxcom-com:serviceId:rfxtrx1 variable: LastReceivedMsg was: 08 20 00 0A 39 B6 B0 04 79 now: 08 20 00 0B 39 B6 B0 04 79 #hooks: 0 upnp: 0 skip: 0 v:(nil)/NONE duplicate:0 <0x7466c520>
01 02/27/18 23:12:04.211 LuaInterface::CallFunction-2 lu_incoming failed [string “module(“L_RFXtrx”, package.seeall)…”]:3224: attempt to concatenate global ‘altid’ (a nil value)


looks like some minor bug in the new LUA file ?

Thanks a lot for all you help,
Uri

Yes, I moved a debug statement. It then had some undefined values. Try the attached file.

works like a charm :slight_smile: :slight_smile: :slight_smile:

device created automatically and are reported “motion” .

with “AutoUntrip” set to 30 seconds, I have a fully functional motion sensor with my Vera… at the cost of 10$ .

It also work quite fast.

The motion sensors are working on batteries as well as with a micro USB 5V cable, and are also equipped with a physical on/off button.

Most recommended.

Thank you very very much… great help !!!

Uri