NFC-V definitions.
More...
#include "nfcv.hpp"
#include "nfc/manufacturer_id.hpp"
#include <M5Utility.hpp>
|
| namespace | m5 |
| | Top level namespace of M5Stack.
|
| |
|
| Type | m5::nfc::v::identify_type (const PICC &picc) |
| | Identify the type from Manufacturer Code, IC Identifier, IC Reference.
|
| |
| uint32_t | m5::nfc::v::encode_VCD (std::vector< uint8_t > &out, const ModulationMode mode, const uint8_t *buffer, const uint32_t length, const bool high_rate=true, const bool add_crc=true) |
| | Encode to VCD frame.
|
| |
| bool | m5::nfc::v::decode_VICC (std::vector< uint8_t > &out, const uint8_t *buffer, const uint32_t length, const uint32_t ignore_bits=16) |
| | Decode from VICC frame.
|
| |
◆ decode_VICC()
| bool m5::nfc::v::decode_VICC |
( |
std::vector< uint8_t > & | out, |
|
|
const uint8_t * | buffer, |
|
|
const uint32_t | length, |
|
|
const uint32_t | ignore_bits = 16 ) |
Decode from VICC frame.
- Parameters
-
| out | Output buffer |
| buffer | Input buffer |
| length | Input buffer length |
| ignore_bits | Number of trailing bits to ignore |
- Returns
- True if successful
◆ encode_VCD()
| uint32_t m5::nfc::v::encode_VCD |
( |
std::vector< uint8_t > & | out, |
|
|
const ModulationMode | mode, |
|
|
const uint8_t * | buffer, |
|
|
const uint32_t | length, |
|
|
const bool | high_rate = true, |
|
|
const bool | add_crc = true ) |
Encode to VCD frame.
- Parameters
-
| out | Output buffer |
| mode | ModulationMode |
| buffer | Input buffer (allow nullptr ) |
| length | Input buffer length (allow 0) |
| high_rate | High data rate if true |
| add_crc | Append CRC16 if true |
- Returns
- Encoded size in bytes, or 0 on error
- Note
- Make EOF only if buffer is nullptr and length is 0
◆ identify_type()
| Type m5::nfc::v::identify_type |
( |
const PICC & | picc | ) |
|
Identify the type from Manufacturer Code, IC Identifier, IC Reference.
- Parameters
-
| picc | PICC information to identify |
- Returns
- Type
- Warning
- Not all tags can be identified
-
If identification is impossible, Unclassified is returned