From 1ae57928d7de5da42595152a681f4e4257b8ae8c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20St=C3=BCrz?= Date: Tue, 28 Oct 2014 22:34:04 +0100 Subject: [PATCH] added new logo and load each plugin json to its documentation --- doc/config.qdocconf | 6 +- doc/html-template.qdocconf | 2 +- doc/rules.qdoc | 4 +- guh.pro | 2 +- plugins/deviceplugins/boblight/bobclient.cpp | 1 + .../boblight/devicepluginboblight.cpp | 24 ++ .../conrad/devicepluginconrad.cpp | 35 +-- .../deviceplugins/elro/devicepluginelro.cpp | 33 +-- .../deviceplugins/eq-3/deviceplugineq-3.cpp | 160 ++--------- .../intertechno/devicepluginintertechno.cpp | 140 +--------- .../lgsmarttv/devicepluginlgsmarttv.cpp | 22 ++ .../deviceplugins/lircd/devicepluginlircd.cpp | 24 ++ .../devicepluginmailnotification.cpp | 208 ++------------- .../devicepluginopenweathermap.cpp | 249 +----------------- .../philipshue/devicepluginphilipshue.cpp | 23 ++ .../wakeonlan/devicepluginwakeonlan.cpp | 96 +------ .../deviceplugins/wemo/devicepluginwemo.cpp | 103 +------- .../wifidetector/devicepluginwifidetector.cpp | 25 ++ 18 files changed, 240 insertions(+), 917 deletions(-) diff --git a/doc/config.qdocconf b/doc/config.qdocconf index 613f25d1..b2b694b5 100644 --- a/doc/config.qdocconf +++ b/doc/config.qdocconf @@ -11,6 +11,8 @@ headers.fileextensions = "*.h" imagedirs = images -sourcedirs = .. -sources.fileextensions = "*.cpp *.qdoc *.json" +exampledirs = .. + +sourcedirs = .. +sources.fileextensions = "*.cpp *.qdoc" diff --git a/doc/html-template.qdocconf b/doc/html-template.qdocconf index 035a2926..47242da3 100644 --- a/doc/html-template.qdocconf +++ b/doc/html-template.qdocconf @@ -3,7 +3,7 @@ include(html-styles.qdocconf) HTML.postheader = \ "
\n" \ " \n" \ "
\n" \ "
    \n" \ diff --git a/doc/rules.qdoc b/doc/rules.qdoc index c63f24f8..db5ebc33 100644 --- a/doc/rules.qdoc +++ b/doc/rules.qdoc @@ -30,7 +30,7 @@ \section2 Event based rules Event based rules (trigger path 1) contain either one or more \l{Event}{Events} or are triggered by a \l{State} change (disregarding what - the changed State's value actually is). Such rules may still evaluate \l{States}{State} for a certain value (leaving + the changed State's value actually is). Such rules may still evaluate \l{State}{States} for a certain value (leaving Trigger path 1 and re-entering Trigger path 2), however, unless otherwise explicitly defined, the Rule is not evaluated when such a State change happens (given the Trigger path has been left by crossing a black arrow). Those rules are only executed for items on trigger path 1. @@ -55,7 +55,7 @@ State binding rules (Trigger path 2) are rules which only contains \l{State}{States} and \l{Action}{Actions}. Each time a \l{State} on that path changes, the rule is evaluated. That means, all the States in the Rule are examined. If all - evaluations are fulfilled, the Rule's \l{Actions}{Action} are executed. Please note, that such Rules may only check + evaluations are fulfilled, the Rule's \l{Action}{Actions} are executed. Please note, that such Rules may only check if states are equal to, unequal, less than or greater then some value. \section3 Examples diff --git a/guh.pro b/guh.pro index e8182f74..6b73931f 100644 --- a/guh.pro +++ b/guh.pro @@ -13,7 +13,7 @@ plugins.depends = libguh tests.depends = libguh doc.depends = libguh server -doc.commands = cd $$top_srcdir/doc; qdoc config.qdocconf; cp images/mascot.png html/images/ +doc.commands = cd $$top_srcdir/doc; qdoc config.qdocconf; cp images/logo.png html/images/ licensecheck.commands = $$top_srcdir/tests/auto/checklicenseheaders.sh $$top_srcdir diff --git a/plugins/deviceplugins/boblight/bobclient.cpp b/plugins/deviceplugins/boblight/bobclient.cpp index 53ca9ad4..177957af 100644 --- a/plugins/deviceplugins/boblight/bobclient.cpp +++ b/plugins/deviceplugins/boblight/bobclient.cpp @@ -16,6 +16,7 @@ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ + #include "bobclient.h" #include "libboblight/boblight.h" diff --git a/plugins/deviceplugins/boblight/devicepluginboblight.cpp b/plugins/deviceplugins/boblight/devicepluginboblight.cpp index 62d49386..e0c3563b 100644 --- a/plugins/deviceplugins/boblight/devicepluginboblight.cpp +++ b/plugins/deviceplugins/boblight/devicepluginboblight.cpp @@ -16,6 +16,30 @@ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/*! + \page boblight.html + \title Boblight + + \ingroup plugins + \ingroup network + + This plugin allows to communicate with a \l{https://code.google.com/p/boblight/}{boblight} server + running on localhost:19333. If a boblight server is running ,the configured light devices from the server will + appear automatically in guh. + + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. + + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + + \quotefile plugins/deviceplugins/boblight/devicepluginboblight.json +*/ + #include "devicepluginboblight.h" #include "plugin/device.h" diff --git a/plugins/deviceplugins/conrad/devicepluginconrad.cpp b/plugins/deviceplugins/conrad/devicepluginconrad.cpp index 31bc336c..d8877819 100644 --- a/plugins/deviceplugins/conrad/devicepluginconrad.cpp +++ b/plugins/deviceplugins/conrad/devicepluginconrad.cpp @@ -23,32 +23,21 @@ \ingroup plugins \ingroup rf433 - This plugin allows to controll RF 433 MHz actors an receive remote signals from Conrad - devices (\l{http://www.conrad.at}). + This plugin allows to controll RF 433 MHz actors an receive remote signals from \l{http://www.conrad.at}{Conrad} + devices. - Following devices are supported: + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. - \chapter Supported devices - \section1 Actors - \table - \header - \li Model - \li Device Type - \row - \li - \li - \endtable + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. - \section1 Remotes - \table - \header - \li Model - \li Device Type - \row - \li - \li - \endtable - */ + \quotefile plugins/deviceplugins/conrad/devicepluginconrad.json +*/ #include "devicepluginconrad.h" diff --git a/plugins/deviceplugins/elro/devicepluginelro.cpp b/plugins/deviceplugins/elro/devicepluginelro.cpp index 9b900bdf..bcd0816f 100644 --- a/plugins/deviceplugins/elro/devicepluginelro.cpp +++ b/plugins/deviceplugins/elro/devicepluginelro.cpp @@ -23,32 +23,21 @@ \ingroup plugins \ingroup rf433 - This plugin allows to controll RF 433 MHz actors an receive remote signals from Elro + This plugin allows to controll RF 433 MHz actors an receive remote signals from \l{http://www.elroshop.eu/}{Elro} devices. - Following devices are supported: + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. - \chapter Supported devices - \section1 Actors - \table - \header - \li Model - \li Device Type - \row - \li - \li - \endtable + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. - \section1 Remotes - \table - \header - \li Model - \li Device Type - \row - \li - \li - \endtable - */ + \quotefile plugins/deviceplugins/elro/devicepluginelro.json +*/ #include "devicepluginelro.h" #include "devicemanager.h" diff --git a/plugins/deviceplugins/eq-3/deviceplugineq-3.cpp b/plugins/deviceplugins/eq-3/deviceplugineq-3.cpp index 8cda754f..d3698dd2 100644 --- a/plugins/deviceplugins/eq-3/deviceplugineq-3.cpp +++ b/plugins/deviceplugins/eq-3/deviceplugineq-3.cpp @@ -31,151 +31,33 @@ software is recomanded (min/max setpoint temperature, weekly programm...). \chapter Supported devices - \section1 Max! Cube LAN Gateway - In order to use this plugin, you need a \l{http://www.eq-3.de/max-heizungssteuerung-produktdetail/ - items/bc-lgw-o-tw.html}{Max! Cube LAN Gateway}. This device can be discovered and has following propertys: - \section2 Device propertys - \section3 Device parameters - Following list contains all cube params: - \table - \header - \li Name - \li Description - \li Data Type - \row - \li host address - \li Holds the ip address from the cube - \li string - \row - \li serial number - \li Holds the serial number of the cube. This number is written on the cube. - \li string - \row - \li port - \li Holds the port, over which the cube is reachable - \li int - \row - \li firmware version - \li Holds the firmware version of the cube - \li int - \endtable + \section2 Max! Cube LAN Gateway + This \l{http://www.eq-3.de/max-heizungssteuerung-produktdetail/ + items/bc-lgw-o-tw.html}{cube} can be discovered in the network. Every + device, which is connected with the cube, will be appear automatically, once the cube is configrued and + added to guh. - \section3 Device states - Following list contains all cube \l{State}s: - \table - \header - \li Name - \li Description - \li UUID - \li Data Type - \row - \li connected - \li This state holds connection status of the cube. If the cube is connected, this state will be true. - \li d0a9a369-cf8c-47c4-a12e-f2d076bf12fd - \li bool - \row - \li portal enabled - \li This state shows if the web portal of the cube is enabled. You can enable with the original - Max! software an login into the cube over \l{https://max.eq-3.de/login.jsp} - \li 2c2367da-c229-40ed-9d47-a6e73cd6dc3b - \li bool - \endtable - - \section1 Max! Wall Thermostat + \section2 Max! Wall Thermostat In order to use this device, you need a \l{http://www.eq-3.de/max-heizungssteuerung-produktdetail/ items/bc-lgw-o-tw.html}{Max! Cube LAN Gateway}. A \l{http://www.eq-3.de/max-raumloesung-produktdetail/items/bc-tc-c-wm.html}{MAX! Wall Thermostat} can not be added, - it will appear automaticaly in the device list, once you add it to the cube. A \l{http://www.eq-3.de/max-raumloesung-produktdetail/items/bc-tc-c-wm.html}{MAX! Wall Thermostat} - has following propertys: - \section2 Device propertys - \section3 Device parameters - Following list contains all device params: - \table - \header - \li Name - \li Description - \li Data Type - \row - \li name - \li Holds the name of the device, given during the setup in the cube - \li string - \row - \li parent cube - \li Holds the serial number of the cube, where this device is added - \li string - \row - \li rfAddress - \li Holds the RF address of the device. This parameter is not important for the user, - but for the actions. - \li string - \row - \li room number - \li Holds the room number, where the device was added. This number represents the room - from the cube-room management. Is not a guh paramter. - \li int - \row - \li room name - \li Holds the room name, where the device was added. This is the room name, which was given - during the setup on the Cube. - \li string - \endtable + it will appear automatically in the device list, once you add it to the cube. - \section3 Device states - Following list contains all device \l{State}s: - \table - \header - \li Name - \li Description - \li UUID - \li Data Type - \row - \li setpoint temperature [Celsius] - \li Describes the setpoint temperature. The setpoint temperatur represents the whished - temperature, which influences the radiator. This temperature can be controlled also - with the +/- Buttons on the device. - \li 579aa8c6-8814-491b-9e7c-b98108c323d1 - \li double - \row - \li current temperature [Celsius] - \li Describes the current measured temperature in the room. - \li 852e7708-db1d-42d1-96e4-19c13598262c - \li double - \row - \li comfort temperature [Celsius] - \li Describes the configured comfort temperature. When the device goes into comfort mode, - than this will be te setpoint temperature. - \li 850380ee-a787-43e7-adb8-768a21a6e64d - \li double - \row - \li eco temperature [Celsius] - \li Describes the configured eco temperature. When the device goes into eco mode, - than this will be te setpoint temperature. - \li 24dfd20d-bc8d-48e4-8162-b20ae0465c41 - \li double - \row - \li max setpoint temperature [Celsius] - \li Describes the highest configurable temperature. - \li a8536ddf-a6e4-41c2-89c1-e7102608f5f6 - \li double - \row - \li min setpoint temperature [Celsius] - \li Describes the lowest configurable temperature. - \li ceb0ad05-37ad-4b79-a4d9-540c34a7e3e4 - \li double - \endtable + \section2 Max! Radiator Thermostat + In order to use this device, you need a \l{http://www.eq-3.de/max-heizungssteuerung-produktdetail/ + items/bc-lgw-o-tw.html}{Max! Cube LAN Gateway}. A \l{http://www.eq-3.de/max-heizungssteuerung-produktdetail/items/bc-rt-trx-cyg.html}{MAX! Radiator Thermostat} can not be added, + it will appear automatically in the device list, once you add it to the cube. + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. - \section3 Device actions - Following list contains all device \l{Action}s: - \table - \header - \li Name - \li Description - \li UUID - \row - \li - \li With this action you can switch WeMo ON (true) or OFF (false). - \li 269f25eb-d0b7-4144-b9ef-801f4ff3e90c - \endtable + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + + \quotefile plugins/deviceplugins/eq-3/deviceplugineq-3.json */ diff --git a/plugins/deviceplugins/intertechno/devicepluginintertechno.cpp b/plugins/deviceplugins/intertechno/devicepluginintertechno.cpp index 8c0efdde..08175c88 100644 --- a/plugins/deviceplugins/intertechno/devicepluginintertechno.cpp +++ b/plugins/deviceplugins/intertechno/devicepluginintertechno.cpp @@ -23,137 +23,21 @@ \ingroup plugins \ingroup rf433 - This plugin allows to controll RF 433 MHz actors an receive remote signals from Intertechno - devices (\l{http://www.intertechno.at}). + This plugin allows to controll RF 433 MHz actors an receive remote signals from + \l{http://www.intertechno.at}{Intertechno} devices. - Following devices are supported: + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. - \chapter Supported devices - \section1 Actors - \table - \header - \li Model - \li Device Type - \row - \li IT-1500 - \li Socket Switch - \row - \li IT-3500L - \li Socket Switch - \row - \li ITLR-3500 - \li Socket Switch - \row - \li ITLR-3500T - \li Socket Switch - \row - \li IT-2300 - \li Multiple Socket Switch - \row - \li GRR-3500 - \li Outdoor Socket Switch - \row - \li IT-3500 - \li Socket Switch - \row - \li ITR-3500 - \li Socket Switch - \row - \li PA3-1000 - \li Socket Switch - \row - \li IT-300L - \li Socket Dimmer - \row - \li ITLR-300 - \li Socket Dimmer - \row - \li IT-300 - \li Socket Dimmer - \row - \li ITR-300 - \li Socket Dimmer - \row - \li ITL-1000 - \li Switch - \row - \li ITL-230 - \li Switch - \row - \li CMR-1000 - \li Switch - \row - \li ITDL-1000 - \li Switch - \row - \li CMR-1224 - \li Switch - \row - \li ITL-3500 - \li Switch - \row - \li ITE-1000 - \li Switch - \row - \li ITL-300 - \li Dimmer - \row - \li ITL-210 - \li Dimmer - \row - \li ITL-150 - \li Dimmer - \row - \li ITL-250 - \li Dimmer (LED) - \row - \li CMR-300 - \li Dimmer - \row - \li ITE-300 - \li Dimmer - \row - \li CMR-500 - \li Jalousie Switch - \row - \li ITL-500 - \li Jalousie Switch - \row - \li ITL-1000 - \li Jalousie Switch - \row - \li LBUR-100 - \li Lamp Switch - \endtable + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. - \section1 Remotes - \table - \header - \li Model - \li Device Type - \row - \li ITK-200 - \li Mini Remote - \row - \li ITS-150 - \li Remote - \row - \li ITZ-500 - \li Remote/Timer - \row - \li YWT-8500 - \li Wall Sender - \row - \li ITW-852 - \li Wall Sender - \row - \li ITM-100 - \li Magnet Sensor - \row - \li PIR-5000 - \li Moving Sensor - \endtable - */ + \quotefile plugins/deviceplugins/intertechno/devicepluginintertechno.json +*/ #include "devicepluginintertechno.h" diff --git a/plugins/deviceplugins/lgsmarttv/devicepluginlgsmarttv.cpp b/plugins/deviceplugins/lgsmarttv/devicepluginlgsmarttv.cpp index 1f058512..fe591cc9 100644 --- a/plugins/deviceplugins/lgsmarttv/devicepluginlgsmarttv.cpp +++ b/plugins/deviceplugins/lgsmarttv/devicepluginlgsmarttv.cpp @@ -16,6 +16,28 @@ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/*! + \page lgsmarttv.html + \title LG Smart Tv + + \ingroup plugins + \ingroup network + + This plugin allows to interact with \l{http://www.lg.com/us/experience-tvs/smart-tv}{LG Smart Tv's}. + + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. + + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + + \quotefile plugins/deviceplugins/lgsmarttv/devicepluginlgsmarttv.json +*/ + #include "devicepluginlgsmarttv.h" #include "plugin/device.h" diff --git a/plugins/deviceplugins/lircd/devicepluginlircd.cpp b/plugins/deviceplugins/lircd/devicepluginlircd.cpp index 7eee0423..2194fa8e 100644 --- a/plugins/deviceplugins/lircd/devicepluginlircd.cpp +++ b/plugins/deviceplugins/lircd/devicepluginlircd.cpp @@ -16,6 +16,30 @@ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/*! + \page lirc.html + \title LIRC + + \ingroup plugins + \ingroup network + + This plugin allows to interact with \l{http://www.lirc.org/}{LIRC} daemon and controll commonly used remote controls. + If lircd (LIRC daemon) is configured on your system, guh will connect to the lirc daemon and all configured remote + controls of lircd will appear in guh. + + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. + + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + + \quotefile plugins/deviceplugins/lircd/devicepluginlircd.json +*/ + #include "devicepluginlircd.h" #include "plugin/device.h" diff --git a/plugins/deviceplugins/mailnotification/devicepluginmailnotification.cpp b/plugins/deviceplugins/mailnotification/devicepluginmailnotification.cpp index 0a403b5d..6f13c9b1 100644 --- a/plugins/deviceplugins/mailnotification/devicepluginmailnotification.cpp +++ b/plugins/deviceplugins/mailnotification/devicepluginmailnotification.cpp @@ -26,197 +26,35 @@ The mail notification plugin allows you to send a mail notification from a mail account by performing an \l{Action}. - ATTENTION: The password currently will be saved as plain text in the guh configuration file. + ATTENTION: The password currently will be saved as plain text in the guh settings file. + This will be changed soon... - \section1 Google Mail Notification - \section2 Examples - \section3 Adding a Google Mail Notification service - In order to add a Google Mail Notification service you need to configure - the "Google Mail login" (user), the password for your Gmail account and the address - of the recipient. - \code - { - "id":1, - "method":"Devices.AddConfiguredDevice", - "params":{ - "deviceClassId": "{38ed6ffc-f43b-48f8-aea2-8d63cdcad87e}", - "deviceParams":{ - "user":"my.address@gmail.com", - "password":"my_secret_password" - "recipient":"recipient@example.com"} - } - } - } - \endcode - Before the device will be added, the plugin trys to login. If the username or the password - are wrong, an error message will be send. - \code - { - "id": 1, - "params": { - "deviceId": "{0b99ea27-896a-4a23-a044-3f1441f6a9a7}", - "errorMessage": "", - "success": true - }, - "status": "success" - } - \endcode + \chapter Supported services + \section2 Google Mail + With the Google Mail Notification you can send a mail with your gmail address to a recipient. The + username is your mail address (e.g. "chuck.norris@gmail.com"). The recipient will receive the notification + from your gmail account. - \section3 Sending a mail notification - In order to send a mail notification from a configured Gmail service use following message - format. - \code - { - "id":1, - "method":"Actions.ExecuteAction", - "params":{ - "actionTypeId": "{fa54f834-34d0-4aaf-b0ab-a165191d39d3}", - "deviceId":"{0b99ea27-896a-4a23-a044-3f1441f6a9a7}", - "params":{ - "subject":"GUH notification", - "body":"Hello world!" - } - } - } - \endcode - response... - \code - { - "id": 1, - "params": { - "errorMessage": "", - "success": true - }, - "status": "success" - } - \endcode + \section2 Yahoo Mail + The Yahoo Mail Notification you can send a mail with your yahoo address to a recipient. The username + is your mail address (e.g. "chuck.norris@yahoo.com"). The recipient will receive the notification + from your yahoo account. - \section2 Plugin propertys: - \section3 Plugin parameters - Each configured plugin has following paramters: + \section2 Custom Mail + With the Custom Mail Notification you can set up a custom SMTP connection. The supported authentification + methods are ["PLAIN", "LOGIN"], the supported encryption methods are ["NONE", "SSL", "TLS"]. - \table - \header - \li Name - \li Description - \li Data Type - \row - \li user - \li This parameter holds the username (mail address) for the login - \li string - \row - \li password - \li This parameter holds the password for the login - \li string - \row - \li recipient - \li This parameter holds the mail address of the recipient of the notification - \li string - \endtable - - \section3 Plugin actions: - Following list contains all plugin \l{Action}s: - \table - \header - \li Name - \li Description - \li UUID - \row - \li sendMail - \li This action sends a mail to the recipient address of the configured device - with a given subject and text body. - \li fa54f834-34d0-4aaf-b0ab-a165191d39d3 - \endtable - - \section1 Custom Mail Notification - \section2 Examples - \section3 Adding a Custom Mail Notification service - In order to add a Custom Mail Notification service you need to configure - the smtp host address, the login (user), the password, the address - of the recipient, the connection port and the authentification method (PLAIN or LOGIN). - The plugin currently supports only SSL encryption. - \code - { - "id":1, - "method":"Devices.AddConfiguredDevice", - "params":{ - "deviceClassId": "{38ed6ffc-f43b-48f8-aea2-8d63cdcad87e}", - "deviceParams":{ - "user":"my.address@gmail.com", - "password":"my_secret_password" - "recipient":"recipient@example.com"} - "host":"smtp.mydomain.com"} - "port":"465"} - "auth":"PLAIN"} - } - } - } - \endcode - Before the device will be added, the plugin trys to login. If the username or the password - are wrong, an error message will be send. - \code - { - "id": 1, - "params": { - "deviceId": "{0b99ea27-896a-4a23-a044-3f1441f6a9a7}", - "errorMessage": "", - "success": true - }, - "status": "success" - } - \endcode - - \section2 Plugin propertys: - \section3 Plugin parameters - Each configured plugin has following paramters: - - \table - \header - \li Name - \li Description - \li Data Type - \row - \li user - \li This parameter holds the username (mail address) for the login - \li string - \row - \li password - \li This parameter holds the password for the login - \li string - \row - \li recipient - \li This parameter holds the mail address of the recipient of the notification - \li string - \row - \li host - \li This parameter holds the smtp host address from the mail server. - \li string - \row - \li port - \li This parameter holds the smtp port from the mail server. - \li int - \row - \li auth - \li This parameter holds the authentification method from the mail server. - Possible values are: PLAIN, LOGIN - \li string - \endtable - - \section3 Plugin actions: - Following list contains all plugin \l{Action}s: - \table - \header - \li Name - \li Description - \li UUID - \row - \li sendMail - \li This action sends a mail to the recipient address of the configured device - with a given subject and text body. - \li fa54f834-34d0-4aaf-b0ab-a165191d39d3 - \endtable + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + \quotefile plugins/deviceplugins/mailnotification/devicepluginmailnotification.json */ #include "devicepluginmailnotification.h" diff --git a/plugins/deviceplugins/openweathermap/devicepluginopenweathermap.cpp b/plugins/deviceplugins/openweathermap/devicepluginopenweathermap.cpp index 8c320601..599f59dc 100644 --- a/plugins/deviceplugins/openweathermap/devicepluginopenweathermap.cpp +++ b/plugins/deviceplugins/openweathermap/devicepluginopenweathermap.cpp @@ -26,246 +26,23 @@ This plugin alows you to get the current weather data from \l{http://www.openweathermap.org}. The plugin offers two different search methods: if the user searches for a empty string, the plugin makes an autodetction with the WAN ip and offers the user the found autodetectresult. - Otherwise the plugin return the list with the found searchresults. + The autodetection function uses the geolocation of your WAN ip and searches all available weather + stations in a radius of 2.5 km. Otherwise the plugin returns the list of the found search results + from the search string. - \section1 Examples - \section2 Autodetect location - If you want to autodetect your location dend a discovery request with an empty string. - \code - { - "id":1, - "method":"Devices.GetDiscoveredDevices", - "params":{ - "deviceClassId":"985195aa-17ad-4530-88a4-cdd753d747d7", - "discoveryParams": { - "location":"" - } - } - } - \endcode - response from autodetection... - \code - { - "id": 1, - "params": { - "deviceDescriptors": [ - { - "description": "AT", - "id": "{75607672-5354-428f-a752-910140c22b18}", - "title": "Vienna" - } - ], - "errorMessage": "", - "success": true - }, - "status": "success" - } - \endcode - \section2 Searching city - If you want to search a string send following discovery message: - \code - { - "id":1, - "method":"Devices.GetDiscoveredDevices", - "params":{ - "deviceClassId":"985195aa-17ad-4530-88a4-cdd753d747d7", - "discoveryParams": { - "location":"Vie" - } - } - } - \endcode - response... - \code - { - "id": 1, - "params": { - "deviceDescriptors": [ - { - "description": "DE", - "id": "{6dc6be43-5bdc-4dbd-bcbf-6f8e1f90000b}", - "title": "Viersen" - }, - { - "description": "VN", - "id": "{af275298-77f1-40b4-843a-d0f3c7aef6bb}", - "title": "Viet Tri" - }, - { - "description": "DE", - "id": "{86a4ab63-41b4-4348-9830-4bf6c87474bf}", - "title": "Viernheim" - }, - { - "description": "AR", - "id": "{3b5f8eea-6159-4375-bd01-1f07de9c3a9d}", - "title": "Viedma" - }, - { - "description": "FR", - "id": "{f3b91f26-3275-4bb4-a594-924202a2124e}", - "title": "Vierzon" - }, - { - "description": "AT", - "id": "{b59d15f7-f52b-43a0-a9c5-a3fa80cbc2bd}", - "title": "Vienna" - } - ], - "errorMessage": "", - "success": true - }, - "status": "success" - } - \endcode - \section2 Adding a discovered city - If you want to add a dicovered city send the add "AddConfiguredDevice" message - with the deviceDescriptorId from the searchresult list. In this example the id for Vienna. - \code - { - "id":1, - "method":"Devices.AddConfiguredDevice", - "params":{ - "deviceClassId":"985195aa-17ad-4530-88a4-cdd753d747d7", - "deviceDescriptorId": "b59d15f7-f52b-43a0-a9c5-a3fa80cbc2bd" - } - } - \endcode - response... - \code - { - "id": 1, - "params": { - "deviceId": "{af0f1958-b901-48da-ad97-d4d64af88cf8}", - "errorMessage": "", - "success": true - }, - "status": "success" - } - \endcode + \underline{NOTE}: If you are using a VPN connection, the autodetection will show the results around of your VPN location. - \section1 Plugin propertys: - \section2 Plugin parameters - Each configured plugin has following paramters: + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. - \table - \header - \li Name - \li Description - \li Data Type - \row - \li location - \li This parameter holds the name of the city - \li string - \row - \li country - \li This parameter holds the country of the city - \li string - \row - \li id - \li This parameter holds the city id from \l{http://www.openweathermap.org} - \li string - \endtable - - \section2 Actions - Following list contains all plugin \l{Action}s: - \table - \header - \li Name - \li Description - \li UUID - \row - \li refresh - \li This action refreshes all states. - \li cfbc6504-d86f-4856-8dfa-97b6fbb385e4 - \endtable - - \section2 States - Following list contains all plugin \l{State}s: - \table - \header - \li Name - \li Description - \li UUID - \li Data Type - \row - \li city name - \li The name of the city - \li fd9e7b7f-cf1f-4093-8f6d-fff5b223471f - \li string - \row - \li city id - \li The city ID for openweathermap.org - \li c6ef1c07-e817-4251-b83d-115bbf6f0ae9 - \li string - \row - \li country name - \li The country name - \li 0e607a5f-1938-4e77-a146-15e9ad15bfad - \li string - \row - \li last update - \li The timestamp of the weather data from the weatherstation in unixtime - format - \li 98e48095-87da-47a4-b812-28c6c17a3e76 - \li unsignend int - \row - \li temperature - \li Current temperature [Celsius] - \li 2f949fa3-ff21-4721-87ec-0a5c9d0a5b8a - \li double - \row - \li temperature minimum - \li Today temperature minimum [Clesius] - \li 701338b3-80de-4c95-8abf-26f44529d620 - \li double - \row - \li temperature maximum - \li Today temperature maximum [Clesius] - \li f69bedd2-c997-4a7d-9242-76bf2aab3d3d - \li double - \row - \li humidity - \li Current relative humidity [%] - \li 3f01c9f0-206b-4477-afa2-80d6e5e54fbb - \li int - \row - \li pressure - \li Current pressure [hPa] - \li 6a57b6e9-7010-4a89-982c-ce0bc2a71f11 - \li double - \row - \li wind speed - \li Current wind speed [m/s] - \li 12dc85a9-825d-4375-bef4-abd66e9e301b - \li double - \row - \li wind direction - \li The wind direction rellative to the north pole [degree] - \li a8b0383c-d615-41fe-82b8-9b797f045cc9 - \li int - \row - \li cloudiness - \li This value represents how much of the sky is clowdy [%] - \li 0c1dc881-560e-40ac-a4a1-9ab69138cfe3 - \li int - \row - \li weather description - \li This string describes the current weather condition in clear words - \li e71d98e3-ebd8-4abf-ad25-9ecc2d05276a - \li string - \row - \li sunset - \li The time of todays sunset in unixtime format - \li 5dd6f5a3-25d6-4e60-82ca-e934ad76a4b6 - \li unsigned int - \row - \li sunrise - \li The time of todays sunrise in unixtime format - \li 413b3fc6-bd1c-46fb-8c86-03096254f94f - \li unsigned int - \endtable + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + \quotefile plugins/deviceplugins/openweathermap/devicepluginopenweathermap.json */ diff --git a/plugins/deviceplugins/philipshue/devicepluginphilipshue.cpp b/plugins/deviceplugins/philipshue/devicepluginphilipshue.cpp index f9bcbee4..7648f3ca 100644 --- a/plugins/deviceplugins/philipshue/devicepluginphilipshue.cpp +++ b/plugins/deviceplugins/philipshue/devicepluginphilipshue.cpp @@ -16,6 +16,29 @@ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/*! + \page philipshue.html + \title Philips hue + + \ingroup plugins + \ingroup network + + This plugin allows to interact with the \l{http://www2.meethue.com/}{Philips hue} bridge. Each light bulp connected to the bridge + will appear automatically in the system, once the bridge is added to guh. + + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. + + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + + \quotefile plugins/deviceplugins/philipshue/devicepluginphilipshue.json +*/ + #include "devicepluginphilipshue.h" #include "plugin/device.h" diff --git a/plugins/deviceplugins/wakeonlan/devicepluginwakeonlan.cpp b/plugins/deviceplugins/wakeonlan/devicepluginwakeonlan.cpp index 3e862932..adba9e35 100644 --- a/plugins/deviceplugins/wakeonlan/devicepluginwakeonlan.cpp +++ b/plugins/deviceplugins/wakeonlan/devicepluginwakeonlan.cpp @@ -20,97 +20,25 @@ \title Wake On Lan \ingroup plugins - \ingroup services + \ingroup network Wake-on-LAN (WOL) is an Ethernet computer networking standard that allows a computer to be turned on or awakened by a network message. This plugin allows you to send a - a "magic packet" to a certain mac address in the local network. The WOL service must - be enabled on the host computer. + a "magic packet" to a certain mac address in the local network. - \section1 Examples - \section2 Adding a WOL device - In order to add a WOL device you need to know the mac address of the host computer you - want to wake up. - \code - { - "id":1, - "method":"Devices.AddConfiguredDevice", - "params":{ - "deviceClassId": "{3c8f2447-dcd0-4882-8c09-99e579e4d24c}", - "deviceParams":{ - "mac":"00:11:22:33:44:55", - "name":"Wohnzimmer-PC" - } - } - } - \endcode - response... - \code - { - "id": 1, - "params": { - "deviceId": "{76347a44-2091-428c-b320-5a8db4c359f6}", - "errorMessage": "", - "success": true - }, - "status": "success" - } - \endcode + \underline{NOTE}: The WOL service has to be enabled on the host computer. - \section2 Wake up a device - In order to wake up a configured device send following message: - \code - { - "id":1, - "method":"Actions.ExecuteAction", - "params":{ - "actionTypeId": "{fb9b9d87-218f-4f0d-9e16-39f8a105029a}", - "deviceId":"{76347a44-2091-428c-b320-5a8db4c359f6}" - } - } - \endcode - response... - \code - { - "id": 1, - "params": { - "errorMessage": "", - "success": true - }, - "status": "success" - } - \endcode - \section1 Plugin propertys: - \section2 Plugin parameters - Each configured plugin has following paramters: + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. - \table - \header - \li Name - \li Description - \li Data Type - \row - \li name - \li This parameter holds the name/description of the target computer - \li string - \row - \li mac - \li This parameter holds the mac address of the target computer - \li string - \endtable - \section2 Plugin actions: - Following list contains all plugin \l{Action}s: - \table - \header - \li Name - \li Description - \li UUID - \row - \li wakeup - \li This action send the "magic package" to the mac address configured in the device parameter. - \li fb9b9d87-218f-4f0d-9e16-39f8a105029a - \endtable + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + \quotefile plugins/deviceplugins/wakeonlan/devicepluginwakeonlan.json */ diff --git a/plugins/deviceplugins/wemo/devicepluginwemo.cpp b/plugins/deviceplugins/wemo/devicepluginwemo.cpp index 8597c76d..a03dcd00 100644 --- a/plugins/deviceplugins/wemo/devicepluginwemo.cpp +++ b/plugins/deviceplugins/wemo/devicepluginwemo.cpp @@ -27,102 +27,17 @@ \l{http://www.belkin.com/de/PRODUKTE/home-automation/c/wemo-home-automation/}{Belkin} home automation system. + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. - \chapter Supported devices - \section1 WeMo Switch - Currently, there is just the \l{http://www.belkin.com/de/F7C027-Belkin/p/P-F7C027/} - {WeMo Switch} supportet. For the first setup, the original app from WeMo (only availabel for - iOS and Android Smartphones) will be needed. Once the WeMo switch is in the private network, - the device can be discovered and controlled from guh. - - \e{\underline{Note:} when the WeMo Switch will not be reachabel, remove the device from guh and re-discover/re-add - it, because the port of the device can change (between 49152-49155 so fare...).} - - \section2 Device propertys - \section3 Device parameters - Following list contains all device Params: - \table - \header - \li Name - \li Description - \li Data Type - \row - \li name - \li Holds the name of the device - \li string - \row - \li uuid - \li Holds the uuid of the device (set from the manufacturer) - \li string - \row - \li model - \li Describes the model - \li string - \row - \li host address - \li Holds the ip address from the device - \li string - \row - \li port - \li Holds the port, over which the switch is reachable - \li int - \row - \li model description - \li Holds the description of the model (given from the manufacturer) - \li string - \row - \li serial number - \li Holds the serial number of the WeMo Switch - \li string - \row - \li location - \li Holds the url of the device information page (XML) - \li string - \row - \li manufacturer - \li Holds the name of the manufacturer (Belkin International Inc.) - \li string - \row - \li device type - \li Holds the type of the device (urn:Belkin:device:controllee:1) - \li string - \endtable - - \section3 Device states - Following list contains all device \l{State}s: - \table - \header - \li Name - \li Description - \li UUID - \li Data Type - \row - \li power - \li Thes state holds the power sate of the switch. If the WeMo Switch power state will be changed - outside of guh (with the button or with the WeMo app), guh will recognize that here. - \li 269f25eb-d0b7-4144-b9ef-801f4ff3e90c - \li bool - \row - \li reachable - \li Thes state gives the information, if the WeMo switch is currently reachable or not. If he's not - reachabel, it can't be controlled. - \li ec2f5b49-585c-4455-a233-b7aa4c608dbc - \li bool - \endtable - - \section3 Device actions - Following list contains all device \l{Action}s: - \table - \header - \li Name - \li Description - \li UUID - \row - \li Set power - \li With this action you can switch WeMo ON (true) or OFF (false). - \li 269f25eb-d0b7-4144-b9ef-801f4ff3e90c - \endtable + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + \quotefile plugins/deviceplugins/wemo/devicepluginwemo.json */ #include "devicepluginwemo.h" diff --git a/plugins/deviceplugins/wifidetector/devicepluginwifidetector.cpp b/plugins/deviceplugins/wifidetector/devicepluginwifidetector.cpp index 532739fe..38379e07 100644 --- a/plugins/deviceplugins/wifidetector/devicepluginwifidetector.cpp +++ b/plugins/deviceplugins/wifidetector/devicepluginwifidetector.cpp @@ -16,6 +16,31 @@ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/*! + \page wifidetector.html + \title WiFi Detector + + \ingroup plugins + \ingroup network + + This plugin allows to find and monitor network devices in your local network by using the MAC address. + + \underline{NOTE}: the application \c nmap has to be installed. + + \chapter Plugin properties + Following JSON file contains the definition and the description of all available \l{DeviceClass}{DeviceClasses} + and \l{Vendor}{Vendors} of this \l{DevicePlugin}. + + Each \l{DeviceClass} has a list of \l{ParamType}{paramTypes}, \l{ActionType}{actionTypes}, \l{StateType}{stateTypes} + and \l{EventType}{eventTypes}. The \l{DeviceClass::CreateMethod}{createMethods} parameter describes how the \l{Device} + will be created in the system. A device can have more than one \l{DeviceClass::CreateMethod}{CreateMethod}. + The \l{DeviceClass::SetupMethod}{setupMethod} describes the setup method of the \l{Device}. + The detailed implementation of each \l{DeviceClass} can be found in the source code. + + \quotefile plugins/deviceplugins/wifidetector/devicepluginwifidetector.json +*/ + + #include "devicepluginwifidetector.h" #include "plugin/device.h"