Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created June 4, 2021 17:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/26a0e4c49511710b19a86dcb5cf48f19 to your computer and use it in GitHub Desktop.
Save parzibyte/26a0e4c49511710b19a86dcb5cf48f19 to your computer and use it in GitHub Desktop.
void setup()
{
Serial.begin(9600);
while (!Serial)
{
// Esperar serial. Nota: la tarjeta NO HARÁ NADA hasta que haya comunicación Serial (es decir, que el monitor serial sea abierto)
// si tú no quieres esto, simplemente elimina todas las llamadas a Serial
}
// Iniciar lector
SPI.begin();
lector.PCD_Init();
// Preparar la clave para leer las tarjetas RFID
for (byte i = 0; i < 6; i++)
{
clave.keyByte[i] = 0xFF;
}
Serial.println("Iniciado correctamente");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment