X_NUCLEO_NFC02A1 library for M24LR
Dependencies: ST_INTERFACES
Dependents: HelloWorld_NFC02A1_mbedOS HelloWorld_NFC02A1laatste HelloWorld_NFC02A1
Fork of X_NUCLEO_NFC02A1 by
X-NUCLEO-NFC02A1 Dynamic NFC Tag Expansion Board Firmware Package
Introduction
This firmware package includes Components Device Drivers, Board Support Package and example applications for STMicroelectronics X-NUCLEO-NFC02A1 Dynamic NFC Tag Expansion Board based on M24LR.
Firmware Library
Class X_NUCLEO_NFC02A1 is intended to represent the Dynamic NFC Tag Expansion Board with the same name.
It provides an API to access to the M24LR component and to the three onboard LEDs.
It is intentionally implemented as a singleton because only one X_NUCLEO_NFC02A1 at a time might be deployed in a HW component stack.
The library also provides an implementation of the NDEF library API for M24LR, providing an simple way to read/write NDEF formatted messages from/to the M24LR dynamic NFC tag.
Example application
Hello World is a simple application to program and read an URI from the NFC tag.
Diff: m24lr/M24LR.h
- Revision:
- 7:b876cdcf095a
- Parent:
- 6:8c1eca41b3a9
- Child:
- 8:7c4cf671960b
--- a/m24lr/M24LR.h Fri May 19 07:51:32 2017 +0000 +++ b/m24lr/M24LR.h Tue Jul 11 15:23:56 2017 +0000 @@ -262,7 +262,7 @@ return i2c_write_data( pDataToWrite, Offset, NbByteToWrite ); } - M24LR(uint8_t const address, uint8_t const addressData, DevI2C &devI2C ): + M24LR(uint8_t const address, uint8_t const addressData, DevI2C *devI2C ): NDefTagUtil(*this), i2c_address_syst(address), i2c_address_data(addressData), dev_I2C(devI2C) {} @@ -290,7 +290,7 @@ uint8_t i2c_address_syst; uint8_t i2c_address_data; - DevI2C dev_I2C; + DevI2C *dev_I2C; };