nfc6 2.1.0.0
|
API for configuring and manipulating NFC 6 Click driver. More...
Topics | |
NFC 6 Registers List | |
List of registers of NFC 6 Click driver. | |
NFC 6 Registers Settings | |
Settings for registers of NFC 6 Click driver. | |
NFC 6 MikroBUS Map | |
MikroBUS pin mapping of NFC 6 Click driver. | |
Functions | |
void | nfc6_cfg_setup (nfc6_cfg_t *cfg) |
NFC 6 configuration object setup function. | |
err_t | nfc6_init (nfc6_t *ctx, nfc6_cfg_t *cfg) |
NFC 6 initialization function. | |
err_t | nfc6_default_cfg (nfc6_t *ctx) |
NFC 6 default configuration function. | |
err_t | nfc6_send_command (nfc6_t *ctx, uint8_t cmd, uint8_t *data_in, uint8_t len) |
NFC 6 send command function. | |
err_t | nfc6_read_data (nfc6_t *ctx, uint8_t *data_out, uint16_t buffer_size, uint16_t *rx_len) |
NFC 6 read data function. | |
err_t | nfc6_poll_ready (nfc6_t *ctx) |
NFC 6 poll ready function. | |
err_t | nfc6_poll_ready_irq (nfc6_t *ctx) |
NFC 6 poll ready irq function. | |
err_t | nfc6_reset_device (nfc6_t *ctx) |
NFC 6 reset device function. | |
err_t | nfc6_check_command_echo (nfc6_t *ctx) |
NFC 6 check command echo function. | |
void | nfc6_pulse_irq_in (nfc6_t *ctx) |
NFC 6 pulse irq in function. | |
void | nfc6_set_irq_in_pin (nfc6_t *ctx, uint8_t state) |
NFC 6 set irq in pin function. | |
uint8_t | nfc6_get_irq_out_pin (nfc6_t *ctx) |
NFC 6 get irq out pin function. | |
err_t | nfc6_calibrate_device (nfc6_t *ctx) |
NFC 6 calibrate device function. | |
err_t | nfc6_select_protocol (nfc6_t *ctx, uint8_t protocol) |
NFC 6 select protocol function. | |
err_t | nfc6_read_mifare_tag_uid (nfc6_t *ctx, uint8_t *tag_uid, uint8_t *tag_uid_len) |
NFC 6 read MIFARE tag UID function. | |
API for configuring and manipulating NFC 6 Click driver.
Any initialization code needed for MCU to function properly. Do not remove this line or clock might not be set correctly.
err_t nfc6_calibrate_device | ( | nfc6_t * | ctx | ) |
NFC 6 calibrate device function.
This function performs the tag detection calibration.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation. void nfc6_cfg_setup | ( | nfc6_cfg_t * | cfg | ) |
NFC 6 configuration object setup function.
This function initializes click configuration structure to initial values.
[out] | cfg | : Click configuration structure. See nfc6_cfg_t object definition for detailed explanation. |
err_t nfc6_check_command_echo | ( | nfc6_t * | ctx | ) |
NFC 6 check command echo function.
This function checks the communication by sending and checking the command echo response.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation. err_t nfc6_default_cfg | ( | nfc6_t * | ctx | ) |
NFC 6 default configuration function.
This function executes a default configuration of NFC 6 click board.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation. uint8_t nfc6_get_irq_out_pin | ( | nfc6_t * | ctx | ) |
NFC 6 get irq out pin function.
This function returns the IRQ_OUT pin logic state.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
err_t nfc6_init | ( | nfc6_t * | ctx, |
nfc6_cfg_t * | cfg ) |
NFC 6 initialization function.
This function initializes all necessary pins and peripherals used for this click board.
[out] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
[in] | cfg | : Click configuration structure. See nfc6_cfg_t object definition for detailed explanation. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation. err_t nfc6_poll_ready | ( | nfc6_t * | ctx | ) |
NFC 6 poll ready function.
This function waits for the device data ready indication via command interface.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation. err_t nfc6_poll_ready_irq | ( | nfc6_t * | ctx | ) |
NFC 6 poll ready irq function.
This function waits for the device data ready indication via IRQ pin.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation. void nfc6_pulse_irq_in | ( | nfc6_t * | ctx | ) |
NFC 6 pulse irq in function.
This function sends a pulse on the IRQ_IN pin.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
err_t nfc6_read_data | ( | nfc6_t * | ctx, |
uint8_t * | data_out, | ||
uint16_t | buffer_size, | ||
uint16_t * | rx_len ) |
NFC 6 read data function.
This function reads a response data bytes by using SPI serial interface.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
[out] | data_out | : Output read data. |
[in] | buffer_size | : Data output buffer size. |
[out] | rx_len | : Number of bytes that were available for read. |
0
- Success, -1
- Error, >0
- Response code error. See #err_t definition for detailed explanation. err_t nfc6_read_mifare_tag_uid | ( | nfc6_t * | ctx, |
uint8_t * | tag_uid, | ||
uint8_t * | tag_uid_len ) |
NFC 6 read MIFARE tag UID function.
This function reads the UID of a MIFARE ISO14443-A type tags with 4-byte or 7-byte UIDs.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
[out] | tag_uid | : MIFARE tag UID array (up to 7 bytes). |
[out] | tag_uid_len | : MIFARE tag UID lenght. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation. err_t nfc6_reset_device | ( | nfc6_t * | ctx | ) |
NFC 6 reset device function.
This function performs a device software reset.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation. err_t nfc6_select_protocol | ( | nfc6_t * | ctx, |
uint8_t | protocol ) |
NFC 6 select protocol function.
This function selects the RF communication protocol and prepares the ST25R95 for communication with a contactless tag.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
[in] | protocol | :
|
0
- Success, -1
- Error. See #err_t definition for detailed explanation. err_t nfc6_send_command | ( | nfc6_t * | ctx, |
uint8_t | cmd, | ||
uint8_t * | data_in, | ||
uint8_t | len ) |
NFC 6 send command function.
This function sends a desired command by using SPI serial interface.
[in] | ctx | : Click context object. See nfc6_t object definition for detailed explanation. |
[in] | cmd | : Command byte to send. |
[in] | data_in | : Command parameter buffer. |
[in] | len | : Number of bytes in parameter buffer. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation.