Skip to content
Permalink
4ef194f24a
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
189 lines (156 sloc) 9.58 KB
Example(s) for each of the webctrl command line tools
---------------------------------------------------
### wc_query - Query the children of a node
webctrl/bin$ ./wc_query -u wsdl -f ../SETTINGS -n /trees/geographic
No password specified via -p. Please enter your WebCTRL login password:
Children of "/trees/geographic":
[#verbrauchszaehlung, #geb_a, #geb_b, #geb_c, #geb_d, #geb_e, #geb_f, #geb_g, #geb_k, #geb_l, #geb_m, #geb_pnq, ...]
webctrl/bin$ ./wc_query -u wsdl -f ../SETTINGS -n /trees/geographic/#geb_e/#kaltw_erzeuger_fel/#km_speicher_fel
No password specified via -p. Please enter your WebCTRL login password:
Children of "/trees/geographic/#geb_e/#kaltw_erzeuger_fel/#km_speicher_fel":
[m032, m007, m008, m034, m033, m001, m005, m004, m003, m002, m006, m019, m020, m017, m018, m012, m013, m014, m015, ...]
ODER:
/webctrl/bin$ ./wc_query -u wsdl -f ../SETTINGS -n '#km_speicher_fel'
No password specified via -p. Please enter your WebCTRL login password:
Children of "#km_speicher_fel":
[m032, m007, m008, m034, m033, m001, m005, m004, m003, m002, m006, m019, m020, m017, m018, m012, m013, m014, m015, ...]
### wc_getValue - get the present value (the present_value attribute) of a m??? controller
webctrl/bin$ ./wc_getValue -u wsdl -f ../SETTINGS -n '#km_speicher_fel/m001'
No password specified via -p. Please enter your WebCTRL login password:
Present value of #km_speicher_fel/m001 is: 15.187662
OR with WC_NODE='#km_speicher_fel/m001' in the SETTINGS file:
webctrl/bin$ ./wc_getValue -u wsdl -f ../SETTINGS
No password specified via -p. Please enter your WebCTRL login password:
Present value of #km_speicher_fel/m001 is: 15.342966
### wc_monitor - monitor a specific controller
# with WC_NODE='#km_speicher_fel/m001' in the SETTINGS file:
webctrl/bin$ ./wc_monitor -u wsdl -f ../SETTINGS
No password specified via -p. Please enter your WebCTRL login password:
09:54:49 15.342966
09:54:51 15.290968
09:55:38 15.342427
09:56:18 15.393141
^CExiting due to keyboard interupt...
### wc_getReport - get a report for a node (one level lower than m???)
webctrl/bin$ ./wc_getReport -u wsdl -f ../SETTINGS -n '#km_speicher_fel/m001'
No password specified via -p. Please enter your WebCTRL login password:
| Standort |
|---------------------------------------------------------------
| Fr die aktuellen Optionen wurden keine Ergebnisse gefunden.x |
webctrl/bin$ ./wc_getReport -u wsdl -f ../SETTINGS -n '#km_speicher_fel'
No password specified via -p. Please enter your WebCTRL login password:
| Standort | Regelungsprogramm | Name | Wert | Typ | Objekt-ID | Gerte-ID | Objektname | Offset/Polaritt | Pfad |
|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
| /Fritz-Haber-Institut/Bauteil E/Kaltwassererzeuger | Kaltwassererzeuger | FEL Kaltwasser Durchflussmenge Verteiler | 6.0 m3/Std. | BMAI | AI:315818 | DEV:34157 | m032_5 | | #km_speicher_fel/m032 |
| /Fritz-Haber-Institut/Bauteil E/Kaltwassererzeuger | Kaltwassererzeuger | FEL Kaltwasser Kltemaschine Rcklauftemperatur x | 9.684903 C | BMAI | AI:2796280 | DEV:34157 | m007_5 | | #km_speicher_fel/m007 |
| /Fritz-Haber-Institut/Bauteil E/Kaltwassererzeuger | Kaltwassererzeuger | FEL Kaltwasser Kltemaschine Vorlauftemperatur | 9.069413 C | BMAI | AI:2796279 | DEV:34157 | m008_5 | | #km_speicher_fel/m008 |
| ...
### wc_getTrend - get timestamps and data values of a specific controller for a specific time period
### If no time period and number of values to retrieve are specified you'll get the last ten values
webctrl/bin$ ./wc_getTrend -u wsdl -f ../SETTINGS -n '#g_primzuluft_trend/m006'
No password specified via -p. Please enter your WebCTRL login password:
No start time specified. ...
No end time specified. ...
No parameter 'limit' specified. ...
No parameter 'maxRec' specified. ...
08/01/2017 09:30:00 AM 49.748962
08/01/2017 09:45:00 AM 49.74543
08/01/2017 10:00:00 AM 49.6482
08/01/2017 10:15:00 AM 50.137894
08/01/2017 10:30:00 AM 51.30997
08/01/2017 10:45:00 AM 51.014744
08/01/2017 11:00:00 AM 51.01651
08/01/2017 11:15:00 AM 51.205673
08/01/2017 11:30:00 AM 51.209206
08/01/2017 11:45:00 AM 51.01651
### Specify the amount of values you want to retrieve starting from the time of retrieval
webctrl/bin$ ./wc_getTrend -u wsdl -f ../SETTINGS -n '#g_primzuluft_trend/m006'
No password specified via -p. Please enter your WebCTRL login password:
No start time specified. ...
No end time specified. ...
No parameter 'limit' specified. ...
No parameter 'maxRec' specified. ...
08/01/2017 10:45:00 AM 51.014744
08/01/2017 11:00:00 AM 51.01651
08/01/2017 11:15:00 AM 51.205673
08/01/2017 11:30:00 AM 51.209206
08/01/2017 11:45:00 AM 51.01651
### Specify the amount of values you want to retrieve starting from the beginning of recording the specified controller
### by using the -l switch
webctrl/bin$ ./wc_getTrend -u wsdl -f ../SETTINGS -n '#g_primzuluft_trend/m006' -m 5 -l
No password specified via -p. Please enter your WebCTRL login password:
No start time specified. ...
No end time specified. ...
05/03/2017 12:13:27 AM 45.4478
05/03/2017 05:43:32 AM 44.273945
05/03/2017 06:23:31 AM 43.200867
05/03/2017 07:13:32 AM 42.028778
05/03/2017 08:26:02 AM 47.01764
### The usage of the date+time options -s and -e as well as in connection to -l are examplified:
webctrl/bin$ ./wc_getTrend -u wsdl -f ../SETTINGS -n '#g_primzuluft_trend/m006' -m 5 -s '07/30/2017 03:00:00 AM' -e '07/30/2017 06:00:00 AM'
No password specified via -p. Please enter your WebCTRL login password:
No parameter 'limit' specified. ...
07/30/2017 05:00:00 AM 49.358273
07/30/2017 05:15:00 AM 49.358273
07/30/2017 05:30:00 AM 49.360043
07/30/2017 05:45:00 AM 49.25927
07/30/2017 06:00:00 AM 49.26281
stefan@muonio: ~/PycharmProjects/webctrl/bin$ ./wc_getTrend -u wsdl -f ../SETTINGS -n '#g_primzuluft_trend/m006' -m 5 -s '07/30/2017 03:00:00 AM' -e '07/30/2017 06:00:00 AM' -l
No password specified via -p. Please enter your WebCTRL login password:
07/30/2017 03:15:00 AM 49.361805
07/30/2017 03:30:00 AM 49.55097
07/30/2017 03:45:00 AM 49.55627
07/30/2017 04:00:00 AM 49.459038
07/30/2017 04:15:00 AM 49.552734
### Get all values (-m 0) between the times given in -s and -e. Notice the difference when using -l:
webctrl/bin$ ./wc_getTrend -u wsdl -f SETTINGS -n '#g_primzuluft_trend/m006' -m 5 -s '07/30/2017 03:00:00 AM' -e '07/30/2017 06:00:00 AM' -m 0
No password specified via -p. Please enter your WebCTRL login password:
No parameter 'limit' specified. ...
07/30/2017 03:15:00 AM 49.361805
07/30/2017 03:30:00 AM 49.55097
07/30/2017 03:45:00 AM 49.55627
...
07/30/2017 05:30:00 AM 49.360043
07/30/2017 05:45:00 AM 49.25927
07/30/2017 06:00:00 AM 49.26281
webctrl/bin$ ./wc_getTrend -u wsdl -f SETTINGS -n '#g_primzuluft_trend/m006' -m 5 -s '07/30/2017 03:00:00 AM' -e '07/30/2017 06:00:00 AM' -m 0 -l
No password specified via -p. Please enter your WebCTRL login password:
07/30/2017 03:00:00 AM 49.552734
07/30/2017 03:15:00 AM 49.361805
07/30/2017 03:30:00 AM 49.55097
...
07/30/2017 05:15:00 AM 49.358273
07/30/2017 05:30:00 AM 49.360043
07/30/2017 05:45:00 AM 49.25927
### wc_checkAlarms - check all alarms of a specified node
webctrl/bin$ ./wc_checkAlarms -u wsdl -f SETTINGS -i 1 -t 1
No password specified via -p. Please enter your WebCTRL login password now:
No verbosity specified. ...
No interval specified. ...
No time to take action specified. ...
# You don't see anything if there are no unhandled/unchecked alarms. So, switch on the verbose output to see a bit
# what's happening:
webctrl/bin$ ./wc_checkAlarms -u wsdl -f SETTINGS -i 1 -t 1 -v
No password specified via -p. Please enter your WebCTRL login password now:
Appending alarm 2017-08-08 15:27:58 Geb.R Anlage 01 Sammelstrung to alarmsActive
No alarms in list alarmsChecked
(datetime.datetime(2017, 8, 8, 15, 27, 58), u'/Fritz-Haber-Institut/Bauteil R/Lftung/Zuluftanlage/Geb.R Zuluftanlagex', u"Geb.R Anlage 01 Sammelstrung is in an alarm state of 'ON'.", u'Geb.R Anlage 01 Sammelstrung', u'Nicht besttigt', u'Heizung, Lftung, Klimatechnik - Allgemein', u'Unnormal')
Age: 0.0
a.reminderNotification= 0
a.firstNotification= False
-----------------------------------------------------------------------------------------
No alarms in list alarmsChecked
(datetime.datetime(2017, 8, 8, 15, 27, 58), u'/Fritz-Haber-Institut/Bauteil R/Lftung/Zuluftanlage/Geb.R Zuluftanlagex', u"Geb.R Anlage 01 Sammelstrung is in an alarm state of 'ON'.", u'Geb.R Anlage 01 Sammelstrung', u'Nicht besttigt', u'Heizung, Lftung, Klimatechnik - Allgemein', u'Unnormal')
Age: 1.0
a.reminderNotification= 1
a.firstNotification= True
-----------------------------------------------------------------------------------------
No alarms in list alarmsChecked
(datetime.datetime(2017, 8, 8, 15, 27, 58), u'/Fritz-Haber-Institut/Bauteil R/Lftung/Zuluftanlage/Geb.R Zuluftanlagex', u"Geb.R Anlage 01 Sammelstrung is in an alarm state of 'ON'.", u'Geb.R Anlage 01 Sammelstrung', u'Nicht besttigt', u'Heizung, Lftung, Klimatechnik - Allgemein', u'Unnormal')
Age: 2.0
a.reminderNotification= 1
a.firstNotification= True
Sending an e-mail to weiher@fhi-berlin.mpg.de
-----------------------------------------------------------------------------------------
No alarms in list alarmsChecked
...