38#include "driver/spi_master.h"
39#include "driver/i2c_master.h"
54#define PN532_MIFARE_ISO14443A (0x00U)
60#define PN532_MAX_APDU_LEN (252U)
63#define PN532_I2C_ADDRESS (0x24U)
251 uint8_t *response, uint16_t *response_len);
esp_err_t pn532_init(pn532_t *dev, const pn532_config_t *config)
Initialise the PN532 and bring it to a ready state.
uint32_t pn532_read_passive_target_id(pn532_t *dev, uint8_t cardbaudrate)
Scan for a passive ISO 14443-A card and return its UID.
bool pn532_send_apdu(pn532_t *dev, const uint8_t *apdu, uint8_t apdu_len, uint8_t *response, uint16_t *response_len)
Exchange a single ISO-DEP APDU with the currently selected card.
uint32_t pn532_get_firmware_version(pn532_t *dev)
Query the PN532 firmware version.
bool pn532_sam_config(pn532_t *dev)
Configure the PN532's Security Access Module (SAM).
pn532_transport_t
Physical bus used to communicate with the PN532.
bool pn532_release_target(pn532_t *dev)
Release the currently selected NFC target.
Compile-time configuration passed to pn532_init.
spi_host_device_t spi_host
pn532_transport_t transport
Opaque-like runtime state for a single PN532 instance.
i2c_master_dev_handle_t i2c_dev
i2c_master_bus_handle_t i2c_bus
pn532_transport_t transport