Un código muy sencillo que es realmente útil a la hora de almacenar valores en un archivo y leerlos luego.
A very simple piece of code that is really useful to read values stored in a file.
String readFileValue(){
FILE *filePointer;
filePointer = fopen("/myStoredData.txt","r");
char fileContent[100];
fgets (fileContent , 100, filePointer);
Serial.println(fileContent);
return fileContent;
}
#Howto read contents of a file into a String variable in an ARDUINO sketch
![]()
Comentarios