This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Tool/software: Code Composer Studio
I am trying to utilize JSON to update information in the GUI. I have the LED working as well as the sliding temperature graph, but I can not get the XYZ plot to work. I have looked through documentation and can not find anything about the JSON format for the graph. What is the required format for the data values utilizing JSON?
Hi Dillon,
To bind data to the ti-widget-linegraph, you will need to format the data assigned to the series_X_values (e.g. series_0_values) property in the following format:
x0,y0;x1,y1;x2,y2; etc.
i.e. the x and y values for each data point are separated by a comma, and the x/y data points are separated by semicolons.
You can see this in action by dragging the Line Graph widget onto your design, and changing the value of the series_0_values to e.g. 0,1;1,2;2,4;3,2;4,1;
Alternatively, if you have a series of samples that occurs at regular intervals, you can pass in a series of y values separated by semicolons as the data array.
Displaying X,Y,Z data in a ti-widget-linegraph is done by setting the num-channels property to 2, and using series_0_values to display x,y data points and the series_1_values to display x,z data points. Note that you won't see the second line on the graph appear in the designer, you will need to run your application for it to show up
I'll make sure that the documentation for the ti-widget-linegraph gets updated to provide better information about this.
Regards,
Brian