Chameleon-Mini
Public Attributes | List of all members
ConfigurationType Struct Reference

#include <Configuration.h>

Public Attributes

uint16_t MemorySize
 
uint8_t UidSize
 
bool ReadOnly
 
uint8_t TagFamily
 
Codec

Codec related methods.

void(* CodecInitFunc )(void)
 
void(* CodecDeInitFunc )(void)
 
void(* CodecTaskFunc )(void)
 
Application

Application related functions.

void(* ApplicationInitFunc )(void)
 
void(* ApplicationResetFunc )(void)
 
void(* ApplicationTaskFunc )(void)
 
void(* ApplicationTickFunc )(void)
 
uint16_t(* ApplicationProcessFunc )(uint8_t *ByteBuffer, uint16_t BitCount)
 
void(* ApplicationGetUidFunc )(ConfigurationUidType Uid)
 
void(* ApplicationSetUidFunc )(ConfigurationUidType Uid)
 

Detailed Description

With this struct the behavior of a configuration is defined.

Member Data Documentation

◆ CodecInitFunc

void(* ConfigurationType::CodecInitFunc) (void)

Function that initializes the codec.

◆ CodecDeInitFunc

void(* ConfigurationType::CodecDeInitFunc) (void)

Function that deinitializes the codec.

◆ CodecTaskFunc

void(* ConfigurationType::CodecTaskFunc) (void)

Function that is called on every iteration of the main loop. Within this function the essential codec work is done.

◆ ApplicationInitFunc

void(* ConfigurationType::ApplicationInitFunc) (void)

Function that initializes the application.

◆ ApplicationResetFunc

void(* ConfigurationType::ApplicationResetFunc) (void)

Function that resets the application.

◆ ApplicationTaskFunc

void(* ConfigurationType::ApplicationTaskFunc) (void)

Function that is called on every iteration of the main loop. Application work that is independent from the codec layer can be done here.

◆ ApplicationTickFunc

void(* ConfigurationType::ApplicationTickFunc) (void)

Function that is called roughly every 100ms. This can be used for parallel tasks of the application, that is independent of the codec module.

◆ ApplicationProcessFunc

uint16_t(* ConfigurationType::ApplicationProcessFunc) (uint8_t *ByteBuffer, uint16_t BitCount)

This function does two important things. It gets called by the codec. The first task is to deliver data that have been received by the codec module to the application module. The application then can decide how to answer to these data and return the response to the codec module, which will process it according to the configured codec.

Parameters
ByteBufferPointer to the start of the buffer, where the received data are and where the application can put the response data.
BitCountNumber of bits that have been received.
Returns
Number of bits of the response.

◆ ApplicationGetUidFunc

void(* ConfigurationType::ApplicationGetUidFunc) (ConfigurationUidType Uid)

Writes the UID for the current configuration to the given buffer.

Parameters
UidThe target buffer.

◆ ApplicationSetUidFunc

void(* ConfigurationType::ApplicationSetUidFunc) (ConfigurationUidType Uid)

Writes a given UID to the current configuration.

Parameters
UidThe source buffer.

◆ MemorySize

uint16_t ConfigurationType::MemorySize

Defines how many space the configuration needs. For emulating configurations this is the memory space of the emulated card.

Note
For reader or sniff configurations this is set to zero.

◆ UidSize

uint8_t ConfigurationType::UidSize

Defines the size of the UID for emulating configurations.

Note
For reader or sniff configurations this is set to zero.

◆ ReadOnly

bool ConfigurationType::ReadOnly

Implies whether the Memory can be changed.

◆ TagFamily

uint8_t ConfigurationType::TagFamily

Specify tag family - see the defines above.