What I didn't quite figure out was how it operates independently as a regular light switch.
What I find most interesting is that this is 8 years old. There have been some incredible advances in the IoT world in that time. I was about to do a similar thing which morphed into an ESP-12F then added a touch screen. I call it the Universal Light Switch
Imagine this: All the switches are identical. Any switch can easily be configured to control up to five devices ... and then changed, on-the-fly, to control a different set of devices.
My design is part of a system that would require a controller (eg. Home Assistant), an MQTT broker, and receiving modules in the devices being switched. It's WiFI which assumes an access point.
The DIY ULS is under $20 and the off-the-shelf receiving modules are under $10. (About the cost of a non-networked dimmer switch) If one doesn't have the controller and MQTT broker, they can run on an old (5 years?) computer (which is cheaper than an old RasberryPi).
This project is a good one!
OSD
I am not able to install the Library . I am getting Error
Invalid library found in C:\Documents and Settings\User\My Documents\Arduino\libraries\ESP8266MQTTMesh: C:\Documents and Settings\User\My Documents\Arduino\libraries\ESP8266MQTTMesh.
I changed the name of the zipped file to ESP8266MQTTMesh as the name of .cpp file ESP8266MQTTMesh.cpp. Still it is saying Invalid Library found in ....
What could be the problem.
@C.r.a.z.y.
yeah.... those are VERY bouncy.
are you interrupt triggering or just using a state change?
post your code, let's make sure you have it de-bounced enough.
I built a trip wire for the post box that I'm connecting. It's however based on a mercury tilt sensor so I'm really not sure whether I think it's a great idea putting it to use (at least not with a sturdy case...). However, I can share my code:
#define DIGITAL_INPUT_SENSOR 2 // The digital input you attached your motion sensor. (Only 2 and 3 generates interrupt!)
#define INTERRUPT DIGITAL_INPUT_SENSOR-2 // Usually the interrupt = pin -2 (on uno/nano anyway)
MyMessage msgTripped(CHILD_ID_TRIPPED, V_TRIPPED);
void setup()
{
gw.sendSketchInfo("Postal", "1.0");
gw.present(CHILD_ID_TRIPPED, S_MOTION);
pinMode(DIGITAL_INPUT_SENSOR, INPUT); // sets the motion sensor digital pin as input
}
void loop()
{
boolean tripped = digitalRead(DIGITAL_INPUT_SENSOR) == LOW;
if(tripped) {
gw.send(msgTripped.set("1")); // Send tripped value to gw
}
gw.sleep(INTERRUPT,FALLING, SLEEP_TIME);
}
@yury said in Wall Socket Insertable Node:
Looks cool! Do you have experience with capacities switches? I did not play much with them. afraid to use close to AC interference though...
You need to use a capacitive IC with active shielding, basically you have an extra electrode around your touch electrode and the touch IC will compare capacitive change of the touch electrode with capacitive change from the shield electrode. If the change is due to electrical interference then both electrodes will be changed in a similar way and the IC will not trigger.