I need help to load variables from certain line in SD card text
First, you need to read from the SD card, and store in an array, all the characters that make up a record. Do you have code to do that?
Next, you need to parse the stored data. If you can change the format of the data, parsing can be easy. If not, parsing is going to be harder. Can you change the format?
reg=001, i=32.6, j=5
would be simpler to parse. Look for the commas to get the tokens, like "reg=001", "i=32.6", and "j=5". Then, parse each token to get the name and value (as string). Finally, convert the value as string to a value, and store it in the correct variable based on the name token.
I need help to load variables from certain line in SD card text
First, you need to read from the SD card, and store in an array, all the characters that make up a record. Do you have code to do that?
The code is make up in C++ program in a computer and stored on SD.
Next, you need to parse the stored data. If you can change the format of the data, parsing can be easy. If not, parsing is going to be harder. Can you change the format?
I can´t change the format =(
reg=001, i=32.6, j=5
would be simpler to parse. Look for the commas to get the tokens, like "reg=001", "i=32.6", and "j=5". Then, parse each token to get the name and value (as string). Finally, convert the value as string to a value, and store it in the correct variable based on the name token.