This is project I did a long time ago. Because of this project, I learn a lot of things. (Not only academically, but also the attitude of dealing with people.)

First, look back the board I designed in the past.

the board

As we all know practice makes prefect. This is the design when I just learned how to use AD software. Integrated by three modules. Arduino uno, ESP8266 and PN532.

I use ESP8266 to wirelessly transmit the information received by PN532.

About ESP8266

It has three modes

  1. STA (station)
  2. AP (Access Point)
  3. STA、AP Both

The technical part adopts STA mode in this project. Arduino sends AT instruction to initialize the module.
ESP8266
But how to connect with the module.
My method is as follows.

Arduino connect ESP8266
3.3V <—> VCC
GND <—> GND
TXD <—> RXD
RXD <—> TXD
3.3V <—> CH _PD(I added pull-up resistor 1.5K*3. Add a pull resistor about 10K on the internet.)

On transmission communication of several modes of PN532.

modes of PN532

As you can see, there are three modes to transmit messages.
HSU、SPI、I2C.

Used with Arduino UNO:
In HSU mode, the serial port monitor will have no information (inconvenient for debugging).
I have never used I2C mode. So I use SPI mode to implementation.
How to turn on SPI mode? Switch channel1: OFF, channel2: ON.

This is the note I wrote before.
Notes made before.

Module connection

Arduino connect PN532(SPI mode)
Pin13 or ICSP-3 <—> SCK
Pin12 or ICSP-1 <—> MISO
Pin12 or ICSP-4 <—> MOSI
Pin10 <—> SS
PN532 Pin Description of pin
SCK: Serial Clock
MISO: Master Input Slave Output
MOSI: Master Output Slave Input
SS(CS): Chip Select

Oh my god. What a terrible design. (This is what I made at that time.)
terrible design

Hardware running process.

  1. Arduino power-on startup procedure.
  2. Initialize the wireless module, connect the wireless module with the preset WiFi, and then connect the server written in Java through TCP protoco
  3. PN532 starts and waits for the card to be read.
  4. When there is a card on it, send the card ID to the server.

Software part:
Database design, Server based on Java.

Java server code:
It is divided into three parts: Server part, multithreading part, and display database part (for the convenience of connecting with Android in the back).

Implementation effect
Display
Display2

Video in bilibili.

Now you can download some code on github, just click here.