[arm-allstar] Weather script updates are out

Tony node4139x at gmail.com
Mon Jan 13 13:41:17 EST 2020


On 1/12/20 5:57 PM, "Doug Crompton via ARM-allstar" 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.
> ...

Thanks for the quick work, Doug. Apparently $w_type is only defined on 
line 385 when the command line specifies w-<weatherunderground id>:

# wx_condition.sh KPHX $NODE1 v
/usr/local/sbin/wx_condition.sh: line 407: [: ==: unary operator expected

Weather for Station ID - KPHX
...

# cat -n /usr/local/sbin/wx_condition.sh | grep w_type
    385          w_type="wunder"
    407          if [ $w_type == "wunder" ]
    472          if [[ "$w_type" == "wunder" ]]
    685      if [[ $w_type == "wunder" ]]



More information about the ARM-allstar mailing list