Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: main.cpp
- Revision:
- 1:27fb38198323
- Parent:
- 0:4b5aa5fe3ff4
- Child:
- 2:e27413743e1b
--- a/main.cpp Thu Apr 06 09:34:26 2017 +0000 +++ b/main.cpp Thu Apr 13 05:33:25 2017 +0000 @@ -1,20 +1,21 @@ -//Test of cheap 13.56 Mhz RFID-RC522 module from eBay -//This code is based on Martin Olejar's MFRC522 library. Minimal changes -//Adapted for Nucleo STM32 F401RE. Should work on other Nucleos too - +//Test of cheap 13.56Mhz RFID-RC522 module //Connect as follows: -//RFID pins -> Nucleo header CN5 (Arduino-compatible header) +//RFID pins -> WIZWiki-W7500 header CN5 (Arduino-compatible header) //---------------------------------------- -//RFID IRQ=pin5 -> Not used. Leave open -//RFID MISO=pin4 -> Nucleo SPI_MISO=PA_6=D12 -//RFID MOSI=pin3 -> Nucleo SPI_MOSI=PA_7=D11 -//RFID SCK=pin2 -> Nucleo SPI_SCK =PA_5=D13 -//RFID SDA=pin1 -> Nucleo SPI_CS =PB_6=D10 -//RFID RST=pin7 -> Nucleo =PA_9=D8 +//1.RFID IRQ -> Not used. Leave open +//2.RFID MISO -> WIZWiki-W7500 SPI_MISO =D12 +//3.RFID MOSI -> WIZWiki-W7500 SPI_MOSI =D11 +//4.RFID SCK -> WIZWiki-W7500 SPI_SCK =D13 +//5.RFID SDA -> WIZWiki-W7500 SPI_CS =D10 +//6.RFID RST -> WIZWiki-W7500 =D9 //3.3V and Gnd to the respective pins + +//Adding Library for Mbed #include "mbed.h" +//Adding Library for MFRC522 #include "MFRC522.h" +//Adding Library for SPI protocol #include "SPI.h" #define VERSION "RFID_2017_03_20" #define CIBLE "WIZwiki-W7500" @@ -26,7 +27,7 @@ #define SPI_SCLK D13 #define SPI_CS D10 -// Nucleo Pin for MFRC522 reset (pick another D pin if you need D8) +// WIZWiki-W7500 Pin for MFRC522 reset(pick another D pin if you need D8) #define MF_RESET D9 DigitalOut LedGreen(D7);