<< Click to Display Table of Contents >> Navigation: Tips and Tricks > Saving CSV data |
The content of the Terminal Log window can be stored in the CSV file and then the data can be processed in a spreadsheet.
•Upload the following application into the TR module:
uns8 val_1, val_2;
enableSPI();
val_1 = 0;
val_2 = 255;
while(1)
{
++val_1;
--val_2;
bufferCOM[0] = '#'; // needed for Terminal - Use Numbers feature
bufferCOM[1] = val_1;
bufferCOM[2] = ';'; // separator
bufferCOM[3] = '#'; // needed for Terminal - Use Numbers feature
bufferCOM[4] = val_2;
startSPI(5);
while(getStatusSPI());
}
•Set the Terminal Log according to the picture below.
•After data reading save the content of the window as a CSV file.
•Data in CSV file is stored in the following format:
1;10:52:28:964;RxD;5;1;254
2;10:52:29:264;RxD;5;2;253
3;10:52:29:561;RxD;5;3;252
4;10:52:29:846;RxD;5;4;251
5;10:52:30:159;RxD;5;5;250
...
•Open and process the CSV file in a spreadsheet.