Wireless sensor

Hi

I am quite new to this arduino world

I want to build a door sensor there trough a wireless solution should tell a controller ie openhab when the door change its state.

I want this solution to run on battery, what parts would be prefered so get the longest battery time, and how long should I exept it to run on battery?

Magnetic contact sensor Magnetic contact switch (door sensor) : ID 375 : $3.95 : Adafruit Industries, Unique & fun DIY electronics and kits
And don't use an Arduino, use an atTiny85 or atMega they can run for years on a button cell as long as they're not always doing a large amount of work

If a use atiny85 what type of communikation should I ain after to preserve as much battery time as posible

Speedy911:
If a use atiny85 what type of communikation should I ain after to preserve as much battery time as posible

It really depends on what you're looking for. Obviously a wired connection would be the most battery efficient but if you need it to be wireless you can go with Bluetooth or wifi and just use a bigger battery. The thing about not being wireless though is if you're planning to have wires you may as well just plug it in the wall and never have to worry about battery.

It's really up to you and your application. :slight_smile:

Bluetooth is a horrible idea. Pairing limitations, power usage, skip BT.

If you watch the vid I posted, the sensor module directly connects to the internet.

Otherwise with an ATTiny, you're better off going with a cheap RF link that would send a message to a base unit that's wall-powered. But if you have a base station, there's no need for the ATTiny, as there are plenty of PT2262 type pairs which can work as the entire transmitter/sensor module for cheap.