1 /* CM5121 backend for 'internal' CCID driver */
6 #include <librfid/rfid_asic.h>
8 #include "ccid/ccid-driver.h"
10 /* this is the sole function required by rfid_reader_cm5121.c */
12 PC_to_RDR_Escape(void *handle,
13 const unsigned char *tx_buf, unsigned int tx_len,
14 unsigned char *rx_buf, unsigned int *rx_len)
17 ccid_driver_t ch = handle;
18 size_t maxrxlen = *rx_len;
20 rc = ccid_transceive_escape (ch, tx_buf, tx_len,
21 rx_buf, maxrxlen, rx_len);
26 int cm5121_source_init(struct rfid_asic_transport_handle *rath)
30 rc = ccid_open_reader(&rath->data, NULL);
32 fprintf (stderr, "failed to open CCID reader: %#x\n", rc);