I have a Photovoltaic system that I'm monitoring with my Raspberry PI.
I'm able to read with an URL the value of the power generated [$kw_prod] with the following script
Code: Select all
$URL_123solar = "http://192.168.1.22/123solar/programs/programmultilive.php";
$json_123solar = file_get_contents($URL_123solar);
$data_123solar = json_decode($json_123solar, true);
if (isset($data_123solar["GPTOT"]))
{
$kw_prod = $data_123solar["GPTOT"];
} else {
$kw_prod = "0";
}
# ----------------------
I suppose I should use "Load custom JavaScript code" or "Load custom JavaScript file" module but honestly I don't know where to start from.
Thanks for your help