[arm-allstar] Weather script updates are out
David
dvd at dalfonso.us
Mon Jan 13 15:04:11 EST 2020
Doug,
More detail on the wx_condition.sh error. Below is the command line
output when I run the script. -Dave k6dvd
"2020-01-13 11:54:43"
/usr/local/sbin/wx_condition.sh: line 475: [: too many arguments
-----------------------------------
Temperature - 56 F / 13 C
Humidity - 55 Percent
Wind Direction - NNW at 2 miles per hour
Wind Gusts - 2 miles per hour
Barometric Pressure - 30.14 inches
Dew point - 40 F / 5 C
Precipitation Today - 0 inches
Wind Chill - 56 F / 13 C
Heat Index - 56 F / 13 C
Solar Radiation - 496.3
UV - 1
/usr/local/sbin/wx_condition.sh: line 116: [[: 496.3: syntax error:
invalid arithmetic operator (error token is ".3")
/usr/local/sbin/wx_condition.sh: line 122: [[: 496.3: syntax error:
invalid arithmetic operator (error token is ".3")
/usr/local/sbin/wx_condition.sh: line 133: [[: 496.3: syntax error:
invalid arithmetic operator (error token is ".3")
/usr/local/sbin/wx_condition.sh: line 136: [[: 496.3: syntax error:
invalid arithmetic operator (error token is ".3")
cat: /var/lib/asterisk/sounds/digits/.gsm: No such file or directory
cat: /var/lib/asterisk/sounds/digits/.gsm: No such file or directory
On 1/13/2020 11:02 AM, "David via ARM-allstar" wrote:
> Doug,
>
> Thanks for getting the wunderground info back online. Weather.sh
> works fine and I see only one issue with wx_conditions.sh.
>
> The solar radiation measurement says only the word "solar" and no
> numeric value.
>
> -Dave k6dvd
>
> On 1/13/2020 8:38 AM, "Doug Crompton via ARM-allstar" wrote:
>> Darrell,
>>
>> The weather scripts always allowed zip, airport or personal
>> wunderground
>> weather station reports. The update was because wundergrounds web
>> presence
>> was taken over by IBM in the last year. They completely changed the
>> way raw
>> data from the stations was presented changing from an xml to a json
>> format.
>> So the two weather scripts no longer worked for wunderground reports.
>> The
>> update fixed that. If you are using zip or airport codes there is no
>> change
>> but you do again have the ability to access wunderground weather
>> stations
>> if you desire.
>>
>> It has also been confirmed since my last message that apparently
>> anyone can
>> get an api key regardless of whether you have a real physical station or
>> not. You just have to sign up at the web site and setup a fake
>> station and
>> get the api key. I am not sure this will always work but it appears
>> to for
>> now.
>>
>>
>> *73 Doug*
>>
>> *WA3DSP*
>> *http://www.crompton.com/hamradio <http://www.crompton.com/hamradio>*
>>
>> On Mon, Jan 13, 2020 at 11:20 AM Darrell Black <gigahacker at gmail.com>
>> wrote:
>>
>>> I am a little confused. I use the weather on our repeater each hour.
>>> I did
>>> this by adding the zip code to the time announcement. Is this the same
>>> thing or is there more weather accountment I didn't know about?
>>>
>>> On Sun, Jan 12, 2020 at 8:57 PM "Doug Crompton via ARM-allstar" <
>>> arm-allstar at hamvoip.org> wrote:
>>>
>>>> The weather scripts weather.sh and wx_condition.sh have been
>>>> updated with
>>>> RPi 2-3-4 version 1-6-08 to accept and work with the new
>>>> wundergound (IBM)
>>>> json format for home weather stations. The prior format was xml.
>>>>
>>>> This updates the two scripts and also the two ini files which if you
>>>> previously changed you will need to do so again. They are very
>>>> simple ini
>>>> files so no big deal. The api key is blank in the two files. If
>>>> you do
>>>> not
>>>> intend to use wunderground then they can be left blank. This update
>>>> also
>>>> installs the package jq which is a command line json reader.
>>>>
>>>> I believe I have all the bases covered but it was a substantial
>>>> change and
>>>> if there are other things that need to be done they will be. Users
>>>> that
>>>> want to use wunderground station reporting must get an api key from
>>>> the
>>>> web
>>>> site -
>>>>
>>>> https://www.wunderground.com/member/api-keys
>>>>
>>>> I have two stations and I had previously been registered so it was
>>>> easy to
>>>> get an api key at this site. Once you have the key you should cut and
>>>> paste, or accurately copy it to the api_Key= variables in
>>>> /etc/asterisl/local/weather.ini and wx_condition.ini files. The two
>>>> scripts should otherwise work the same. Running the scripts without
>>>> any
>>>> parameters will give parameter examples.
>>>>
>>>> Three parameters have been added - precipitation rate, solar
>>>> radiation and
>>>> UV level for wundergound stations that provide those values.
>>>>
>>>> Since I have stations and contribute data I was able to get the api
>>>> key
>>>> very easily. I am not sure if you have to be a contributing member
>>>> to get
>>>> a
>>>> key. Obviously the scripts will work with other services like the
>>>> National
>>>> Weather Service and using airport and zip codes if you cannot get a
>>>> key.
>>>>
>>>> Please let me know how this is working for you if you use it.
>>>>
>>>>
>>>> *73 Doug*
>>>>
>>>> *WA3DSP*
>>>>
>>>> *http://www.crompton.com/hamradio <http://www.crompton.com/hamradio>*
>>>> _______________________________________________
>>>>
>>>> ARM-allstar mailing list
>>>> ARM-allstar at hamvoip.org
>>>> http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
>>>>
>>>> Visit the BBB and RPi2/3/4 web page - http://hamvoip.org
>>>>
>>>
>>> --
>>>
>>> Darrell Black
>>>
>>> (517) 917-2226
>>> GigaHacker at gmail.com
>>> http://www.linkedin.com/in/darrellblack
>>>
>>>
>>> 73 de W8DSB
>>> "In God we trust, all others we monitor"
>>>
>>> GMRS WRDE739
>>>
>> _______________________________________________
>>
>> ARM-allstar mailing list
>> ARM-allstar at hamvoip.org
>> http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
>>
>> Visit the BBB and RPi2/3/4 web page - http://hamvoip.org
> _______________________________________________
>
> ARM-allstar mailing list
> ARM-allstar at hamvoip.org
> http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
>
> Visit the BBB and RPi2/3/4 web page - http://hamvoip.org
More information about the ARM-allstar
mailing list