Problem with new Update 6/5/2017

Support forum for MegunoLink
Post Reply
dhaffnersr
Posts: 1
Joined: Mon Apr 03, 2017 7:30 pm

Mon Jun 05, 2017 2:28 pm

I am getting this error; no matching function for call to 'XYPlot::SendData(const char [13], int&)'

this is my code snippet; void loop() /*----( LOOP: RUNS CONSTANTLY )----*/
{

{
if ((millis() - LastSent) > SendInterval)
{

LastSent = millis();

int DataValue = analogRead(A0);
MyPlot.SendData("stepperValue", DataValue);

The error is the code in "red," I am setting up my program to monitor a POT attached to pin A0, it was working fine under TimePlot function, but when I updated MegunoLinkPro, now I get this error for XYPlotting?

Need some help :)
philr
Posts: 446
Joined: Mon May 26, 2014 10:58 am

Tue Jun 06, 2017 12:18 am

Hi, it appears you are using our XYPlot class. This requires an X and Y value to be sent across. In your example, you are only sending a single value. I suggest you switch to our TimePlot class which will automatically generate a timestamp for you.

Cheers
Phil
Post Reply