Jump to content

Banner.jpg.b83b14cd4142fe10848741bb2a14c66b.jpg

My prototype cloud sensor - suggestions wanted


pete_l

Recommended Posts

After a couple of days hacking away at the software, I've got my prototype cloud sensor sensing clouds.

cloudsensor.jpg

By the look of it, I might even be able to test it with a clear sky tonight.

Here's the run-down of the project.

I used an MLX90614 I-R thermometer chip (the round thing above the LCD) as a temperature sensor. it measures "seen" temperature, which I've labelled Sky on the display and its own ambient temperature (Amb). I'm displaying the results in degrees K, for the time being.

When the sky temperature gets to be 40°K below ambient the software puts a lilltle * on the display, below the Clr text to indicate a clear sky.

The software runs on an old PIC 16c84, since I have a whole load of them which need using up :) and is written (mostly) in HiTech C. As it stands I have about 100 words of code space and 1 byte of RAM spare - and I'm looking for suggestions!

What features would you like in a cloud/clear-sky sensor?

So far, the plan is to have the software either switch a relay / opto-switch when a clear sky is detected. Possibly "beep" a little buzzer, too. Although than could get annoying. When I productionise it, I'll probably remove the LCD and instead have a serial + USB connection to a PC. That way I can also power the board from the USB.

The other question is: how to mount it. I expect this to become a permanent fixture, so I'm looking for a weatherproof container. Plan "A" is to fit it all into some white uPVC pipe, with the sensor sticking out of an end cap. (I'm told the sensor is weatherproof, this could be the test of that claim.) Then run a longish USB cable down into the house and log sky/ambient temperatures on a PC.

Link to comment
Share on other sites

Impressive!

I suspect the ideal for many people would be if it were like an alarm clock - that is, I could say wake me at 4AM but only if it's clear. I guess the easiest way to work towards this might be with a countdown timer rather than a proper clock, so that if I were going to bed at 10, I'd set it to wake me in 6 hours but only if it's clear.

No idea how difficult that would be, mind, but you seem to have skills.

Link to comment
Share on other sites

When the sky temperature gets to be 40°K below ambient the software puts a lilltle * on the display, below the Clr text to indicate a clear sky.

This is a very interesting project. What's the rationale for taking a 40 degree difference as indicating a clear sky?

Link to comment
Share on other sites

This is a very interesting project. What's the rationale for taking a 40 degree difference as indicating a clear sky?

Purely arbitrary. When I get a clear looking sky I'll see what the temperature difference is and maybe adjust accordingly. I think I read somewhere that a clear sky is around -60°C, though I also have a link [here] that uses a difference of around 30° below ambient.

Link to comment
Share on other sites

It's probably around £40 in parts (the sensor came to nearly £20 delivered) - and another £1k in software development time!. So far as "does it work?" who knows :) it's a prototype - I'll find out over the next few weeks

Link to comment
Share on other sites

You've probably noticed that there is a similar project (or projects) going on in the thread here:

http://stargazerslounge.com/diy-astronomer/106144-arduino-focus-control-cloud-sensor.html

It uses the same Melexis sensor and is based on the Arduino boards. I think 40 degrees of difference is a bit too much. It also seems to depend on location and how many heat sources are around that mess up your IR readings. In my case I get about 10-15 degrees of difference when it's clear-ish.

Interesting idea with the sky condition based alarm. My next project is an exact clock with big red numbers for my (future) obsy. I was going to use a MSF radio clock receiver but they turned out to be too complex to interpret the data. ;-) So I ordered a GPS module that sends me the current time and location via serial. I might consider an alarm based on cloud status... ;-)

Link to comment
Share on other sites

You've probably noticed that there is a similar project (or projects) going on in the thread

Yes, I've been watching that thread.

I do agree that a 40° temperature differential does appear to be too large. I think the piece I saw which advised that was probably from a warmer part of the world. Since we got a short clear interval this afternoon, I field-tested my prototype and reckon that 25-30° is a more practical figure. Although I do have a sneaking suspicion that a thorough solution would either have to be adaptive, or would involve several logic steps. I.e.: If the differential is > X or the ambient is < Y and the sky is < Z, or the ambient is > A and the sky is less than B. It could take a while to fine-tune the algorithm.

The field of view of the sensor does seem to be quite broad. When I was testing it indoors, I noticed that waving my soldering iron around, I registered a change in reading with the iron at quite low angles WRT the sensor's vertical axis.

So far as MSF goes. I did build a receiver many years ago - back in the 80's. Just out of logic gates. It only showed the time though, not the date information. And the transmitter was turned off (IIRC) on tuesday mornings for maintenance. I've still got it somewhere, must dig it out again ...

Link to comment
Share on other sites

Looks nice.

What is the field of view of the sensor? What fraction of cloud cover do you need for it to trigger? Guess these are things to test on-sky once it is working.

