17-02-2020, 10:43
Hello, Thank you very much, now it works!
I saw an JSON file with all data in local IP adress.
I created a simply PHP file to test data in my server, but I saw only empty data, this is the script:
<?php
//www.mywebsite.com/dust/SQL.php?privatekey=YOURKEY&PM25=99&PM100=98.7&AQI=97&CO2=96
$pm25 = $_GET["PM25"];
$pm100 = $_GET["PM100"];
$aqi = $_GET["AQI"];
$co2 = $_GET["CO2"];
$key = $_GET["privatekey"];
$id = $_GET["DevID"];
//print $pm100."|".$pm25."|".$aqi."|".$co2;
$scrivifile=$pm100."|".$pm25."|".$aqi."|".$co2;
$filenameserver='dati.txt';
$file = fopen($filenameserver, "w");
fwrite($file, $scrivifile);
fclose($file);
?>
if I want to change read interval of the sensor, have I to change these rows?
for example:
1) const byte readInterval = 5;
2) if (!first4readings) divider = 12;
3) if (readCount_1H == 12)
Are there others?
Thank you.
I saw an JSON file with all data in local IP adress.
I created a simply PHP file to test data in my server, but I saw only empty data, this is the script:
<?php
//www.mywebsite.com/dust/SQL.php?privatekey=YOURKEY&PM25=99&PM100=98.7&AQI=97&CO2=96
$pm25 = $_GET["PM25"];
$pm100 = $_GET["PM100"];
$aqi = $_GET["AQI"];
$co2 = $_GET["CO2"];
$key = $_GET["privatekey"];
$id = $_GET["DevID"];
//print $pm100."|".$pm25."|".$aqi."|".$co2;
$scrivifile=$pm100."|".$pm25."|".$aqi."|".$co2;
$filenameserver='dati.txt';
$file = fopen($filenameserver, "w");
fwrite($file, $scrivifile);
fclose($file);
?>
if I want to change read interval of the sensor, have I to change these rows?
for example:
1) const byte readInterval = 5;
2) if (!first4readings) divider = 12;
3) if (readCount_1H == 12)
Are there others?
Thank you.

