-
-
Save parzibyte/4925293041f1aa89092f31999f837b94 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void loop() | |
{ | |
if (MODO == MODO_LECTURA) | |
{ | |
char contenidoRfid[LONGITUD_BYTES] = ""; | |
bool lecturaExitosa = leer(contenidoRfid); | |
if (lecturaExitosa) | |
{ | |
Serial.println("Lo que hay escrito es:"); | |
Serial.println(contenidoRfid); | |
} | |
else | |
{ | |
Serial.println("Error leyendo. Tal vez no hay RFID presente"); | |
} | |
} | |
else if (MODO == MODO_ESCRITURA) | |
{ | |
char mensaje[] = "parzibyte"; | |
bool escrituraExitosa = escribir(mensaje); | |
if (escrituraExitosa) | |
{ | |
Serial.println("Escrito ok"); | |
} | |
else | |
{ | |
Serial.println("Error escribiendo. Tal vez no hay RFID presente"); | |
} | |
} | |
delay(1000); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment