]> _ Git - tortuga-home.git/commitdiff
.
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Wed, 4 Jun 2025 15:40:45 +0000 (17:40 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Wed, 4 Jun 2025 15:40:45 +0000 (17:40 +0200)
.idea/workspace.xml
images/cocodrilo.svg [new file with mode: 0644]
scripts/lib/homeassistant.php
scripts/lib/weatherstation.php

index 67ea1134e21dd6b81f9d455d568544c9c6b71d5b..b36e2be5ede2a98e2d6ef92aaf75b21d984e1958 100644 (file)
@@ -5,12 +5,9 @@
   </component>
   <component name="ChangeListManager">
     <list default="true" id="352ce63a-b52a-41a2-979b-becda7920939" name="Default" comment=".">
-      <change afterPath="$PROJECT_DIR$/scripts/xplanet.php" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/.docker/dockerterminal.bat" beforeDir="false" afterPath="$PROJECT_DIR$/.docker/dockerterminal.bat" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/.docker/update" beforeDir="false" afterPath="$PROJECT_DIR$/.docker/update" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/scripts/cron/cron.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/cron/cron.php" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/scripts/lib/heartbeats.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/lib/heartbeats.php" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/scripts/lib/homeassistant.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/lib/homeassistant.php" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/scripts/lib/weatherstation.php" beforeDir="false" afterPath="$PROJECT_DIR$/scripts/lib/weatherstation.php" afterDir="false" />
     </list>
     <option name="SHOW_DIALOG" value="false" />
     <option name="HIGHLIGHT_CONFLICTS" value="true" />
     "RunOnceActivity.ShowReadmeOnStart": "true",
     "RunOnceActivity.TerminalTabsStorage.copyFrom.TerminalArrangementManager": "true",
     "RunOnceActivity.git.unshallow": "true",
+    "SHELLCHECK.PATH": "C:\\Users\\vince\\AppData\\Roaming\\JetBrains\\IntelliJIdea2025.1\\plugins\\Shell Script\\shellcheck.exe",
     "Shell Script.Docker terminal.executor": "Run",
     "Shell Script.Update DNS.executor": "Run",
     "WebServerToolWindowFactoryState": "true",
     "ignore.virus.scanning.warn.message": "true",
     "junie.onboarding.icon.badge.shown": "true",
     "kotlin-language-version-configured": "true",
-    "last_opened_file_path": "D:/Works/tortuga-home",
+    "last_opened_file_path": "D:/Works/tortuga-home/images",
     "node.js.detected.package.eslint": "true",
     "node.js.detected.package.tslint": "true",
     "node.js.selected.package.eslint": "(autodetect)",
 }]]></component>
   <component name="RecentsManager">
     <key name="CopyFile.RECENT_KEYS">
+      <recent name="D:\Works\tortuga-home\images" />
       <recent name="D:\Works\tortuga-home\scripts" />
       <recent name="T:\Drive\Works\home" />
       <recent name="T:\Drive\Works\home\config" />
       <recent name="T:\Drive\Works\home\images\rooms\small" />
-      <recent name="T:\Drive\Works\home\images\rooms\medium" />
     </key>
     <key name="MoveFile.RECENT_KEYS">
       <recent name="D:\Works\tortuga-home\lib" />
       <workItem from="1743155457881" duration="635000" />
       <workItem from="1747769206421" duration="5548000" />
       <workItem from="1748247197909" duration="4084000" />
-      <workItem from="1749022280289" duration="2180000" />
+      <workItem from="1749022280289" duration="3013000" />
+      <workItem from="1749025974811" duration="112000" />
+      <workItem from="1749027906070" duration="11028000" />
     </task>
     <task id="LOCAL-00502" summary=".">
       <created>1641726946298</created>
       <option name="project" value="LOCAL" />
       <updated>1687259667913</updated>
     </task>
-    <option name="localTasksCounter" value="627" />
+    <option name="localTasksCounter" value="628" />
     <servers />
   </component>
   <component name="TypeScriptGeneratedFilesManager">
diff --git a/images/cocodrilo.svg b/images/cocodrilo.svg
new file mode 100644 (file)
index 0000000..0f065fb
--- /dev/null
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg id="Calque_1" xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 18 18">
+  <defs>
+    <style>
+      .st0 {
+        fill:currentColor;
+      }
+    </style>
+  </defs>
+  <path class="st0" d="M10.7,5.1c-.3,0-.6.2-.8.4,0,0-.2.2-.3.3h0c0,.1-.4.1-.4.1h-.4l-.3-.2c-.5-.4-.7-.4-.7-.4,0,0,0,.2-.1.4,0,.2-.1.3-.1.3,0,0,0,0-.2,0h-.2s-.3-.2-.3-.2c-.3-.3-.6-.5-.6-.5s0,0-.2.4c0,.2-.1.4-.2.4,0,0,0,0-.2,0h-.2s0,0,0,0c-.6-.5-.9-.7-1-.6,0,0-.2.4-.3.8h0c0,.1-.3.2-.3.2-1.4.3-2.4,1.1-2.8,2.1-.1.3-.2.5-.2,1s0,.5,0,.7c.2,1.1.9,1.9,1.9,2.4,1,.5,2.2.7,4.2.7,1.1,0,1.7,0,3.7-.2,1.4-.1,1.8-.1,2.4-.1s1,0,1.4.1c.3,0,.3,0,.4-.1,0,0,0-.2-.2-.4-.4-.4-1.2-.8-2-.9-.6,0-1.3-.1-3.9-.2-2.2,0-2.7,0-3.1-.1-.8-.1-1.3-.5-1.6-.9-.2-.4-.2-.6.1-.9s.2-.1.2-.1c0,0,.1.1.2.3.2.8.3,1,.6,1.1.1,0,.2,0,1.1,0h.9,0c0-.3-.2-.5-.4-.7,0,0-.2,0-.3-.1h-.2s0-.2,0-.2c0,0,0-.1,0-.2h0c0,0,1.1,0,1.1,0h1.1s0,.1,0,.1c0,0,.1.3.2.4.2.5.3.6.6.6.1,0,.7,0,1.2,0h1s0,0,0,0c0-.1-.1-.3-.2-.4-.1-.1-.4-.3-.6-.3-.2,0-.3,0-.4-.3,0-.2,0-.3,0-.3,0,0,1,0,2.8,0s2.8,0,2.9,0c.2,0,.4-.2.5-.5.1-.2,0-.4-.2-.4-.2,0-.2,0-.3-.2,0-.2-.2-.4-.2-.4,0,0,0,.1-.2.3,0,.1-.2.2-.2.2,0,0-.1,0-.3,0h-.3s-.1-.2-.1-.2c0-.1-.1-.2-.1-.3h0c0,0,0,0,0,0,0,0-.1.1-.2.2,0,.1-.1.1-.2.1-.8-.1-1.7-.4-2.2-.5h-.2c0,0,.1-.2.1-.2.3-.3.8-.4,1.6-.4h.2s.1.2.1.2c0,.1.1.3.2.3,0,0,.1,0,.2-.3v-.2h.3c0,0,.2,0,.3,0h.2s.1.2.1.2c.1.2.2.3.2.3,0,0,0-.1.2-.3v-.3c.1,0,.4,0,.4,0,.3,0,.3,0,.4.2,0,0,.1.2.1.2,0,0,0,0,0,0,0,0,0-.2.1-.3,0-.2,0-.3.2-.3.2-.2.3-.6.3-.9,0-.2-.1-.3-.2-.5-.4-.4-1.1-.3-1.4.2h0c0,0-1.4,0-1.4,0h-1.5c-.1-.3-.3-.5-.5-.6-.3-.2-.8-.3-1.2-.3ZM11.2,5.9c.2,0,.3.3.2.5,0,.2-.2.3-.4.3s-.3,0-.4-.3c-.1-.3,0-.6.4-.6,0,0,.1,0,.2,0Z"/>
+</svg>
\ No newline at end of file
index 83c79c869c2ac49e8a49452c785f3920075557e6..16ac75941874b8554195113531ed7fa983d26eef 100644 (file)
 const HA_KEY = 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJiMjJlOWU2YzQ5ZTM0OTk5YTc3YTFjYzE3MDdiNTViNyIsImlhdCI6MTY4ODMxNTk0NywiZXhwIjoyMDAzNjc1OTQ3fQ.HS-KUXxaFE2esRydhqTfzCS7sc7eaZPVv0BE6NNGWas';
 const HA_URL = 'http://192.168.13.8:8123/';
 
