mirror of
https://github.com/weewx/weewx.git
synced 2026-08-07 05:53:48 -04:00
added partial support for acurite weather stations
This commit is contained in:
1 parent
273e9a72e0
commit
c374084cfc
5 files changed
+501
-1
No files matched your search
@@ -35,6 +35,10 @@ while [ "$STATE" != 0 -a "$STATE" != 7 ]; do
|
||||
6) # prompt for station-specific parameters
|
||||
db_get weewx/station_type
|
||||
|
||||
if [ "$RET" = "AcuRite" ]; then
|
||||
db_input high weewx/acurite_model || true
|
||||
fi
|
||||
|
||||
if [ "$RET" = "CC3000" ]; then
|
||||
db_input high weewx/cc3000_model || true
|
||||
db_input high weewx/cc3000_port || true
|
||||
|
||||
+7
-1
@@ -46,6 +46,10 @@ configure_weewxconf() {
|
||||
db_get weewx/station_type
|
||||
if [ "$RET" != "" ]; then
|
||||
sed -i "s%station_type[ ]*=.*%station_type = $RET%" $cfgfile
|
||||
if [ "$RET" = "AcuRite" ]; then
|
||||
db_get weewx/acurite_model
|
||||
sed -i "/\[AcuRite\]/,/\[.*\]/ s%[# ]*model[ ]*=.*% model = $RET%" $cfgfile
|
||||
fi
|
||||
if [ "$RET" = "CC3000" ]; then
|
||||
db_get weewx/cc3000_model
|
||||
sed -i "/\[CC3000\]/,/\[.*\]/ s%[# ]*model[ ]*=.*% model = $RET%" $cfgfile
|
||||
@@ -159,7 +163,9 @@ configure_post() {
|
||||
if [ "$1" = "driver" -o "$2" = "driver" ]; then
|
||||
driver=weewx.drivers.simulator
|
||||
db_get weewx/station_type
|
||||
if [ "$RET" = "CC3000" ]; then
|
||||
if [ "$RET" = "AcuRite" ]; then
|
||||
driver=weewx.drivers.acurite
|
||||
elif [ "$RET" = "CC3000" ]; then
|
||||
driver=weewx.drivers.cc3000
|
||||
elif [ "$RET" = "FineOffsetUSB" ]; then
|
||||
driver=weewx.drivers.fousb
|
||||
|
||||
@@ -30,6 +30,12 @@ Default: Simulator
|
||||
Description: weather station type:
|
||||
The weather station hardware type. Specify simulator to run weewx without a weather station.
|
||||
|
||||
Template: weewx/acurite_model
|
||||
Type: string
|
||||
Default: 01035
|
||||
Description: weather station model:
|
||||
Specify the station model, for example 01025, 01035, 01036, 02032C
|
||||
|
||||
Template: weewx/cc3000_port
|
||||
Type: string
|
||||
Default: /dev/ttyUSB0
|
||||
|
||||
Reference in new issue
Block a user