I have some portable weather stations that are using the CR10X datalogger, and we are updating to the CR1000 because we need some additional functionality.
First, a description of our weather stations. We are setting up portable stations similar to the RAWS systems, but ours are used for flight testing, often in remote locations where there is no other weather data available. Our systems are set up temporarily, monitored in real time (using RTMC), and then torn down at the end of the day with data parsed by SPLIT and saved for historical data.
We have the following sensors:
HMP45C (temp, rh)
CM3 (solar radiation)
CS105 (barometric pressure)
05103 wind sensors with 32500 electronic compass
We'll be updating the wind sensors soon, likely to RM Young 85000 series ultrasonic sensors.
We display measurements of wind speed/direction and solar radiation once every second. Every 60 seconds I display temp, RH, and pressure. Every five minutes I display gust data, prevailing wind direction, and standard deviation of wind direction for the past five minutes.
I have all this working on the CR10X and ported over to the CR1000 as well just fine, but I would like to make some refinements on the CR1000. List of things I want to change:
1. Add GPS for the following:
a. position data, only needs to be stored once per test setup.
b. time data, used to set station time to local time. This presents a couple issues (how does end user set UTC offset without editing .CR1 file? Is daylight saving time taken into consideration automatically, or need to be set by user?)
c. Use $GPRMC string to get Magnetic Variation, which would then allow true north to be displayed instead of magnetic north.
2. I'd like to change the five minute averages and standard deviation to be a rolling five minutes instead of 'chunk' data. I assume this is possible with the CR1000 but haven't started working on it yet.
Here's where I'm stuck. I have a test program working for the GPS data, using the samples in the GPS16X-HVS manual. There were some errors in the example that I fixed, but I am still having a problem with running the examples concurrently. It seems I can either store the GPS data in an array and then use the GPS command in the main program to set station time first example), or I can store the individual GPS strings in table format (second example) but if I use the GPS command in the main program, this breaks the tables and fills them with empty data.
I also noticed that there is a problem with the second example in that it is looking for the position of data in string, not for the comma delimiters. This means that if any data is absent, all of the subsequent pieces are incorrect. I'd rather not use this method as it appears to be unreliable.
So how do I write the arrays from the first example (page 8,9 in the manual) to a data table as in the second example (page 10,11)? I can't seem to get it to work.