+const HA_COCODRILO_KEY = 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiI0NjNhOWVhNzIyYzY0ZGRlODhkODY3ZDdhZDc2N2NmOSIsImlhdCI6MTc0OTA0MDkxNCwiZXhwIjoyMDY0NDAwOTE0fQ.0cwLyGhpd0XK4NaO2cK0686SNRor7jAQqdEDb9vos6Q';
+const HA_COCODRILO_URL = 'http://cocodrilo.enhydra.fr:18832/';
+
 const HA_WC_VMC = 'switch.0x847127fffe280f20';
 const HA_SDB_AMPLI = 'switch.0xa4c138168147c1b6';
 const HA_ECO_BASIC = 'switch.ecomode_basic';
 const HA_ECO_SUPER = 'switch.ecomode_super';
 const HA_HOTTE = 'switch.hotte';
 const HA_BAR = 'switch.bar';
-const HA_GROW_LAMPS='switch.0x00124b0025e24358';
+const HA_GROW_LAMPS = 'switch.0x00124b0025e24358';
 const HA_PLANETARIUM = 'switch.0xa4c138788071821e';
 
-const HA_OFFICE_CURTAIN='input_boolean.rideaux_bureau';
-const HA_OFFICE_SCREEN='cover.office_screen';
+const HA_OFFICE_CURTAIN = 'input_boolean.rideaux_bureau';
+const HA_OFFICE_SCREEN = 'cover.office_screen';
 
 const HA_OFFICE_MAIN_SCREEN = 'switch.0xa4c138787633f01d';
 const HA_OFFICE_PLANE_SCREENS = 'switch.0xa4c138ba535d2cc5';
 
-const HA_COFFEE='switch.machine_a_cafe_power';
+const HA_COFFEE = 'switch.machine_a_cafe_power';
+
+const HA_SALON_PROJ_SENSOR = 'binary_sensor.0x00158d00094363cc_contact';
 
