hi
Im not having much luck to get this working with TimePlot. Im looking for how to format the senddata command so i can use the local RTC vs the pc time.
My function is as
TemperaturePlot.SendData(F("Temperature Fahrenheit"),TempsF); and prints as {TIMEPLOT:Temperature|DATA|Temperature Fahrenheit|T|32}
in the serial monitor which is correct.
Fahrenheit|T|32} The |T| tells us this is using pc time. I need to know where and how to format to use arduino rtc in the function. I cannot find any info thru the online docs.
Thanks
RTC on Arduino call to send with Senddata function
Hi, unfortunately the arduino library doesn't support that functionally (yet). We have added it to our request list. To make it work you'd need to manually assemble a serial message and match your real time clock daya to the format covered here:
https://www.megunolink.com/documentatio ... reference/
Cheers
Phil
https://www.megunolink.com/documentatio ... reference/
Cheers
Phil
Hi
I have tried using the serialized version of the send command {TIMEPLOT:TemperaturePlot|data|Temperature Celcius|T|25.6} and of course this works. Then replacing T with a string, that CONCATENATES my time format as per your link yyyy-mm-dd hr:mm:ss this doesnt work. In the serial monitor it merely shows my String function variable name and of course this is incorrect.
What am i missing?
Thanks
I have tried using the serialized version of the send command {TIMEPLOT:TemperaturePlot|data|Temperature Celcius|T|25.6} and of course this works. Then replacing T with a string, that CONCATENATES my time format as per your link yyyy-mm-dd hr:mm:ss this doesnt work. In the serial monitor it merely shows my String function variable name and of course this is incorrect.
What am i missing?
Thanks
PlotTemperatureC(TempsInC); to call the function below, where "TempsInC" is a string variable of temperature.
This as is works with no problem, but is using computer time |T|
void PlotTemperatureC(String data)
{
Serial.print("{TIMEPLOT:Temperature|data|Temperature Celcius|T|");
Serial.print(data);
Serial.println("}");
}
Simply replacing |T| with a string variable of time stamp. The string is "2020-10-14 02:09:10"
I have also tried "2020/10/14 02:09:10"
Serial.print("{TIMEPLOT:Temperature|data|Temperature Celcius|2020/10/14 02:09:10|");
Actual .... Serial.print("{TIMEPLOT:TemperatureColin|data|Temperature Celcius|TimeIn|"); where "TimeIn string variable is formatted as shown above.
If its not a string variable that is valid, what is the correct method to populate this with?
Thanks
This as is works with no problem, but is using computer time |T|
void PlotTemperatureC(String data)
{
Serial.print("{TIMEPLOT:Temperature|data|Temperature Celcius|T|");
Serial.print(data);
Serial.println("}");
}
Simply replacing |T| with a string variable of time stamp. The string is "2020-10-14 02:09:10"
I have also tried "2020/10/14 02:09:10"
Serial.print("{TIMEPLOT:Temperature|data|Temperature Celcius|2020/10/14 02:09:10|");
Actual .... Serial.print("{TIMEPLOT:TemperatureColin|data|Temperature Celcius|TimeIn|"); where "TimeIn string variable is formatted as shown above.
If its not a string variable that is valid, what is the correct method to populate this with?
Thanks