13static const char *
const TAG = 
"pn532_i2c";
 
   40  ESP_LOGV(TAG, 
"Reading response");
 
   46  ESP_LOGV(TAG, 
"Reading response of length %d", 
len);
 
   48    ESP_LOGD(TAG, 
"No response data");
 
   52  if (
data[1] != 0x00 && 
data[2] != 0x00 && 
data[3] != 0xFF) {
 
   54    ESP_LOGV(TAG, 
"read data invalid preamble!");
 
   58  bool valid_header = (
static_cast<uint8_t
>(
data[4] + 
data[5]) == 0 &&  
 
   60                       data[7] == command + 1);                         
 
   63    ESP_LOGV(TAG, 
"read data invalid header!");
 
   70  for (
int i = 0; i < 
len + 1; i++) {
 
   71    uint8_t dat = 
data[i];
 
   77    ESP_LOGV(TAG, 
"read data invalid checksum! %02X != %02X", 
data[
len], 
checksum);
 
   82    ESP_LOGV(TAG, 
"read data invalid postamble!");
 
 
   93  std::vector<uint8_t> 
data;
 
   98  if (
data[1] != 0x00 && 
data[2] != 0x00 && 
data[3] != 0xFF) {
 
  100    ESP_LOGV(TAG, 
"read data invalid preamble!");
 
  104  bool valid_header = (
static_cast<uint8_t
>(
data[4] + 
data[5]) == 0 &&  
 
  108    ESP_LOGV(TAG, 
"read data invalid header!");
 
  115  uint8_t full_len = 
data[4];
 
  117  uint8_t 
len = full_len - 1;
 
 
  124  PN532::dump_config();
 
  125  LOG_I2C_DEVICE(
this);
 
 
 
ErrorCode write(const uint8_t *data, size_t len) const
writes an array of bytes to a device using an I2CBus
 
optional< std::array< uint8_t, N > > read_bytes_raw()
 
enum PN532ReadReady read_ready_(bool block)
 
uint8_t read_response_length_()
 
bool write_data(const std::vector< uint8_t > &data) override
 
bool read_response(uint8_t command, std::vector< uint8_t > &data) override
 
void dump_config() override
 
bool is_read_ready() override
 
bool read_data(std::vector< uint8_t > &data, uint8_t len) override
 
@ ERROR_OK
No error found during execution of method.
 
Providing packet encoding functions for exchanging data with a remote host.
 
void IRAM_ATTR HOT delay(uint32_t ms)