![]() |
STM8L libraries for CR95HF 1.0
|
Functions | |
u8 | CR95HF_FieldOff (CR95HF_Protocol_Config *Protocol_Settings) |
This function swithes the RF Field Off using the protocol select comand. | |
u8 | CR95HF_SendEOF (CR95HF_ResponseReceiving *Response) |
This function sends an End Of Frame. This can be used for instance in ISO15693 inventory command or write command. Right after the EOF the tag could answer a command (Write or Inventory), so the response is received and written into the structure provided. | |
u8 | CR95HF_Tagdet (const u8 DacDataL, const u8 DacDataH) |
The purpose of this function is to perform the detector calibration according to the Application Note : AN3433 Tag Detection Calibration Process. | |
u8 | CR95HF_Wait_Wake_up_from_Idle (CR95HF_ResponseReceiving *CR95HF_Response_Idle, CR95HF_Idle_Config *Idle_Config, u8 Number_of_DELAY_BEFORE_TIMEOUT_250MS) |
The purpose of this function is to wait for CR95HF exiting the idle mode and retrieve what caused the wake-up. The method proposed is to wait for the CR95HF answer and then to send several echo command in order to resume communication and clear the fifo stack. Note that this function waits for CR95HF wakes up on its own (internal timer, tag detection), after this function the CR95HF_Wake_up_CR95HF fucntion may be called to wake up the CR95HF with NNS or IRQ_in interrupt. | |
u8 | CR95HF_Wake_up_CR95HF (CR95HF_Idle_Config *Idle_Config) |
The purpose of this function is to avoid getting stuck when the CR95HF exists idle mode. The method proposed is to send several echo command in order to resume communication and clear the fifo stack. |
u8 CR95HF_FieldOff | ( | CR95HF_Protocol_Config * | Protocol_Settings | ) |
This function swithes the RF Field Off using the protocol select comand.
Protocol_Settings | : structure to update at the end of the command containing last protocol selected and parameters |
CR95HF_SUCCESS_CODE | : The fied was successsfully turned off |
CR95HF_ERROR_INVALID_PROTOCOL | : The protocol selected is wrong |
CR95HF_ERROR_INVALID_CMD_LENGTH | : The command length is invalid |
CR95HF_ERROR_CODE,: | unsuccessful command |
u8 CR95HF_SendEOF | ( | CR95HF_ResponseReceiving * | Response | ) |
This function sends an End Of Frame. This can be used for instance in ISO15693 inventory command or write command. Right after the EOF the tag could answer a command (Write or Inventory), so the response is received and written into the structure provided.
Response,: | pointer on the structure which will contain the Tag answer |
CR95HF_SUCCESS_CODE | : The command is successful |
CR95HF_ERROR_CODE | unsuccessful command |
u8 CR95HF_Tagdet | ( | const u8 | DacDataL, |
const u8 | DacDataH | ||
) |
The purpose of this function is to perform the detector calibration according to the Application Note : AN3433 Tag Detection Calibration Process.
DacDataL | : Lower comparing value for tag detection |
DacDataH | : Higher comparing value for tag detection |
CR95HF_SUCCESS_CODE | : command succeed |
CR95HF_ERROR_CODE | : command failed |
u8 CR95HF_Wait_Wake_up_from_Idle | ( | CR95HF_ResponseReceiving * | CR95HF_Response_Idle, |
CR95HF_Idle_Config * | Idle_Config, | ||
u8 | Number_of_DELAY_BEFORE_TIMEOUT_250MS | ||
) |
The purpose of this function is to wait for CR95HF exiting the idle mode and retrieve what caused the wake-up. The method proposed is to wait for the CR95HF answer and then to send several echo command in order to resume communication and clear the fifo stack. Note that this function waits for CR95HF wakes up on its own (internal timer, tag detection), after this function the CR95HF_Wake_up_CR95HF fucntion may be called to wake up the CR95HF with NNS or IRQ_in interrupt.
CR95HF_Response_Idle | : pointer to store the response |
Idle_Config | : pointer on thr structure to update with the new last reason of wake up |
Number_of_DELAY_BEFORE_TIMEOUT_250MS | : number of period of 250ms duration to wait before aborting the procedure. |
EXIT_COMMUNICATION_OK | (CR95HF_SUCCESS_CODE): communication is possible |
EXIT_COMMUNICATION_TIMEOUT | : communication is not possible |
u8 CR95HF_Wake_up_CR95HF | ( | CR95HF_Idle_Config * | Idle_Config | ) |
The purpose of this function is to avoid getting stuck when the CR95HF exists idle mode. The method proposed is to send several echo command in order to resume communication and clear the fifo stack.
Idle_Config | : contains the wake up condition |
CR95HF_SUCCESS_CODE,: | the CR95HF woke up, communication is possible |
CR95HF_ERROR_CODE | : fail to wake up the CR95HF, either the CR95HF waits for another event (tag detection, timer) or communication cannot be resumed. |