diff --git a/CODEOWNERS b/CODEOWNERS index bc976170a2733..c19b8b4d24cf4 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -109,6 +109,7 @@ /bundles/org.openhab.binding.max/ @marcelrv /bundles/org.openhab.binding.mcp23017/ @aogorek /bundles/org.openhab.binding.melcloud/ @lucacalcaterra @paulianttila @thewiep +/bundles/org.openhab.binding.meteoalerte/ @clinique /bundles/org.openhab.binding.meteoblue/ @9037568 /bundles/org.openhab.binding.meteostick/ @cdjackson /bundles/org.openhab.binding.miele/ @kgoderis diff --git a/bom/openhab-addons/pom.xml b/bom/openhab-addons/pom.xml index b120947b42edf..df3a28ecb3107 100644 --- a/bom/openhab-addons/pom.xml +++ b/bom/openhab-addons/pom.xml @@ -541,6 +541,11 @@ org.openhab.binding.melcloud ${project.version} + + org.openhab.addons.bundles + org.openhab.binding.meteoalerte + ${project.version} + org.openhab.addons.bundles org.openhab.binding.meteoblue diff --git a/bundles/org.openhab.binding.meteoalerte/.classpath b/bundles/org.openhab.binding.meteoalerte/.classpath new file mode 100644 index 0000000000000..a5d95095ccaaf --- /dev/null +++ b/bundles/org.openhab.binding.meteoalerte/.classpath @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/bundles/org.openhab.binding.meteoalerte/.project b/bundles/org.openhab.binding.meteoalerte/.project new file mode 100644 index 0000000000000..fecdf933509dc --- /dev/null +++ b/bundles/org.openhab.binding.meteoalerte/.project @@ -0,0 +1,23 @@ + + + org.openhab.binding.meteoalerte + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.m2e.core.maven2Builder + + + + + + org.eclipse.jdt.core.javanature + org.eclipse.m2e.core.maven2Nature + + diff --git a/bundles/org.openhab.binding.meteoalerte/NOTICE b/bundles/org.openhab.binding.meteoalerte/NOTICE new file mode 100644 index 0000000000000..38d625e349232 --- /dev/null +++ b/bundles/org.openhab.binding.meteoalerte/NOTICE @@ -0,0 +1,13 @@ +This content is produced and maintained by the openHAB project. + +* Project home: https://www.openhab.org + +== Declared Project Licenses + +This program and the accompanying materials are made available under the terms +of the Eclipse Public License 2.0 which is available at +https://www.eclipse.org/legal/epl-2.0/. + +== Source Code + +https://github.com/openhab/openhab-addons diff --git a/bundles/org.openhab.binding.meteoalerte/README.md b/bundles/org.openhab.binding.meteoalerte/README.md new file mode 100644 index 0000000000000..7d127ac9ff45b --- /dev/null +++ b/bundles/org.openhab.binding.meteoalerte/README.md @@ -0,0 +1,92 @@ +# Meteo Alerte Binding + +The Meteo Alerte binding gives alert level regarding major weather related risk factors. + +## Supported Things + +There is exactly one supported thing type, which represents the weather alerts for a given department. +It has the `department` id. +Of course, you can add multiple things, e.g. for getting alerts for different locations. + +## Binding Configuration + +The binding has no configuration options, all configuration is done at Thing level. + +## Thing Configuration + +The thing has a few configuration parameters: + +| Parameter | Description | +|---------------|----------------------------------------------------------------------------------------| +| `department` | Name of the department. | +| refresh | Refresh interval in minutes. Optional, the default value is 1440 minutes (once a day). | + +## Channels + +The Météo Alerte information that are retrieved is available as these channels: + +| Channel ID | Item Type | Description | +|-----------------------|-----------|-----------------------------------------------| +| observation-time | DateTime | Date and time of alert creation | +| comment | String | General comments on alerts for the department | +| vent | String | Wind alert level (*) | +| pluie-inondation | String | Rain alert level (*) | +| orage | String | Storm alert level (*) | +| inondation | String | Flood alert level (*) | +| neige | String | Snow alert level (*) | +| canicule | String | Heat alert level (*) | +| grand-froid | String | Cold alert level (*) | +| avalanches | String | Avalanche alert level (*) | +| pluie-inondation-icon | Image | Pictogram of the Rain alert level | +| vent-icon | Image | Pictogram of the Wind alert level | +| orage-icon | Image | Pictogram of Storm alert level | +| inondation-icon | Image | Pictogram of Flood alert level | +| neige-icon | Image | Pictogram of Snow alert level | +| canicule-icon | Image | Pictogram of Heat alert level | +| grand-froid-icon | Image | Pictogram of Cold alert level | +| avalanches-icon | Image | Pictogram of Avalanche alert level | + +(*) Each alert level is described by a color : + +| Code | Color | Description | +|------|--------|-------------------------------------------| +| 0 | Green | No particular vigilance | +| 1 | Yellow | Be attentive to the weather situation | +| 2 | Orange | Be "very vigilant" in the concerned areas | +| 3 | Red | Absolute vigilance required | + + +## Full Example + +meteoalert.things: + +``` +Thing meteoalerte:department:yvelines @ "MyCity" [department="YVELINES", refresh=12] +``` + +meteoalert.items: + +``` +Group gMeteoAlert "Alertes Météo" + String MA_Dept78 "Département 78 [%s]" (gMeteoAlert) {channel="meteoalerte:department:yvelines:comment"} + String MA_etat_canicule "Canicule [%s]" (gMeteoAlert) {channel="meteoalerte:department:yvelines:canicule"} + String MA_etat_grand_froid "Grand Froid [%s]" (gMeteoAlert) {channel="meteoalerte:department:yvelines:grand-froid"} + String MA_etat_pluie_inondation "Pluie-Inondation [%s]" (gMeteoAlert) {channel="meteoalerte:department:yvelines:pluie-inondation"} + String MA_etat_neige "Neige [%s]" (gMeteoAlert) {channel="meteoalerte:department:yvelines:neige"} + String MA_etat_vent "Vent [%s]" (gMeteoAlert) {channel="meteoalerte:department:yvelines:vent"} + String MA_etat_inondation "Inondation [%s]" (gMeteoAlert) {channel="meteoalerte:department:yvelines:inondation"} + String MA_etat_orage "Orage [%s]" (gMeteoAlert) {channel="meteoalerte:department:yvelines:orage"} + String MA_etat_avalanche "Avalanches [%s]" (gMeteoAlert) {channel="meteoalerte:department:yvelines:avalanches"} + + Image MA_icon_canicule "Canicule" (gMeteoAlert) {channel="meteoalerte:department:yvelines:canicule-icon"} + Image MA_icon_grand_froid "Grand Froid" (gMeteoAlert) {channel="meteoalerte:department:yvelines:grand-froid-icon"} + Image MA_icon_pluie_inondation "Pluie-Inondation" (gMeteoAlert) {channel="meteoalerte:department:yvelines:pluie-inondation-icon"} + Image MA_icon_neige "Neige" (gMeteoAlert) {channel="meteoalerte:department:yvelines:neige-icon"} + Image MA_icon_vent "Vent" (gMeteoAlert) {channel="meteoalerte:department:yvelines:vent-icon"} + Image MA_icon_inondation "Inondation" (gMeteoAlert) {channel="meteoalerte:department:yvelines:inondation-icon"} + Image MA_icon_orage "Orage" (gMeteoAlert) {channel="meteoalerte:department:yvelines:orage-icon"} + Image MA_icon_avalanche "Avalanche" (gMeteoAlert) {channel="meteoalerte:department:yvelines:avalanches-icon"} + + DateTime MA_ObservationTS "Timestamp [%1$tH:%1$tM]"