-const HA_SALON_PROJ_SENSOR='binary_sensor.0x00158d00094363cc_contact';
+function haGetState($id, $attribute = null, $instance = 'tortuga')
+{ //ID to read - for example sensor.foo
 
-function haGetState($id, $attribute = null) { //ID to read - for example sensor.foo
+    if ($instance === 'tortuga') {
+        $url = HA_URL;
+        $key = HA_KEY;
+    } else {
+        $url = HA_COCODRILO_URL;
+        $key = HA_COCODRILO_KEY;
+    }
 
 
-       $opts = [
-               "http" => [
-                       "method" => "GET",
-                       "header" =>
-                               "Content-Type: application/json\r\n" .
-                               "Authorization: Bearer " . HA_KEY . "\r\n"
-               ]
-       ];
+    $opts = [
+        "http" => [
+            "method" => "GET",
+            "header" =>
+                "Content-Type: application/json\r\n" .
+                "Authorization: Bearer " . $key . "\r\n"
+        ]
+    ];
 
-       $ids = !is_array($id) ? explode(',', $id) : $id;
-       $d = [];
+    $ids = !is_array($id) ? explode(',', $id) : $id;
+    $d = [];
 
-       foreach ($ids as $id) {
-               $ctx = stream_context_create($opts);
-               $data = @file_get_contents(HA_URL . 'api/states/' . $id, false, $ctx);
-               if (!$data) {
-                       continue;
-               }
-               $d[$id] = json_decode($data);
-       }
+    foreach ($ids as $id) {
+        $ctx = stream_context_create($opts);
+        $data = @file_get_contents($url . 'api/states/' . $id, false, $ctx);
+        if (!$data) {
+            continue;
+        }
+        $d[$id] = json_decode($data);
+    }
 
-       usort($d, function ($a, $b) {
-               return strcmp($a->last_updated, $b->last_updated) * -1;
-       });
+    usort($d, function ($a, $b) {
+        return strcmp($a->last_updated, $b->last_updated) * -1;
+    });
 
 
-       $data = array_shift($d);
+    $data = array_shift($d);
 
-       if (null === $attribute) {
-               if (!$data)
-                       return false;
-               if (!isset($data->state))
-                       return false;
-               return $data->state;
-       }
-       return ($data->attributes->$attribute) ?? false;
+    if (null === $attribute) {
+        if (!$data)
+            return false;
+        if (!isset($data->state))
+            return false;
+        return $data->state;
+    }
+    return ($data->attributes->$attribute) ?? false;
 
 }
 
 
-function haAction($id, $action = null, $domain = null, $data = []) {
-       if (null === $action) {
-               $action = 'turn_on';
-       }
-       $data['entity_id'] = $id;
-       $opts = [
-               "http" => [
-                       "method" => "POST",
-                       'content' => json_encode($data),
-                       "header" =>
-                               "Content-Type: application/json\r\n" .
-                               "Authorization: Bearer " . HA_KEY . "\r\n"
-               ]
-       ];
-
-       if (null === $domain) {
-               $e = explode('.', $id);
-               $domain = $e[0];
-       }
-
-       $ctx = stream_context_create($opts);
-       $data = file_get_contents(HA_URL . 'api/services/' . $domain . '/' . $action, false, $ctx);
-       if (!$data)
-               return false;
-       $data = json_decode($data);
-       if (!$data)
-               return false;
-       if (!isset($data->state))
-               return false;
-       return [$data->state, $data->last_updated];
+function haAction($id, $action = null, $domain = null, $data = [], $instance = 'tortuga')
+{
+    if ($instance === 'tortuga') {
+        $url = HA_URL;
+        $key = HA_KEY;
+    } else {
+        $url = HA_COCODRILO_URL;
+        $key = HA_COCODRILO_KEY;
+    }
+
+    if (null === $action) {
+        $action = 'turn_on';
+    }
+    $data['entity_id'] = $id;
+    $opts = [
+        "http" => [
+            "method" => "POST",
+            'content' => json_encode($data),
+            "header" =>
+                "Content-Type: application/json\r\n" .
+                "Authorization: Bearer " . $key . "\r\n"
+        ]
+    ];
+
+    if (null === $domain) {
+        $e = explode('.', $id);
+        $domain = $e[0];
+    }
+
+    $ctx = stream_context_create($opts);
+    $data = file_get_contents($url . 'api/services/' . $domain . '/' . $action, false, $ctx);
+    if (!$data)
+        return false;
+    $data = json_decode($data);
+    if (!$data)
+        return false;
+    if (!isset($data->state))
+        return false;
+    return [$data->state, $data->last_updated];
 }
index 40adcea75436830d9c085e3e94b8770cc452f713..c4d9a7bd1f7e1a3d77dd50e3debaca1d3c747f35 100644 (file)
@@ -16,25 +16,26 @@ function getWeather()
     $weather = json_decode(file_get_contents($cache), true);
     $weather = $weather[0];
     $res['temp'] = round(($weather['Temperature']['Metric']['Value']/* + getState('airtemperature')*/));
-    $res['outdoor_temp'] = toNumber(haGetState(['sensor.indoor_outdoor_meter_ddf7_temperature', 'sensor.w340001x_tempc']), 1);
-    $res['outdoor_humidity'] = toNumber(haGetState(['sensor.indoor_outdoor_meter_ddf7_humidity', 'sensor.w340001x_hum']), true);
-    $res['outdoor_pressure'] = toNumber(haGetState('sensor.0x00158d000464c885_pressure'), true);
-    $res['backyard_temp'] = toNumber(haGetState('sensor.indoor_outdoor_meter_1719'), 1);
-    $res['backyard_humidity'] = toNumber(haGetState('sensor.indoor_outdoor_meter_1719_humidite'), true);
-    $res['backyard_pressure'] = toNumber(haGetState('sensor.0x00158d0004658cc2_pressure'), true);
-    $res['bathroom_temp'] = toNumber(haGetState('sensor.0x00158d0004658cc2_temperature'), 1);
-    $res['bathroom_humidity'] = toNumber(haGetState('sensor.0x00158d0004658cc2_humidity'), true);
-    $res['bedroom_temp'] = toNumber(haGetState('sensor.0x54ef4410003596e5_temperature'), 1);
-    $res['bedroom_humidity'] = toNumber(haGetState('sensor.0x54ef4410003596e5_humidity'), true);
-    $res['bedroom_airquality'] = toNumber(haGetState('sensor.0x54ef4410003596e5_voc'), true);
-    $res['livingroom_temp'] = toNumber(haGetState('sensor.temperature_salon_temperature'), 1);
-    $res['livingroom_humidity'] = toNumber(haGetState('sensor.temperature_salon_humidity'), true);
-    $res['kitchen_temp'] = toNumber(haGetState('sensor.0x00158d000418441f_temperature'), 1);
-    $res['kitchen_humidity'] = toNumber(haGetState('sensor.0x00158d000418441f_humidity'), true);
-    $res['wc_temp'] = toNumber(haGetState('sensor.0x00158d00046574da_temperature'), 1);
-    $res['wc_humidity'] = toNumber(haGetState('sensor.0x00158d00046574da_humidity'), true);
-    $res['office_temp'] = toNumber(haGetState(['sensor.meter_c7c3_temperature', 'sensor.thx1_w230150x_tempc']), 1);
-    $res['office_humidity'] = toNumber(haGetState(['sensor.meter_c7c3_humidite', 'sensor.thx1_w230150x_hum']), true);
+    $res['outdoor_temp'] = toNumber(haGetState('sensor.sb_balcon_temperature'), true);
+    $res['outdoor_humidity'] = toNumber(haGetState('sensor.sb_balcon_humidite'), true);
+    $res['backyard_temp'] = toNumber(haGetState('sensor.sb_cour_temperature'), 1);
+    $res['backyard_humidity'] = toNumber(haGetState('sensor.sb_cour_humidite'), true);
+    $res['bathroom_temp'] = toNumber(haGetState('sensor.sb_sdb_temperature'), 1);
+    $res['bathroom_humidity'] = toNumber(haGetState('sensor.sb_sdb_humidite'), true);
+    $res['bedroom_temp'] = toNumber(haGetState('sensor.sb_chambre_temperature'), 1);
+    $res['bedroom_humidity'] = toNumber(haGetState('sensor.sb_chambre_humidite'), true);
+    //$res['bedroom_airquality'] = toNumber(haGetState('sensor.0x54ef4410003596e5_voc'), true);
+    $res['livingroom_temp'] = toNumber(haGetState('sensor.sb_salon_temperature'), 1);
+    $res['livingroom_humidity'] = toNumber(haGetState('sensor.sb_salon_humidite'), true);
+    $res['kitchen_temp'] = toNumber(haGetState('sensor.sb_cuisine_temperature'), 1);
+    $res['kitchen_humidity'] = toNumber(haGetState('sensor.sb_cuisine_humidite'), true);
+    $res['wc_temp'] = toNumber(haGetState('sensor.sb_wc_temperature'), 1);
+    $res['wc_humidity'] = toNumber(haGetState('sensor.sb_wc_humidite'), true);
+    $res['office_temp'] = toNumber(haGetState('sensor.sb_bureau_temperature'), 1);
+    $res['office_humidity'] = toNumber(haGetState('sensor.sb_bureau_humidite'), true);
+    $res['cocodrilo_min'] = toNumber(haGetState('sensor.temperature_interieure_minimale', null, 'cocodrilo'));
+    $res['cocodrilo_max'] = toNumber(haGetState('sensor.temperature_interieure_maximale', null, 'cocodrilo'));
+    $res['cocodrilo_humidity'] = toNumber(haGetState('sensor.humidite_interieure', null, 'cocodrilo'),true);
     $res['cellar_humidity'] = 0;
     $res['cellar_temp'] = 0;
     $res['pressure'] = round($weather['Pressure']['Metric']['Value']);
@@ -101,7 +102,6 @@ function weatherStationScreenSaver()
     $weather = json_decode(file_get_contents(ROOT . '/cache/weather.json'), true);
 
     $pressureTendency = $weather['pressureTendency'] == 'F' ? 'down' : 'up';
-    $pressure = $weather['outdoor_pressure'] == '--' ? $weather['backyard_pressure'] : $weather['outdoor_pressure'];
 
     $res = '<div id="weatherstation" class="screensaver">';
     $res .= '<div class="contents">';
@@ -118,7 +118,7 @@ function weatherStationScreenSaver()
     $res .= '<div class="temp-max">' . $weather['max'] . '°C</div>';
     $res .= '</div>';
     $res .= '<div class="pp">';
-    $res .= '<i class="fas fa-cloud-rain"></i> ' . $weather['precipitations24'] . ' mm | <i class="fas fa-tachometer-alt"></i> ' . $pressure . ' hPa <i class="fa fa-arrow-circle-' . $pressureTendency . '"></i> | <i class="fa fa-tint"></i> ' . $weather['outdoor_humidity'] . '%';
+    $res .= '<i class="fas fa-cloud-rain"></i> ' . $weather['precipitations24'] . ' mm | <i class="fas fa-tachometer-alt"></i> ' . $weather['pressure'] . ' hPa <i class="fa fa-arrow-circle-' . $pressureTendency . '"></i> | <i class="fa fa-tint"></i> ' . $weather['outdoor_humidity'] . '%';
     $res .= '</div>';
     $res .= '<table class="house">';
     $res .= '<tr><td class="hicon backyard"><i class="fa fa-flower-tulip"></i></td><td class="backyard">' . $weather['backyard_temp'] . ' °C</td><td class="hicon hum backyard"><i class="fa fa-tint"></i></td><td class="hum backyard">' . $weather['backyard_humidity'] . '%</td>';
@@ -128,7 +128,9 @@ function weatherStationScreenSaver()
     $res .= '<tr><td class="hicon wc"><i class="fa fa-toilet"></i></td><td class="wc">' . $weather['wc_temp'] . ' °C</td><td class="hicon hum wc"><i class="fa fa-tint"></i></td><td class="hum wc">' . $weather['wc_humidity'] . '%</td>';
     $res .= '<td class="sep"></td><td class="hicon bedroom"><i class="fa fa-bed"></i></td><td class="bedroom">' . $weather['bedroom_temp'] . ' °C</td><td class="hicon hum bedroom"><i class="fa fa-tint"></i></td><td class="hum bedroom">' . $weather['bedroom_humidity'] . '%</td>';
     $res .= '<tr><td class="hicon bathroom"><i class="fa fa-bath"></i></td><td class="bathroom">' . $weather['bathroom_temp'] . ' °C</td><td class="hicon hum bathroom"><i class="fa fa-tint"></i></td><td class="hum bathroom">' . $weather['bathroom_humidity'] . '%</td>';
-    $res .= '<td class="sep"></td><td class="hicon cellar"><i class="fa fa-bat"></i></td><td class="cellar">' . $weather['cellar_temp'] . ' °C</td><td class="hicon hum cellar"><i class="fa fa-tint"></i></td><td class="hum cellar">' . $weather['cellar_humidity'] . '%</td></tr>';
+    $res .= '<td class="sep"></td><td class="hicon cellar"><svg style="width: 22px; transform: translateY(3px) scale(1.1, 1.4);" viewBox="0 0 18 18">
+  <path fill="currentColor" d="M10.9,4.6c-.3,0-.7.2-.9.5-.1,0-.2.2-.3.3h0c0,.1-.5.1-.5.1h-.5l-.3-.2c-.5-.4-.7-.5-.8-.4,0,0,0,.2-.1.4,0,.2-.1.4-.1.4,0,0,0,0-.2,0h-.2s-.3-.2-.3-.2c-.3-.3-.7-.5-.7-.5s0,0-.3.5c0,.2-.2.4-.2.4,0,0,0,0-.2,0h-.2s0,0,0,0c-.7-.6-1-.8-1.1-.7,0,0-.2.5-.3.9h0c0,.1-.3.2-.3.2-1.5.3-2.7,1.2-3.1,2.4-.1.4-.2.6-.2,1.2s0,.5,0,.7c.3,1.2,1,2.1,2.1,2.7,1.1.6,2.5.8,4.6.7,1.2,0,1.9,0,4.1-.2,1.5-.1,2-.2,2.6-.2s1.1,0,1.5.2c.3,0,.4,0,.4-.1,0,0,0-.2-.2-.4-.5-.5-1.3-.9-2.2-1-.7-.1-1.4-.1-4.4-.2-2.5,0-3,0-3.5-.1-.9-.1-1.5-.5-1.7-1-.2-.4-.2-.7.1-1s.2-.2.2-.2c0,0,.1.1.2.3.2.8.4,1.1.7,1.2.1,0,.2,0,1.2,0h1,0c0-.3-.2-.6-.5-.7,0,0-.2,0-.4-.1h-.2s0-.2,0-.2c0,0,0-.1,0-.2h0c0,0,1.2,0,1.2,0h1.2s0,.2,0,.2c0,0,.2.3.2.5.2.5.3.6.7.6.1,0,.7,0,1.4,0h1.2s0,0,0,0c0-.1-.1-.3-.3-.5-.2-.2-.4-.3-.7-.4-.3,0-.3,0-.4-.3,0-.2,0-.3,0-.3,0,0,1.1,0,3.2,0s3.1,0,3.2,0c.3,0,.5-.3.6-.5.1-.3,0-.4-.2-.4-.3,0-.2,0-.3-.2-.1-.3-.2-.5-.3-.5,0,0-.1.1-.2.3,0,.1-.2.3-.2.3,0,0-.1,0-.3,0h-.3s-.1-.3-.1-.3c0-.1-.1-.3-.2-.3h0c0,0,0,0,0,0,0,0-.1.2-.2.2-.1.1-.1.2-.2.1-.8-.1-1.9-.4-2.5-.6h-.3c0,0,.1-.2.1-.2.4-.3.9-.4,1.8-.5h.3s.1.3.1.3c0,.1.1.3.2.3,0,0,.1,0,.3-.3v-.2h.3c0,0,.2,0,.4,0h.2s.1.2.1.2c.1.2.2.4.3.3,0,0,0-.2.2-.3l.2-.3h.3c.4,0,.3,0,.5.2,0,.1.1.2.1.2,0,0,0,0,0,0,0,0,0-.2.1-.3,0-.2.1-.3.2-.4.2-.2.4-.7.3-1,0-.2-.1-.4-.3-.5-.5-.5-1.2-.4-1.6.2h0c0,.1-1.6.1-1.6.1h-1.7c-.1-.3-.4-.6-.5-.7-.4-.3-.9-.4-1.3-.3ZM11.4,5.6c.2,0,.3.4.2.6,0,.2-.2.3-.4.3s-.4-.1-.4-.3c-.1-.3,0-.6.4-.6,0,0,.1,0,.2,0Z"/>
+</svg></td><td class="cellar">' . $weather['cocodrilo_min'] . ' / ' . $weather['cocodrilo_max'] . ' °C</td><td class="hicon hum cellar"><i class="fa fa-tint"></i></td><td class="hum cellar">' . $weather['cocodrilo_humidity'] . '%</td></tr>';
     $res .= '</table>';
     $res .= '</div>';
     $res .= '<div class="forecasts">';