HomeGenie Forum
General Category => Troubleshooting and Support => Topic started by: MItchCECG on February 09, 2016, 11:35:43 PM
-
OK I install HG on windows. I am using a Zstick and it sees all of my devices.
I configure just 2 devices a light switch Dragon ws-100 binary switch device # 10 and a Ecolink pir-zwave2 sensor device #36.
First Issue: the switch can be turned on and off from the HG interface. However, the status does not update if I manually activate the switch on its own mechanical button.
Second Issue: I can see the motion detector detect motion in HG if the tamper is tripped it does not reset.
Third Issue: I am using smart lights. when the pir detects motion it updates on the screen but the light does not turn on.
Any help with these issues would be appreciated
THANX
MITCH
-
Issue one is very simple. X10 devices don't report their status, so doing a manual change outside of the HG interface isn't going to show up.
I can't help with tue other two issues, I'm sure someone will come along soon enough who can.
Regards,
Garry
-
Thanks Garry for the reply
All of the devices I am writing about are Z-wave and not X10 and I can Poll for status but it should not be necessary
Thanks again
-
1) I don't use ZWave, but it is my understanding that they should all send their status as you suggest and you can certainly poll them (though should not be necessary). I don't know why they would not update as I've never used them.
2) I've seen reports that the tamper switch does not reset unless you do something to the module itself. I don't know anything beyond that, but it's been reported in a couple threads, so you might be able to search and find some useful information.
3) Are you sure you have the smart lights set up correctly? To make it work, you must have a motion sensor, a luminescence sensor, and a light of some kind. You modify the smart lights settings for the light such that it triggers based on the motion sensor's name. I don't remember how the lumin value is set in the code, so I can't help there. Once you have it configured, make sure you select "UPDATE" or else settings will be lost. Finally, if everything is configured correctly, you will have your lights turn on only when the lumens are below a threshold set in the APP. Make sure it's dark enough. Also, make sure the lumen sensor is not close to the light you are triggering or you will have a flashing light situation.
-
My understanding is that the luminescence sensor is optional and not required for it to work on motion alone. can someone verify this and also still looking for answers to my other 2 questions
THANX
MITCH
-
var da = GetDomainAddress(mod.Parameter(MOT_SENSOR_NAME).Value);
if (da.Domain == module.Instance.Domain && da.Address == module.Instance.Address)
{
mod.Parameter(LAST_EVENT).Value = DateTime.UtcNow.Ticks.ToString();
//if (mod.IsOff)
{
da = GetDomainAddress(mod.Parameter(LUM_SENSOR_NAME).Value);
var lumsensor = Modules.InDomain(da.Domain).WithAddress(da.Address).Get();
if (lumsensor.Instance != null)
{
var luminosity = lumsensor.Parameter("Sensor.Luminance").DecimalValue;
if (luminosity < mod.Parameter(MIN_LUMINANCE).DecimalValue)
{
Program.Notify("Smart Lights", module.Instance.Name + "<br>switched ON " + mod.Instance.Address + " " + mod.Instance.Name);
if (synchTimetable && mod.Parameter("TimeTable.Status").DecimalValue > 0)
mod.Level = mod.Parameter("TimeTable.Status").DecimalValue;
else
mod.On();
}
}
else
{
Program.Notify("Smart Lights", module.Instance.Name + "<br>switched ON " + mod.Instance.Address + " " + mod.Instance.Name);
if (synchTimetable && mod.Parameter("TimeTable.Status").DecimalValue > 0)
mod.Level = mod.Parameter("TimeTable.Status").DecimalValue;
else
mod.On();
}
}
}
- find module
- check state
- check lumsensor is defined
- if lumsensor not defined (else), set to timetable value or turn on
So, it appears that if you do not have a lumsensor defined and the timetable is not used then it should turn the light on when motion is sensed. Are you seeing the notification?
Program.Notify("Smart Lights", module.Instance.Name + "<br>switched ON " + mod.Instance.Address + " " + mod.Instance.Name);
It should say:
title="Smart Lights"
text="<module name> switched ON <module address> <module name>"
-
Hi,
First Issue: the switch can be turned on and off from the HG interface. However, the status does not update if I manually activate the switch on its own mechanical button.
In HomeGenie configuration of the device, did you put the "GroupID" 1 to value 1.
Perhaps need the other GroupID 2,3,... to value 1 too. It depends of your device.
Second Issue: I can see the motion detector detect motion in HG if the tamper is tripped it does not reset.
Same behavior on my side with a Fibaro motion sensor (and a door sensor). Perhaps, HomeGenie need to reset because the device doesn't to send zwave packet to say "all fine now" ..
On my side, i don't care a lot of the "tampered" ;)
-
still looking for answers to all 3 questions
So far no suggestions worked.
But I wish to thank everyone for their input
-
I tried to help you with question 3 but you either didn't see the question or didn't post the result from HG.
-
bkenobi
sorry I did not respond. just being new to this It did not seem to work
I have set up a test enviorment with just the 2 devices a switch and a motion sensor
The sensor shows motion on the widget. It also displays tamper.
The light does not turn on
you state "It should say:
title="Smart Lights"
text="<module name> switched ON <module address> <module name>"
I don't know where I should see those words. they do not show on the display. nor can i find them in the log (ATTACHED)
I have also attached the log file
-
I can't help much on ZWave as I have never looked at it or the commands. It looks to me as though HG is at least attempting communication with several nodeID's (0, 4, 10, 12). NodeID 10 appears to be your motion sensor as it has the "AlarmTampered" parameter and a value of 255 (on) as well as "Battery". HG is successful in sending and receiving data packets (outbound, inbound). I do not know what is on either 4 or 12, but I don't see NodeID 36. My only suggestion is to make sure your devices are set up correctly first and then we can try again. It looks like you think 10 is your switch and it's really your motion sensor. You certainly can't control the lights by sending anything to a motion sensor.
-
Again Thank you for the help here is an update
Node 10 is the echolink pir-zwave2 sensor and node 4 is the light switch dragon ws-100 that I am trying to control
here is the log entries
------
2016-02-16 08:55:54.5024 Debug 01-09-00-04-00-0A-03-30-03-FF-37
2016-02-16 08:55:54.5024 Debug ZWaveMessage (RawData=01-09-00-04-00-0A-03-30-03-FF-37)
2016-02-16 08:55:54.5024 Debug ZWaveMessage (Direction=Inbound Header=SOF NodeId=10 Type=Request Function=ApplicationCommandHandler CommandClass=SensorBinary)
2016-02-16 08:55:54.5024 Debug 06
2016-02-16 08:55:54.5024 Debug NodeUpdated (NodeId=10 Parameter=SensorGeneric Value=255)
"2016-02-16 08:55:54.5024 Info HomeAutomation.ZWave 10 ZWave Node Sensor.Generic 255"
"2016-02-16 08:55:58.1674 Info WebServiceGateway 192.168.16.4 HTTP GET 200 /api/HomeAutomation.HomeGenie/Config/Interfaces.List/?_=1455572111507 [OPEN]"
"2016-02-16 08:55:58.1674 Info WebServiceGateway 192.168.16.4 HTTP GET 200 /api/HomeAutomation.HomeGenie/Config/Interfaces.List/?_=1455572111507 [CLOSED AFTER 0 seconds]"
"2016-02-16 08:56:08.1079 Info WebServiceGateway 192.168.16.4 HTTP GET 200 /api/HomeAutomation.HomeGenie/Config/Interfaces.List/?_=1455572111508 [OPEN]"
"2016-02-16 08:56:08.1079 Info WebServiceGateway 192.168.16.4 HTTP GET 200 /api/HomeAutomation.HomeGenie/Config/Interfaces.List/?_=1455572111508 [CLOSED AFTER 0 seconds]"
"2016-02-16 08:56:12.5035 Info WebServiceGateway 192.168.16.4 HTTP GET 200 /api/HomeAutomation.HomeGenie/Config/System.Configure/UpdateManager.UpdatesList/?_=1455572111509 [OPEN]"
"2016-02-16 08:56:12.5035 Info WebServiceGateway 192.168.16.4 HTTP GET 200 /api/HomeAutomation.HomeGenie/Config/System.Configure/SystemLogging.IsEnabled/?_=145"
It seems to me that the PIR state changes but there is no action taken by the smart lights I do not even see an entry for it in the log
-
I have solved Issue #3 on my list the Smart Lights issue
I have changed this line of code from
if (parameter.Name == "Sensor.MotionDetect" || parameter.Name == "Status.Level ")
to
if (parameter.Name == "Sensor.MotionDetect" || parameter.Name == "Status.Level "||parameter.Name == "Sensor.Generic")
which solved the issue
-
That works. I use Status.Level in the Advanced Smart Lights code as X10 motion sensors do not use the MotionDetected parameter. Even if the motion sensor did return that value, the Status.Level would also be set so I don't see any down side to using it instead.
The funny thing is that I thought Gene coded that up to work with Aeon brand sensors which are ZWave. I would have assumed the Smart Lights code would work with all ZWave since that's what it was designed for.
-
As I stated I am using the Ecolink pir-zwave2
when it sees motion it does not set or change status.level the only change is sensor.generic
I have now determined that Smart Lights is too basic for my needs and I am trying to get advanced smart lights working. However, I am not a coder and I am spending a lot mmore time on this project than I expected. I realy need to find an off the shelf solution to fit my needs. Any suggestions are welcome
-
I believe what you want is a motion sensor to control a light that is connected to a switch. I'm not clear if you also want to have the light only turn on between dusk and dawn. The Smart Lights (SL) code is designed to work with a setup including a motion sensor, a light, and optionally some kind of luminescence sensor.
I wrote the Advanced Smart Lights (ASL) code to extend the capabilities of the SL code Gene provided. ASL can use a motion sensor, a light, a switch capable of transmitting, and a chime. I do not have any kind of light sensor, so I utilized APPs available within HG to determine day/night. I also had an issue with false triggers due to wind, bugs, birds, etc causing my chime to trip repetitively, so I included a nuisance timeout. The switch can be used to override the motion sensor or turn the light on for a timed period.
In either case, the modules you are using should work without significant modification. I use X10, so I know ASL will work with that. I don't use other systems, so it's possible that some slight modification in the way modules are referenced or what values to check may need to be applied. The ASL code is fairly well documented IMO, so you should be able to follow along so long as you can follow the logic/read pseudocode. If you find bugs in ASL or have improvements to suggest, let me know and I can try to help out or update the code that's in the contribution thread.