Site icon 14core.com

Wiring the PN532 (NFC) Near Field Communication Devices with Microcontroller

NFC (Near-field communication) is a protocol that enable 2 devices to communicate typically smart phone device and NFC tags / devices to establish communication by getting them together range of 4 cm at 1.6 inch defends of usage and antenna circuitry. NFC device are used in contactless payment system, security, marketing, transportations, Bluetooth fairing. Etc. NFC also can be found on your mobile phones that can act as electronic identity documents and keycards working on a low speed connection.


Each NFC device can work in 3 modes, can be NFC Card Emulation it means that NFC device such as smart phones can act as smart cards allowing the smart phones to transact as payment or ticketing. NFC devices also allows you two write / read information stored on NFC tags in embedded in labels, tickers, passports or smart posters. NFC PTP (Pear to Pear) allows you to NFC enabled devices to communicate with each other devices to exchange information.

The diagram below demonstrate how to used NFC devices with your microcontrollers. As you can see the diagram below there are two options the first option is wired using i2C (2 Wire Communication), second option is wired using SPI (Serial Peripheral Interface) below are the component required for this test.

Required Components

Wiring Guide

When you save and upload the code below unto your MCU w/d the module/shield attached you can now begin testing and show the message burn-in your tags, when you upload the code into the MCU then opening the serial monitor you will see the message 14CORE | NFC – i2C Test Code TAG Reader see below code to write data into your TAGS to read from your smart phone.

Source Code for i2C
[crayon-6766ce66b071b512948460/]
Source Code for SPI
[crayon-6766ce66b0724540358713/]
Writing on NFC Tag Source Code

[crayon-6766ce66b0729426049838/]
Downloads

Wiring the PN532 (NFC) Near Field Communication Devices with Microcontroller
Exit mobile version