M5Unit-RFID 0.2.0 git rev:79c1939
Loading...
Searching...
No Matches
m5::uhf::Epc Struct Reference

EPC of a tag. More...

#include <uhf.hpp>

Public Member Functions

uint8_t operator[] (const size_t i) const
 Byte at the given index.
 
uint8_t & operator[] (const size_t i)
 Byte at the given index.
 
const uint8_t * begin () const
 
const uint8_t * end () const
 
bool empty () const
 Holds no EPC?
 
bool assign (const uint8_t *src, const size_t len)
 Copy in from a raw buffer, refusing anything longer than EPC_MAX_BYTES.
 
bool operator== (const Epc &o) const
 
std::string toString () const
 Uppercase hex.
 

Public Attributes

std::array< uint8_t, EPC_MAX_BYTESdata {}
 Bytes, only the first size are valid.
 
uint8_t size {}
 Number of valid bytes.
 

Detailed Description

EPC of a tag.

A tag's EPC is variable length, so the used size travels with the bytes. The storage is a fixed array: queueing tags must never touch the heap