Author Topic: Self-build Arduino HA sensors controlled with VoxCommando  (Read 28977 times)

0 Members and 1 Guest are viewing this topic.

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2318
  • Karma: 47
    • View Profile
Self-build Arduino HA sensors controlled with VoxCommando
« on: December 19, 2014, 06:37:27 AM »
Hi guys, this is one of our plan for the new year!  :bignod


We are build some wireless sensors based on arduino hardware and the API from www.mysensors.org, which is cheap and easy to handle. The sensors can be powerd by a battery/usb or power supply.
There are a lot of sensor available - for example: light switch, temperature, motion, humidity, water-level, light level, IR control, gas, dust and much more.

We started with examples from this website: http://www.mysensors.org/build/temp which has also a fantastic community. You can use this sensors with a Vera controller by connecting a self-build gateway on his USB port or as stand alone solution with VoxCommando connect to a PC.
We have created a first sensor and also a gateway PCB-board. The sensor board has a size of 44x34mm and the gateway a size of  42x30mm. Now we do some tests to get sure everything works well. At the moment we can not really say how much it will cost, because it depends how many boards we produce and which sensor parts is needed. We think it will cost ~10$ per sensor node like a temperatur sensor.


If anybody is interesting to create his own sensor or have good ideas or maybe will help us, please feel free to post here.


If you need more information, please ask for.

BIG THANKS to www.mysensors.org for the great project!


here are some "first-looks-like" photos  ;)
This is really a first look, without a case, but it will show you the size.
« Last Edit: May 28, 2015, 07:43:37 AM by Kalle »
***********  get excited and make things  **********

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7714
  • Karma: 116
    • View Profile
    • VoxCommando
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #1 on: December 19, 2014, 10:36:15 AM »
Here are some more images to give you an idea of the actual scale of the assembled base unit.  Yes I know, my hands are ludicrous.  :biglaugh

Also a schematic of the board.  This is intended as a test board, so you can build all kinds of different sensors with it without extra soldering (once you have assembled it with all the headers etc. as shown)

Foggy

  • $upporter
  • Contributor
  • *****
  • Posts: 86
  • Karma: 4
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #2 on: December 19, 2014, 12:21:33 PM »
This looks really cool.

Best wishes.

Dave

  • $upporter
  • Sr. Member
  • *****
  • Posts: 139
  • Karma: 31
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #3 on: December 20, 2014, 07:45:57 AM »
Nice! :D
I wanted to do something similar, but I'm still waiting for my Arduinos from china...
Did you already try how long the sensor can be powered by battery?

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2318
  • Karma: 47
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #4 on: December 20, 2014, 08:17:20 AM »
Hallo Dave,


die Batterie-Tests laufen noch. Ein Temperatur-Sensor läuft jetzt über 2 Wochen (mit 2 AA Batterien die aber nicht neu waren, ca. 90%) sind jetzt bei 50%. Im Moment habe ich aber noch keine LED oder Spannungsregler am ProMini gekappt. http://www.mysensors.org/build/battery
Und der Arduino Sketch sollte auch noch ein wenig angepasst werden(momentan wird alle 10 Minuten der Status gesendet).
Für VoxCommando haben wir einen Python Script, der über das Gateway von allen Sensoren die Daten als Event mit angehängten payloads, an VC ausgibt. Danach speichert VC die Daten in Map-tables (Device ID, Art des Sensors, Daten des Sensors und Datum mit Uhrzeit seit der letzten Aktualisierung). Es werden also 3 Maps generiert, die dann alles automatisch aufnehmen. Bei Interesse melde dich, vor allem wenn Du PCB-boards brauchst. Für Arduino ProMinis habe ich eine sehr gute Ebay Adresse (2 EUR pro Stück und Lieferung innerhalb von 4-5 Tagen).


UPDATE 21.12.2014: Die Batterien sind jetzt nach ca.2 1/2 Wochen erschöpft. Ich habe einen neuen Test mit entfernten LED's und angepasstem arduino sketch gestartet (Der Sensor sendet jetzt alle 30 min seinen Batteriestatus an das Gateway).
« Last Edit: December 21, 2014, 09:54:44 AM by Kalle »
***********  get excited and make things  **********

Foggy

  • $upporter
  • Contributor
  • *****
  • Posts: 86
  • Karma: 4
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #5 on: December 22, 2014, 09:19:54 AM »
Hi,

A few questions if I may.

Am I correct that if I don't have a Vera controller I can connect a Gateway via USB to my VC computer?

When do you think your software and hardware will become available for non programmers?

Best wishes.

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2318
  • Karma: 47
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #6 on: December 22, 2014, 09:41:34 AM »
You have already the Software - VoxCommando  ;)


For this project, there is no Vera controller necessary and yes you can connect the gateway via USB to your PC.
You need only run our python script within the python plugin in VC. All sketches for the Arduino Sensors are at www.MySensors.org available, I think we will modify something in the sketches, because to create a sketch for a multisensor like motion, temp, infrared.
We will do first some tests to get sure everything is working fine with our PCB board and a bit fine tunning at the python code.
If you are able to solder things on a PCB-Board, the hardware is already available. To get "out of the box" working devices take a while but sorry,  now I am still not able to tell you when it will available, maybe James have a idea.