For an alarm, can you implement some kind of time averaging? Wouldn't want to be woken up for a passing bit of cirrus, or a narrow sucker-hole, for example. Should probably only trigger if it's been clear/cloudy for the past N minutes. Maybe you could also include some kind of trending algorithm in the PIC?

The IR satellite images are notoriously bad at picking up low (warm) cloud, which a cloud sensor like this should see.

Link to comment
Share on other sites

The FOV of the sensor appears to be quite wide. An unscientific test shows that when a hot soldering iron is positioned +/- 45° off-axis, that still makes a marked difference to the measured "sky" temperature - which the sensor takes as an average over it's entire field. It's also remarkably unaffected by direct sunlight.

I've also been thinking about adding some hysteresis to the detection. So that it doesn't go off immediately after passing it's "clear" threshold, but needs (say) 5 minutes of solid clear. however it flags cloudy immediately. That would give the most warning of impending cloud-over and possible rain. I've also been considering a day/night sensor, so it only fires the alarm when the night sky is clear. I also think the alarm needs to have a disable function, so it doesn't drive you batty when you're up and observing: "yes, I *know* it's clear! grrrrr."

Link to comment
Share on other sites

The standard version of the sensor has a field of view of 90 degrees, though it doesn't have a sharp edge. It shows the average temperature over the whole FoV. The sensor also has a filter in front that blocks visible and near IR light. That's why the sun doesn't bother it much.

You can get narrower FoV versions but the price seems to increase exponentially with decreasing FoV. ;-)

Link to comment
Share on other sites

Hi, I've been thinking of making myself something like this as well. One question I have though is how directional the temperature sensor is? That is, suppose I have it outside pointed at zenith. If it is indicating clear sky, does that mean the zenith is clear, but perhaps there could be surrounding clouds scattered about the sky? Or does the sensor have a fairly wide field of view, so to speak?

If it is fairly directional, would it be possible to mount several sensors in some kind of dome arrangement so that readings from all over the sky could be taken and then used to form a view as to whether it is truly cloudless or not?

David

Link to comment
Share on other sites

The sensor has a field of view of 90 degrees (standard version). So it would look up and 45 degrees on either side. It then measures the _average_ temperature of the whole field. So it wouldn't detect a few small cloud I think. It is still a bit of guesswork. But still better than not knowing at all ..;-)

The same sensor is also used in some commercial cloud sensors though. Not sure how accurate these are....

Link to comment
Share on other sites

Hmmm, I guess the detection of small clouds in the FOV could be handled by requiring a greater difference between sky and ambient? The smaller the difference, presumably the less sensitive it becomes at detecting cloud cover if that makes sense?

Probably I should just get myself some kit and have a play around. I already have PIC, so just need the sensors.

Link to comment
Share on other sites

Sounds about right. I think the measured difference in temperature depends a lot on location. My sensor is mounted in my drive way between 2 houses pointing towards the patch of sky I can see from there over the garage. With all these heat and IR sources around, the biggest temperature difference I get is around 15 degrees, more like 10 deg on average when it's clear. I guess if the same setup was somewhere in an open field I would get very different results...

So I get the feeling this has to be tweaked for each location.

Link to comment
Share on other sites

Average clear night sky reading with the Melexis Ive been getting is -32C which is pretty much spot on. Its quite sensitive to cloud and your readings will climb quite quickly when cloud is in the FOV and drop just as quickly when its passed, if your using for an alarm it would be best to build in a delay of some sort.

Link to comment
Share on other sites

This looks like the start of a very good product. You have the basics there. This being the temperature measurement components, the intelligence to alter response (PIC) and a user interface (LCD or USB).

For me, a free standing instrument that just measures cloud is not that much use. I can look out of the window, or even open the door.

However, the idea of an alarm clock with 'wake me at 3am if the sky has been clear for 30 minutes' type of output is a very good idea. The Box could be left on the bedroom window sill and a sounder wire run through an opening window.

Programming alarm or sensitivty parameters to suit the individual is a very good idea. If you are looking at a commercial project, then an extra quid (or less) on a bigger PIC to give more features is not a show stopper. A box that does not suit the user will not get used. You could use the USB interface to talk to a simple PC application to configure the box. Most of us have a computer of sorts. A front panel display & buttons cost more money than a USB link, so PC configuration has to be the way forward.

Having got the box linked to a PC, there are those who will want to log cloud cover, send data to their friends via the internet, use the data to open/close the obsy roof. The list is probably endless.

Excellent idea and I wish you all the best with it's development. In fact, I will buy one when it is in production. Nice to see innovation in the UK instead of just buying in chinese electronics boxes.

Link to comment
Share on other sites

There are commercially available cloud sensors.

Aurora: http://www.auroraeurotech.com/CloudSensor.php

Boltwood I: Cyanogen Imaging Products from Diffraction Limited

Boltwood II: Cyanogen Imaging Products from Diffraction Limited

Cheapest is Aurora at around £200 so DIY certainly looks a cheaper option (though it also has rain and light sensors). Boltwood II is $1700!

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. By using this site, you agree to our Terms of Use.