- Posts: 4
- Thank you received: 0
Please Log in or Create an account to join the conversation.
Try this should helppiman wrote: Thanks Harry,
That seemed to have done the trick thanks a lot, I have modified the code slightly so that it switches the buzzer off when the door is closed, here is an example just in case someone else was having the same problem I was. I think I've got it now thanks to Harry.
Next step email notification.public void Setup() { { EventHelper.ModuleChangedHandler((o, m, p) => { Console.WriteLine(m.Address + " in program id "+ Program.ProgramId.ToString()+ " property "+ p.Property + " value " + p.Value); if (m.Domain == Domains.MYSENSORS && m.Address == "N11S3" && p.Property == "Sensor.DoorWindow" && p.Value == "1") DriverHelper.ProcessCommad(Domains.RPIGPIO, "Pin_P1_07", "ControlOn",""); if (m.Domain == Domains.MYSENSORS && m.Address == "N11S3" && p.Property == "Sensor.DoorWindow" && p.Value == "0") DriverHelper.ProcessCommad(Domains.RPIGPIO, "Pin_P1_07", "ControlOff",""); return true; }); } }
Please Log in or Create an account to join the conversation.