***********  get excited and make things  **********

Foggy

  • $upporter
  • Contributor
  • *****
  • Posts: 86
  • Karma: 4
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #7 on: December 22, 2014, 10:08:48 AM »
Thank you kalle,

Yes - I was really thinking about the Python script  :)

So I can be ready. I can just build the Gateway and Sensor from the the link http://www.mysensors.org/ ? Then I will be ready for when you are to make the python & arduino code available?
I will probably try the Temp sensor first - so that I can understand how things work.

Of course I will certainly support/buy any hardware you decide to produce in the future.

Best wishes.

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2318
  • Karma: 47
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #8 on: December 22, 2014, 10:16:53 AM »
Yes, you can build the gateway and the sensor and I can post the python script and some xml's for VC. You can use the temperatur sketch from www.mysensor.org, but get sure that you have install also the mysensor libraries from her website: https://github.com/mysensors/Arduino/archive/master.zip


Our PCB board is also not necessary, but it facilitates the building of the sensors.
« Last Edit: December 22, 2014, 10:23:27 AM by Kalle »
***********  get excited and make things  **********

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7714
  • Karma: 116
    • View Profile
    • VoxCommando
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #9 on: December 22, 2014, 12:16:04 PM »
I recommend you start with a breadboard (if you have one) and later you can think about getting a PCB in order to make a nice small package.

We are happy to share the files needed to make your own but at some point next year we may make a larger batch of PCBs that would cost a lot less than having just a few of your own made.

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7714
  • Karma: 116
    • View Profile
    • VoxCommando
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #10 on: December 22, 2014, 12:20:34 PM »
There are several ways to program your Arduino.  I personally use the free software provided by Arduino but there are also plugins for your web browser etc.  It's all free stuff.

The simplest (and still cheap) way to start is probably with two Arduino Nanos.  If you want to use the Pro Mini (which is oddly smaller than the Nano) it is more difficult because the mini does not have a usb plug and you also need a special programmer (not too expensive but more complicated).

So for example you could get started with two of these (one for the gateway and one for a sensor): http://www.ebay.ca/itm/1P-HOT-USB-Nano-V3-0-ATmega328-16M-5V-Micro-controller-CH340G-board-For-Arduino-/271686219247?pt=LH_DefaultDomain_2&hash=item3f41c2b5ef

You also need other parts like the RF module and the actual sensor parts.  All that information is available at the MySensors link that Kalle posted above.

Foggy

  • $upporter
  • Contributor
  • *****
  • Posts: 86
  • Karma: 4
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #11 on: December 22, 2014, 02:21:30 PM »
Thank you.

Yes. I agree with all your recommendations. I'll come back when I have all the parts and tested.

Best wishes.

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2318
  • Karma: 47
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #12 on: February 08, 2015, 06:29:18 PM »
Hi Guys, now we can present a finished gateway which work with VoxCommando as controller.


Here is a short video, which demonstrate how VoxCommando controls our RGB-Dimmer-Sensor (Great Arduino-Sketch from Dave)  ::banana





And here some first pictures from the gateway in a housing (Zebrano-wood)
We have two different sizes of gateways.



https://www.dropbox.com/s/fiar02gnczsp6g5/gatewayPCBFront.png?dl=0


https://www.dropbox.com/s/k11egvyy4v5ivgm/gatewayPCBback.png?dl=0


https://www.dropbox.com/s/aptrp4p8285x5mo/P1040457.JPG?dl=0


https://www.dropbox.com/s/tjmnnspefrbjl8u/pcb1.jpg?dl=0


https://www.dropbox.com/s/py0xv0zrt931s8s/P1040465.JPG?dl=0


https://www.dropbox.com/s/fz0gicwzu8kesmt/P1040467.JPG?dl=0


https://www.dropbox.com/s/cnxg3djfcrz6pic/20150204_170824.jpg?dl=0


https://www.dropbox.com/s/0fue9r3q5whzpr0/20150204_155126.jpg?dl=0


https://www.dropbox.com/s/le8yiewlwwp1a4p/tinynanogateway.PNG?dl=0


I hope you will like it  ;)


PS: It is possible to order a assembled gateway (without housing), or only the PCB-board to solder things by your self. Feel free to ask for details.


We have a lot of more sensors created to show you, but first we still wait for a batch of new sensor pcb's.
« Last Edit: February 09, 2015, 04:09:36 AM by Kalle »
***********  get excited and make things  **********

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7714
  • Karma: 116
    • View Profile
    • VoxCommando
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #13 on: February 08, 2015, 08:59:29 PM »
Amazing work Kalle and Dave!  I look forward to trying out the RGB light strip myself soon.  I love the little wood boxes.  Guaranteeeeeeed high WAF!

I did some work today on the python code for the "controller" (serial communication between VC and the Gateway).  I think that auto assignment of IDs for new sensors should work well now.

The next step is to store all collected sensor data in python variables (and to a file on disk) so VC can request info any time.  I will work on this next.

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2318
  • Karma: 47
    • View Profile
Re: Self-build Arduino HA sensors controlled with VoxCommando
« Reply #14 on: February 09, 2015, 12:39:19 AM »
It looks like the project is growing fast - great work at the python code James!
***********  get excited and make things  **********