With the cloudy summer weather approaching, I decided I needed a new project. I've never really understood what Arduino micro controllers were all about so decided to investigate. A trip to Jaycar last weekend, a bag full of goodies and a few hours of youtube later I now have a basic weather station connected to the PC reporting the light, barometric pressure, relative humidity, temperature, sky temperature, dew point and rain every 5 seconds.
I was surprised at how easy it was to set up the electronics and write the Arduino code. The difficult part that I'll be embarking on next is how to display that information and potentially integrate that into Ascom.
I'm quite keen on the Grafana type visual interface however I have a lot of questions to set me on a productive path as I'm staring from zero knowledge so watch this space.
Images to come.
Last edited by peter_4059; 25-10-2019 at 09:51 PM.
Hi Peter
well done what a project you have started I have never looked into Arduino Kits do you have any links to how this project all goes together
very interesting stuff
cheers Pete
I had zero knowledge of Arduino this time last week. I got the prototype up and running in eight hours so it is pretty simple given my coding experience (almost none).
All the parts I used are from Jarcar. The part numbers are:
XC3902 - Arduino starter kit (this contains the Arduino Uno, the breadboard and some hookup wires
The sensors are:
XC-3704 - Non contact IRsensor module
XC-4446 - Photosensitive LDR sensor module
XC-4603 - Rain sensor
XC-4520 - Temperature and Humidity sensor module
XC-3702 - Barometric Pressure sensor module
Once you have the parts you need to install the Arduino IDE software on the PC you intend to use to program the Arduino Uno.
You then connect the Uno to the PC via USB and start t write the code.
There are Adafruit libraries for some of the modules I used (IR module, Barometric pressure module and the Temp/Humidity module). These get downloaded and linked into the Arduino IDE environment.
The ones I used were :
Adafruit_MLX90614.h
Adafruit_Sensor.h
Adafruit_BMP085.h
The Arduino code is a form of C I think.
I've attached my code in the text file if you want to see what it looks like however I'm a novice so there might be much better coding practices than this.
Enjoy.
Peter
Last edited by peter_4059; 26-10-2019 at 06:38 PM.
Cheers Rob. That was the easy part. I'm now trying to learn how to write the Ascom driver. I'd also like to create a pc dashboard with the data trended however I think there is a lot more to that. I've been looking at a product called Grafana that looks quite good but haven't worked out how all the bits fit together yet.
I'm currently thinking VB but could do C# if necessary. There are plenty of youtube videos and github code - the trick is finding the one that is going to be helpful.
I've got it all properly installed outside now and had a good opportunity to test this evening with heavy cloud rolling in. I think I've got the detection setting dialled in now so will be focusing on trying to write an ascom driver and/or a decent pc interface.
Yes that's correct Rob. It calculates the difference between ambient and sky temp (IR measurement) and you build a model of the temp difference for clear and cloudy. Last night was first proper cloudy night so I was able to observe the temp difference change as the clouds rolled in and then calibrate the model. Next step is to work on the pc end interface.
Very cool, Peter. I'll need something like this once I get around to motorizing my ROR. I haven't decided whether to DIY like you have, or buy something off the shelf. I may end up doing the latter... I'm wary about risking very expensive equipment by trying to save a few bucks.
It would be interesting to look inside some of the commercial detectors. I wouldn't be surprised to find an Arduino in many of them. The detectors in the images all look like the MLX IR sensor I'm using. The tricky part is the code. I'm currently using a simple straight line correlation but might change that if I observe a different relationship over time. In any case I'm not automating a roof, I don't have expensive equipment and I just want feedback of the sky conditions when I'm sitting inside the house.
Last edited by peter_4059; 30-10-2019 at 07:02 PM.
One step closer...got my desktop app drafted up this evening in Processing. Not exactly how I hope the end product will look but it is a steep learning curve and any small win is good as far as I'm concerned. This one is using random number generators. Tomorrow night should see it getting real time data....
It would be interesting to look inside some of the commercial detectors. I wouldn't be surprised to find an Arduino in many of them. The detectors in the images all look like the MLX IR sensor I'm using. The tricky part is the code. I'm currently using a simple straight line correlation but might change that if I observe a different relationship over time. In any case I'm not automating a roof, I don't have expensive equipment and I just want feedback of the sky conditions when I'm sitting inside the house.
Oh I wouldn't be surprised in the least to see an Arduino in commercial products, nor am I trying to detract from your project in any way. I'm giving serious thought to doing the same.
My main concern is that in all but the most trivial of applications, there's bugs. Theoretically a commercial product will have been tested more thoroughly and be in use by many more people so it may be less likely to have catastrophic bugs. The flip side to that is, if there is a bug, you're beholden to the manufacturer to fix it.
Anyway, I think this is a great project and it looks like yours is coming along very well. Great work, Peter!
Theoretically a commercial product will have been tested more thoroughly and be in use by many more people so it may be less likely to have catastrophic bugs.
That might be true and I'm no codemonkey but I have managed to get it working today