Suggestions wanted for v2 of my spark door sensor

Hi there,

I’m after suggestions for the second major version of my spark core shower room door sensor. The original version is documented here: https://unop.uk/dev/spark-core-shower-room-door-sensor/

It’s currently a bit of a hack (though not as much as the prototype) and makes use of a lot of paper-clips, post-it notes and gaffer tape. I have plans for version 2 and any feedback would be appreciated.

I want to use a Raspberry Pi running the local spark cloud instead of the official one. Then I can connect my Blinky Tape to the Pi to display the current state rather than just relying on a web page. This also allows the logging of data for historical analysis.

What do you think?

Thanks
James

@JSingleton, first you could use a magnet and reed switch sensor for the door. I recently installed NODE-RED on a Pi:

I haven’t have a chance to play with it yet but it could do some cool stuff for you including doing the Blinky Tape and and data logging. Using the local cloud would also be good but it does not support Spark.subscribe yet so that may be a problem. Keep us informed cause this sounds fun! :smile:

1 Like

Thanks for the input. A reed switch would only detect a shut door but my project detects the bolt of the lock in the frame.

I only use Spark.publish but if the local cloud doesn’t support web socket events at all then I may have to rethink.

I went to a talk by the author of node red. It looks good but I prefer to code rather than drag and drop.

A lever type snap action switch would be a little cleaner. A reed switch would work if you drill into the bolt and put a small button type neo-magnet in it. I just use those cheap 433MHz transmitters and a PIC to send to a main receiver, which then tells me what’s going on.

I’m pretty happy with the switch. The paper-clips lasted longer than the shower room! After 7 months they were still working great. The office has been gutted and is being refurbished so I was using the hardware for my Christmas tree: https://unop.uk/hardware/spark-core-xmas-tree-lights-10-minute-hack/

My first attempt was to use two springs but the bolt wasn’t conductive so would need modifying. I hadn’t expected to use the paper-clip rig beyond the prototype stage but it performed so well that I kept it for version 1. It survived being ripped out for the build and for demoing at events. The electrical connections are just old school wire wrapped too. Damp isn’t an issue as it’s not exposed to the room when in use.

These comments have some useful ideas: http://hackaday.com/2015/01/02/shower-occupancy-sensor-keeps-peaceeliminates-odor-at-the-office/

Thinking of writing up how to make the paper-clip switch on my blog.

I’ve written up the new version of this project: https://unop.uk/dev/spark-core-raspberry-pi-blinky-tape-awesome/

Not completely finished yet but got the basic concept prototyped and checked it works.