I'm going to relentlessly play the 'newbie' card and ask a question that's remarkably like @richpasma 's question from 2020: Everspring HSP02 Motion Detector Driver?
I too recently installed an Everspring HSP02 Motion detector on my HE hub C8. As in 2020, the device is still listed on HE support as being compatible. And the generic driver that was installed as part of the Inclusion process is what I have been using and have not been able to find anything else. Check.
Unlike the earlier post, I am unable to get it to respond in any way. It appears in my devices display with these two states:
No amount of motion in front of the sensor seems to trigger anything.
Scanning the support documentation reveals 11 posts with HSP02, but only 4 that seem to fit. Two of them are from @richpasma and contain external custom code links that have since disappeared. These appear to be based on code for another platform.
The last message on richpasma's post indicates the source code is available at an internal link, but that link doesn't do anything (I mean it doesn't even try to open a URL)
What advice can this community give me to get this device operable in Hubitat? Am I missing something obvious?
You can take Kevin LaFramboise (krlaframboise) code and replace "physicalgraph" with "hubitat" the code will compile. I don't have a device so I can't tell you if it works. After adding the driver, making the edits, and saving it, you will be able to find it in Type on the Device Info page.
Thanks this helps I was able to change the device driver to Kevin's code. Will work with this and reach out to the community if I have more questions!
follow on question. I havn't been able to make it work within an app yet. I have been successful with another brand of motion sensor triggering lights, but this one is eluding me.
As I try different device settings I notice that the Type* text goes from black to red.
What is Hubitat trying to tell me?
Wow, I don't know what a red Type means. Are you seeing errors in the logs?
I can't duplicate:
I swapped the driver to this Everspring one and get reasonable logs:
as a result of clicking config, followed by waving my hands in front of the Aeotec sensor. The commands are generic enough that it doesn't work exactly, but it tries valiantly.
OK the logs gave me more information, and it appears that the red driver type label has not come back while I fiddle with the preferences to see what works.
Seeing the message in the log to take off the back cover, I gave it a try, and while it didn't fix the issue, I did manage to generate an exception:
groovy.lang.MissingMethodException: No signature of method: user_driver_krlaframboise_Everspring_Motion_Detector_607.sendHubCommand() is applicable for argument types: (java.util.ArrayList) values: [[840400025801, delay 500, 7004010163, delay 500, 700501, delay 500, ...]]
Possible solutions: sendHubCommand(hubitat.device.HubAction), sendHubCommand(hubitat.device.HubMultiAction) on line 336 (method parse)
Other than that its all Motion Inactive messages in the log
Hi, I have not done anything with Hubitat driver code other than what was mentioned with the posts you referenced, so I am still in the same newbie club as you. LaFramboise;s driver code was modifed as recommended by esteele in the post above. The modified driver code can be found at the following link: Everspring Driver Code
This driver code has been working fine with the 5 motion detectors I have been using for lighting control. When the detector is working properly the log should have a line with: "Detected Motion" followed by a line with: "Motion is Active XX seconds (XX being your setting).
This driver code does not work well for changing the detector's settings. To do that you can use the recommendation provided by: Everspring HSP02 Motion Detector Driver? - #4 by Ryan780
You can find the programing instructions and parameter setting in the manual that came with the detector. At a minimum you might want to take a look at the default settings. That will give you an idea about what the detector should be doing. I never did get the Lux setting for the detector to work and ended up using the Hubitat's timed settings. With the options to use Sunrise/Sunset offsets it has been working out quite well.
If anything, I posted here is not clear, let me know. All the Best, Rich
Thank you @richpasma this ties it all together. The code you shared hasn't generated any errors, and I am seeing motion detected in the logs. I can now trigger lights using that motion sensor. Very much appreciated
Glad to hear that worked out for you. I think you will be happy with the Everspring motion detectors. The detectors in my house have been working very well, with good battery life, for a little over three years.
Since you are new to Hubitat, I will give you a tip you might find useful. There are times when you might want to temporarily ignore a rule that is associated with your motion detector. For instance, you might have a situation where the rule might be turning the lights off sooner than you want, or for some reason you might not want the detector rule to turn the lights on. You can do this with a Virtual Switch, that can be created using the add device option. Towards the bottom of the basic rule settings, you will see a section for restrictions. If you open that up you can add any number of restrictions to ignore the rule for all kinds of conditions, usually time or device related. Here is where you will have the option to test the position of the virtual switch to control the restriction. Virtual switches show up on the same lists as regular switches whenever a selection for a switch device is given. Thus, you can turn the virtual switch on or off with a skill such as the Amazon Echo Skill, or with a Dashboard button.
The problem with the hyperlink in the earlier thread you mentioned above, was caused by the accidental deletion of the linked file that was done during a cleanup of my Google Drive. That link has been fixed. Please accept my apology for the trouble that caused you. All the Best, Rich