summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorlaforge <laforge@e0336214-984f-0b4b-a45f-81c69e1f0ede>2006-06-13 09:55:09 +0000
committerlaforge <laforge@e0336214-984f-0b4b-a45f-81c69e1f0ede>2006-06-13 09:55:09 +0000
commit2e5b78aa3beb31e5d9d83e693c59671faebfc932 (patch)
treec56580d518df09302ae432fb46d9f3e6cc882eb1 /src
parentaeb513680eccb0aa4062f63d7b5ae7725d83b848 (diff)
s/transcieve/transceive/g (Henryk Ploetz)
git-svn-id: https://svn.gnumonks.org/trunk/librfid@1817 e0336214-984f-0b4b-a45f-81c69e1f0ede
Diffstat (limited to 'src')
-rw-r--r--src/rc632.h2
-rw-r--r--src/rfid_asic_rc632.c34
-rw-r--r--src/rfid_layer2.c6
-rw-r--r--src/rfid_layer2_iso14443a.c28
-rw-r--r--src/rfid_layer2_iso14443b.c22
-rw-r--r--src/rfid_layer2_iso15693.c30
-rw-r--r--src/rfid_proto_mifare_classic.c4
-rw-r--r--src/rfid_proto_mifare_ul.c6
-rw-r--r--src/rfid_proto_tcl.c22
-rw-r--r--src/rfid_protocol.c4
-rw-r--r--src/rfid_reader.c4
-rw-r--r--src/rfid_reader_cm5121.c18
12 files changed, 90 insertions, 90 deletions
diff --git a/src/rc632.h b/src/rc632.h
index 977b0ee..f207661 100644
--- a/src/rc632.h
+++ b/src/rc632.h
@@ -79,7 +79,7 @@ enum rc632_reg_command {
RC632_CMD_RECEIVE = 0x16,
RC632_CMD_LOAD_KEY = 0x19,
RC632_CMD_TRANSMIT = 0x1a,
- RC632_CMD_TRANSCIEVE = 0x1e,
+ RC632_CMD_TRANSCEIVE = 0x1e,
RC632_CMD_STARTUP = 0x3f,
};
diff --git a/src/rfid_asic_rc632.c b/src/rfid_asic_rc632.c
index 0d4a0c4..6f42208 100644
--- a/src/rfid_asic_rc632.c
+++ b/src/rfid_asic_rc632.c
@@ -229,7 +229,7 @@ tcl_toggle_pcb(struct rfid_asic_handle *handle)
}
static int
-rc632_transcieve(struct rfid_asic_handle *handle,
+rc632_transceive(struct rfid_asic_handle *handle,
const u_int8_t *tx_buf,
u_int8_t tx_len,
u_int8_t *rx_buf,
@@ -243,7 +243,7 @@ rc632_transcieve(struct rfid_asic_handle *handle,
if (ret < 0)
return ret;
- ret = rc632_reg_write(handle, RC632_REG_COMMAND, RC632_CMD_TRANSCIEVE);
+ ret = rc632_reg_write(handle, RC632_REG_COMMAND, RC632_CMD_TRANSCEIVE);
if (ret < 0)
return ret;
@@ -581,7 +581,7 @@ rc632_iso14443a_fini(struct iso14443a_handle *handle_14443)
/* issue a 14443-3 A PCD -> PICC command in a short frame, such as REQA, WUPA */
static int
-rc632_iso14443a_transcieve_sf(struct rfid_asic_handle *handle,
+rc632_iso14443a_transceive_sf(struct rfid_asic_handle *handle,
u_int8_t cmd,
struct iso14443a_atqa *atqa)
{
@@ -615,10 +615,10 @@ rc632_iso14443a_transcieve_sf(struct rfid_asic_handle *handle,
if (ret < 0)
return ret;
- ret = rc632_transcieve(handle, tx_buf, sizeof(tx_buf),
+ ret = rc632_transceive(handle, tx_buf, sizeof(tx_buf),
(u_int8_t *)atqa, &rx_len, 0x32, 0);
if (ret < 0) {
- DEBUGP("error during rc632_transcieve()\n");
+ DEBUGP("error during rc632_transceive()\n");
return ret;
}
@@ -635,9 +635,9 @@ rc632_iso14443a_transcieve_sf(struct rfid_asic_handle *handle,
return 0;
}
-/* transcieve regular frame */
+/* transceive regular frame */
static int
-rc632_iso14443ab_transcieve(struct rfid_asic_handle *handle,
+rc632_iso14443ab_transceive(struct rfid_asic_handle *handle,
unsigned int frametype,
const u_int8_t *tx_buf, unsigned int tx_len,
u_int8_t *rx_buf, unsigned int *rx_len,
@@ -673,7 +673,7 @@ rc632_iso14443ab_transcieve(struct rfid_asic_handle *handle,
if (ret < 0)
return ret;
- ret = rc632_transcieve(handle, tx_buf, tx_len, rx_buf, &rxl, 0x32, 0);
+ ret = rc632_transceive(handle, tx_buf, tx_len, rx_buf, &rxl, 0x32, 0);
*rx_len = rxl;
if (ret < 0)
return ret;
@@ -682,9 +682,9 @@ rc632_iso14443ab_transcieve(struct rfid_asic_handle *handle,
return 0;
}
-/* transcieve anti collission bitframe */
+/* transceive anti collission bitframe */
static int
-rc632_iso14443a_transcieve_acf(struct rfid_asic_handle *handle,
+rc632_iso14443a_transceive_acf(struct rfid_asic_handle *handle,
struct iso14443a_anticol_cmd *acf,
unsigned int *bit_of_col)
{
@@ -730,7 +730,7 @@ rc632_iso14443a_transcieve_acf(struct rfid_asic_handle *handle,
if (ret < 0)
return ret;
- ret = rc632_transcieve(handle, (u_int8_t *)acf, tx_bytes,
+ ret = rc632_transceive(handle, (u_int8_t *)acf, tx_bytes,
rx_buf, &rx_len, 0x32, 0);
if (ret < 0)
return ret;
@@ -1371,9 +1371,9 @@ rc632_mifare_auth(struct rfid_asic_handle *h, u_int8_t cmd, u_int32_t serno,
}
-/* transcieve regular frame */
+/* transceive regular frame */
static int
-rc632_mifare_transcieve(struct rfid_asic_handle *handle,
+rc632_mifare_transceive(struct rfid_asic_handle *handle,
const u_int8_t *tx_buf, unsigned int tx_len,
u_int8_t *rx_buf, unsigned int *rx_len,
u_int64_t timeout, unsigned int flags)
@@ -1397,7 +1397,7 @@ rc632_mifare_transcieve(struct rfid_asic_handle *handle,
if (ret < 0)
return ret;
- ret = rc632_transcieve(handle, tx_buf, tx_len, rx_buf, &rxl, 0x32, 0);
+ ret = rc632_transceive(handle, tx_buf, tx_len, rx_buf, &rxl, 0x32, 0);
*rx_len = rxl;
if (ret < 0)
return ret;
@@ -1415,11 +1415,11 @@ struct rfid_asic rc632 = {
.power_down = &rc632_power_down,
.turn_on_rf = &rc632_turn_on_rf,
.turn_off_rf = &rc632_turn_off_rf,
- .transcieve = &rc632_iso14443ab_transcieve,
+ .transceive = &rc632_iso14443ab_transceive,
.iso14443a = {
.init = &rc632_iso14443a_init,
- .transcieve_sf = &rc632_iso14443a_transcieve_sf,
- .transcieve_acf = &rc632_iso14443a_transcieve_acf,
+ .transceive_sf = &rc632_iso14443a_transceive_sf,
+ .transceive_acf = &rc632_iso14443a_transceive_acf,
.set_speed = &rc632_iso14443a_set_speed,
},
.iso14443b = {
diff --git a/src/rfid_layer2.c b/src/rfid_layer2.c
index 8d1544a..eef0560 100644
--- a/src/rfid_layer2.c
+++ b/src/rfid_layer2.c
@@ -49,16 +49,16 @@ rfid_layer2_open(struct rfid_layer2_handle *ph)
}
int
-rfid_layer2_transcieve(struct rfid_layer2_handle *ph,
+rfid_layer2_transceive(struct rfid_layer2_handle *ph,
enum rfid_frametype frametype,
const unsigned char *tx_buf, unsigned int len,
unsigned char *rx_buf, unsigned int *rx_len,
u_int64_t timeout, unsigned int flags)
{
- if (!ph->l2->fn.transcieve)
+ if (!ph->l2->fn.transceive)
return -EIO;
- return ph->l2->fn.transcieve(ph, frametype, tx_buf, len, rx_buf,
+ return ph->l2->fn.transceive(ph, frametype, tx_buf, len, rx_buf,
rx_len, timeout, flags);
}
diff --git a/src/rfid_layer2_iso14443a.c b/src/rfid_layer2_iso14443a.c
index da2628f..839cffe 100644
--- a/src/rfid_layer2_iso14443a.c
+++ b/src/rfid_layer2_iso14443a.c
@@ -31,37 +31,37 @@
#define TIMEOUT 1236
-/* Transcieve a 7-bit short frame */
+/* Transceive a 7-bit short frame */
static int
-iso14443a_transcieve_sf(struct rfid_layer2_handle *handle,
+iso14443a_transceive_sf(struct rfid_layer2_handle *handle,
unsigned char cmd,
struct iso14443a_atqa *atqa)
{
struct rfid_reader *rdr = handle->rh->reader;
- return rdr->iso14443a.transcieve_sf(handle->rh, cmd, atqa);
+ return rdr->iso14443a.transceive_sf(handle->rh, cmd, atqa);
}
/* Transmit an anticollission bit frame */
static int
-iso14443a_transcieve_acf(struct rfid_layer2_handle *handle,
+iso14443a_transceive_acf(struct rfid_layer2_handle *handle,
struct iso14443a_anticol_cmd *acf,
unsigned int *bit_of_col)
{
struct rfid_reader *rdr = handle->rh->reader;
- return rdr->iso14443a.transcieve_acf(handle->rh, acf, bit_of_col);
+ return rdr->iso14443a.transceive_acf(handle->rh, acf, bit_of_col);
}
/* Transmit a regular frame */
static int
-iso14443a_transcieve(struct rfid_layer2_handle *handle,
+iso14443a_transceive(struct rfid_layer2_handle *handle,
enum rfid_frametype frametype,
const unsigned char *tx_buf, unsigned int tx_len,
unsigned char *rx_buf, unsigned int *rx_len,
u_int64_t timeout, unsigned int flags)
{
- return handle->rh->reader->transcieve(handle->rh, frametype, tx_buf,
+ return handle->rh->reader->transceive(handle->rh, frametype, tx_buf,
tx_len, rx_buf, rx_len, timeout, flags);
}
@@ -111,10 +111,10 @@ iso14443a_anticol(struct rfid_layer2_handle *handle)
memset(&atqa, 0, sizeof(atqa));
memset(&acf, 0, sizeof(acf));
- ret = iso14443a_transcieve_sf(handle, ISO14443A_SF_CMD_REQA, &atqa);
+ ret = iso14443a_transceive_sf(handle, ISO14443A_SF_CMD_REQA, &atqa);
if (ret < 0) {
h->state = ISO14443A_STATE_REQA_SENT;
- DEBUGP("error during transcieve_sf: %d\n", ret);
+ DEBUGP("error during transceive_sf: %d\n", ret);
return ret;
}
h->state = ISO14443A_STATE_ATQA_RCVD;
@@ -142,7 +142,7 @@ iso14443a_anticol(struct rfid_layer2_handle *handle)
cascade:
iso14443a_code_nvb_bits(&acf.nvb, 16);
- ret = iso14443a_transcieve_acf(handle, &acf, &bit_of_col);
+ ret = iso14443a_transceive_acf(handle, &acf, &bit_of_col);
if (ret < 0)
return ret;
DEBUGP("bit_of_col = %u\n", bit_of_col);
@@ -150,14 +150,14 @@ cascade:
while (bit_of_col != ISO14443A_BITOFCOL_NONE) {
set_bit_in_field(&acf.uid_bits[0], bit_of_col-16);
iso14443a_code_nvb_bits(&acf.nvb, bit_of_col);
- ret = iso14443a_transcieve_acf(handle, &acf, &bit_of_col);
+ ret = iso14443a_transceive_acf(handle, &acf, &bit_of_col);
DEBUGP("bit_of_col = %u\n", bit_of_col);
if (ret < 0)
return ret;
}
iso14443a_code_nvb_bits(&acf.nvb, 7*8);
- ret = iso14443a_transcieve(handle, RFID_14443A_FRAME_REGULAR,
+ ret = iso14443a_transceive(handle, RFID_14443A_FRAME_REGULAR,
(unsigned char *)&acf, 7,
(unsigned char *) &sak, &rx_len,
TIMEOUT, 0);
@@ -241,7 +241,7 @@ iso14443a_hlta(struct rfid_layer2_handle *handle)
unsigned char rx_buf[10];
unsigned int rx_len = sizeof(rx_buf);
- ret = iso14443a_transcieve(handle, RFID_14443A_FRAME_REGULAR,
+ ret = iso14443a_transceive(handle, RFID_14443A_FRAME_REGULAR,
tx_buf, sizeof(tx_buf),
rx_buf, &rx_len, 1000 /* 1ms */, 0);
if (ret < 0) {
@@ -314,7 +314,7 @@ struct rfid_layer2 rfid_layer2_iso14443a = {
.fn = {
.init = &iso14443a_init,
.open = &iso14443a_anticol,
- .transcieve = &iso14443a_transcieve,
+ .transceive = &iso14443a_transceive,
.close = &iso14443a_hlta,
.fini = &iso14443a_fini,
.setopt = &iso14443a_setopt,
diff --git a/src/rfid_layer2_iso14443b.c b/src/rfid_layer2_iso14443b.c
index 7c92562..454df0a 100644
--- a/src/rfid_layer2_iso14443b.c
+++ b/src/rfid_layer2_iso14443b.c
@@ -114,13 +114,13 @@ send_reqb(struct rfid_layer2_handle *h, unsigned char afi,
if (is_wup)
reqb[2] |= 0x08;
- ret = h->rh->reader->transcieve(h->rh, RFID_14443B_FRAME_REGULAR,
+ ret = h->rh->reader->transceive(h->rh, RFID_14443B_FRAME_REGULAR,
reqb, sizeof(reqb),
(unsigned char *)&atqb,
&atqb_len, ATQB_TIMEOUT, 0);
h->priv.iso14443b.state = ISO14443B_STATE_REQB_SENT;
if (ret < 0) {
- DEBUGP("error during transcieve of REQB/WUBP\n");
+ DEBUGP("error during transceive of REQB/WUBP\n");
continue;
}
@@ -152,7 +152,7 @@ static inline unsigned int mbli_to_mbl(struct rfid_layer2_handle *h,
}
static int
-transcieve_attrib(struct rfid_layer2_handle *h, const unsigned char *inf,
+transceive_attrib(struct rfid_layer2_handle *h, const unsigned char *inf,
unsigned int inf_len, unsigned char *rx_data, unsigned int *rx_len)
{
struct iso14443b_attrib_hdr *attrib;
@@ -200,14 +200,14 @@ transcieve_attrib(struct rfid_layer2_handle *h, const unsigned char *inf,
attrib->param3.protocol_type = 0x1;
*rx_len = *rx_len + 1;
- ret = h->rh->reader->transcieve(h->rh, RFID_14443B_FRAME_REGULAR,
+ ret = h->rh->reader->transceive(h->rh, RFID_14443B_FRAME_REGULAR,
(unsigned char *) attrib,
sizeof(*attrib)+inf_len,
rx_buf, rx_len, h->priv.iso14443b.fwt,
0);
h->priv.iso14443b.state = ISO14443B_STATE_ATTRIB_SENT;
if (ret < 0) {
- DEBUGP("transcieve problem\n");
+ DEBUGP("transceive problem\n");
goto out_rx;
}
@@ -244,13 +244,13 @@ iso14443b_hltb(struct rfid_layer2_handle *h)
hltb[0] = 0x50;
memcpy(hltb+1, h->uid, 4);
- ret = h->rh->reader->transcieve(h->rh, RFID_14443B_FRAME_REGULAR,
+ ret = h->rh->reader->transceive(h->rh, RFID_14443B_FRAME_REGULAR,
hltb, 5,
hltb_resp, &hltb_len,
h->priv.iso14443b.fwt, 0);
h->priv.iso14443b.state = ISO14443B_STATE_HLTB_SENT;
if (ret < 0) {
- DEBUGP("transcieve problem\n");
+ DEBUGP("transceive problem\n");
return ret;
}
@@ -275,7 +275,7 @@ iso14443b_anticol(struct rfid_layer2_handle *handle)
if (ret < 0)
return ret;
- ret = transcieve_attrib(handle, NULL, 0, buf, &buf_len);
+ ret = transceive_attrib(handle, NULL, 0, buf, &buf_len);
if (ret < 0)
return ret;
@@ -319,14 +319,14 @@ iso14443b_fini(struct rfid_layer2_handle *handle)
}
static int
-iso14443b_transcieve(struct rfid_layer2_handle *handle,
+iso14443b_transceive(struct rfid_layer2_handle *handle,
enum rfid_frametype frametype,
const unsigned char *tx_buf, unsigned int tx_len,
unsigned char *rx_buf, unsigned int *rx_len,
u_int64_t timeout, unsigned int flags)
{
DEBUGP("transcieving %u bytes, expecting max %u\n", tx_len, *rx_len);
- return handle->rh->reader->transcieve(handle->rh, frametype,
+ return handle->rh->reader->transceive(handle->rh, frametype,
tx_buf, tx_len,
rx_buf, rx_len, timeout, flags);
}
@@ -337,7 +337,7 @@ struct rfid_layer2 rfid_layer2_iso14443b = {
.fn = {
.init = &iso14443b_init,
.open = &iso14443b_anticol,
- .transcieve = &iso14443b_transcieve,
+ .transceive = &iso14443b_transceive,
.close = &iso14443b_hltb,
.fini = &iso14443b_fini,
},
diff --git a/src/rfid_layer2_iso15693.c b/src/rfid_layer2_iso15693.c
index 1a93a19..8c5d808 100644
--- a/src/rfid_layer2_iso15693.c
+++ b/src/rfid_layer2_iso15693.c
@@ -29,36 +29,36 @@
#include <librfid/rfid_layer2_iso15693.h>
#if 0
-/* Transcieve a 7-bit short frame */
+/* Transceive a 7-bit short frame */
static int
-iso14443a_transcieve_sf(struct rfid_layer2_handle *handle,
+iso14443a_transceive_sf(struct rfid_layer2_handle *handle,
unsigned char cmd,
struct iso14443a_atqa *atqa)
{
struct rfid_reader *rdr = handle->rh->reader;
- return rdr->iso14443a.transcieve_sf(handle->rh, cmd, atqa);
+ return rdr->iso14443a.transceive_sf(handle->rh, cmd, atqa);
}
/* Transmit an anticollission bit frame */
static int
-iso14443a_transcieve_acf(struct rfid_layer2_handle *handle,
+iso14443a_transceive_acf(struct rfid_layer2_handle *handle,
struct iso14443a_anticol_cmd *acf,
unsigned int *bit_of_col)
{
struct rfid_reader *rdr = handle->rh->reader;
- return rdr->iso14443a.transcieve_acf(handle->rh, acf, bit_of_col);
+ return rdr->iso14443a.transceive_acf(handle->rh, acf, bit_of_col);
}
/* Transmit a regular frame */
static int
-iso14443a_transcieve(struct rfid_layer2_handle *handle,
+iso14443a_transceive(struct rfid_layer2_handle *handle,
const unsigned char *tx_buf, unsigned int tx_len,
unsigned char *rx_buf, unsigned int *rx_len,
u_int64_t, unsigned int flags)
{
- return handle->rh->reader->transcieve(handle->rh, tx_buf, tx_len,
+ return handle->rh->reader->transceive(handle->rh, tx_buf, tx_len,
rx_buf, rx_len, timeout, flags);
}
@@ -111,16 +111,16 @@ iso14443a_anticol(struct rfid_layer2_handle *handle)
if (first == 0) {
DEBUGP("Sending REQA\n");
- ret = iso14443a_transcieve_sf(handle, ISO14443A_SF_CMD_REQA, &atqa);
+ ret = iso14443a_transceive_sf(handle, ISO14443A_SF_CMD_REQA, &atqa);
first = 1;
} else {
DEBUGP("Sending WUPA\n");
- ret = iso14443a_transcieve_sf(handle, ISO14443A_SF_CMD_WUPA, &atqa);
+ ret = iso14443a_transceive_sf(handle, ISO14443A_SF_CMD_WUPA, &atqa);
}
if (ret < 0) {
handle->priv.iso14443a.state = ISO14443A_STATE_REQA_SENT;
- DEBUGP("error during transcieve_sf: %d\n", ret);
+ DEBUGP("error during transceive_sf: %d\n", ret);
return ret;
}
handle->priv.iso14443a.state = ISO14443A_STATE_ATQA_RCVD;
@@ -148,7 +148,7 @@ iso14443a_anticol(struct rfid_layer2_handle *handle)
cascade:
iso14443a_code_nvb_bits(&acf.nvb, 16);
- ret = iso14443a_transcieve_acf(handle, &acf, &bit_of_col);
+ ret = iso14443a_transceive_acf(handle, &acf, &bit_of_col);
if (ret < 0)
return ret;
DEBUGP("bit_of_col = %u\n", bit_of_col);
@@ -156,14 +156,14 @@ cascade:
while (bit_of_col != ISO14443A_BITOFCOL_NONE) {
set_bit_in_field(&acf.uid_bits[0], bit_of_col-16);
iso14443a_code_nvb_bits(&acf.nvb, bit_of_col);
- ret = iso14443a_transcieve_acf(handle, &acf, &bit_of_col);
+ ret = iso14443a_transceive_acf(handle, &acf, &bit_of_col);
DEBUGP("bit_of_col = %u\n", bit_of_col);
if (ret < 0)
return ret;
}
iso14443a_code_nvb_bits(&acf.nvb, 7*8);
- ret = iso14443a_transcieve(handle, (unsigned char *)&acf, 7,
+ ret = iso14443a_transceive(handle, (unsigned char *)&acf, 7,
(unsigned char *) &sak, &rx_len,
TIMEOUT, 0);
if (ret < 0)
@@ -249,7 +249,7 @@ iso14443a_hlta(struct rfid_layer2_handle *handle)
return 0;
- ret = iso14443a_transcieve(handle, tx_buf, sizeof(tx_buf),
+ ret = iso14443a_transceive(handle, tx_buf, sizeof(tx_buf),
rx_buf, &rx_len, 1000 /* 1ms */, 0);
if (ret < 0) {
/* "error" case: we don't get somethng back from the card */
@@ -294,7 +294,7 @@ struct rfid_layer2 rfid_layer2_iso15693 = {
.fn = {
.init = &iso15693_init,
//.open = &iso15693_anticol,
- //.transcieve = &iso15693_transcieve,
+ //.transceive = &iso15693_transceive,
//.close = &iso14443a_hlta,
.fini = &iso15693_fini,
},
diff --git a/src/rfid_proto_mifare_classic.c b/src/rfid_proto_mifare_classic.c
index e2ee80c..5d2b3ff 100644
--- a/src/rfid_proto_mifare_classic.c
+++ b/src/rfid_proto_mifare_classic.c
@@ -57,7 +57,7 @@ mfcl_read(struct rfid_protocol_handle *ph, unsigned int page,
tx[0] = MIFARE_CL_CMD_READ;
tx[1] = page & 0xff;
- ret = rfid_layer2_transcieve(ph->l2h, RFID_MIFARE_FRAME, tx,
+ ret = rfid_layer2_transceive(ph->l2h, RFID_MIFARE_FRAME, tx,
sizeof(tx), rx_buf, &real_rx_len,
MIFARE_CL_READ_FWT, 0);
@@ -93,7 +93,7 @@ mfcl_write(struct rfid_protocol_handle *ph, unsigned int page,
memcpy(tx+2, tx_data, 16);
- ret = rfid_layer2_transcieve(ph->l2h, RFID_MIFARE_FRAME, tx,
+ ret = rfid_layer2_transceive(ph->l2h, RFID_MIFARE_FRAME, tx,
sizeof(tx), rx, &rx_len,
MIFARE_CL_WRITE_FWT, 0);
diff --git a/src/rfid_proto_mifare_ul.c b/src/rfid_proto_mifare_ul.c
index 747f38c..5de050d 100644
--- a/src/rfid_proto_mifare_ul.c
+++ b/src/rfid_proto_mifare_ul.c
@@ -52,7 +52,7 @@ mful_read(struct rfid_protocol_handle *ph, unsigned int page,
tx[0] = MIFARE_UL_CMD_READ;
tx[1] = page & 0xff;
- ret = rfid_layer2_transcieve(ph->l2h, RFID_14443A_FRAME_REGULAR,
+ ret = rfid_layer2_transceive(ph->l2h, RFID_14443A_FRAME_REGULAR,
tx, sizeof(tx), rx_buf,
&real_rx_len, MIFARE_UL_READ_FWT, 0);
@@ -86,7 +86,7 @@ mful_write(struct rfid_protocol_handle *ph, unsigned int page,
for (i = 0; i < 4; i++)
tx[2+i] = tx_data[i];
- ret = rfid_layer2_transcieve(ph->l2h, RFID_14443A_FRAME_REGULAR,
+ ret = rfid_layer2_transceive(ph->l2h, RFID_14443A_FRAME_REGULAR,
tx, sizeof(tx), rx, &rx_len,
MIFARE_UL_WRITE_FWT, 0);
@@ -100,7 +100,7 @@ mful_write(struct rfid_protocol_handle *ph, unsigned int page,
}
static int
-mful_transcieve(struct rfid_protocol_handle *ph,
+mful_transceive(struct rfid_protocol_handle *ph,
const unsigned char *tx_data, unsigned int tx_len,
unsigned char *rx_data, unsigned int *rx_len,
unsigned int timeout, unsigned int flags)
diff --git a/src/rfid_proto_tcl.c b/src/rfid_proto_tcl.c
index 901e42c..66f1edd 100644
--- a/src/rfid_proto_tcl.c
+++ b/src/rfid_proto_tcl.c
@@ -176,13 +176,13 @@ tcl_request_ats(struct rfid_protocol_handle *h)
rats[0] = 0xe0;
rats[1] = (h->priv.tcl.cid & 0x0f) | ((fsdi << 4) & 0xf0);
- /* transcieve (with CRC) */
- ret = rfid_layer2_transcieve(h->l2h, RFID_14443A_FRAME_REGULAR,
+ /* transceive (with CRC) */
+ ret = rfid_layer2_transceive(h->l2h, RFID_14443A_FRAME_REGULAR,
rats, 2, h->priv.tcl.ats,
&h->priv.tcl.ats_len, activation_fwt(h),
TCL_TRANSP_F_TX_CRC);
if (ret < 0) {
- DEBUGP("transcieve of rats failed\n");
+ DEBUGP("transceive of rats failed\n");
h->priv.tcl.state = TCL_STATE_RATS_SENT;
/* FIXME: retransmit */
return ret;
@@ -279,7 +279,7 @@ tcl_do_pps(struct rfid_protocol_handle *h)
ppss[2] = (ppss[2] & 0xf0) | (DrI | DsI << 2);
- ret = rfid_layer2_transcieve(h->l2h, RFID_14443A_FRAME_REGULAR,
+ ret = rfid_layer2_transceive(h->l2h, RFID_14443A_FRAME_REGULAR,
ppss, 3, pps_response, &rx_len,
h->priv.tcl.fwt, TCL_TRANSP_F_TX_CRC);
if (ret < 0)
@@ -478,7 +478,7 @@ tcl_deselect(struct rfid_protocol_handle *h)
if (ret < 0)
return ret;
- ret = rfid_layer2_transcieve(h->l2h, RFID_14443A_FRAME_REGULAR,
+ ret = rfid_layer2_transceive(h->l2h, RFID_14443A_FRAME_REGULAR,
frame, prlg_len, rx,
&rx_len, deactivation_fwt(h),
TCL_TRANSP_F_TX_CRC);
@@ -497,7 +497,7 @@ tcl_deselect(struct rfid_protocol_handle *h)
#define is_i_block(x) ((x & 0xc0) == 0x00)
static int
-tcl_transcieve(struct rfid_protocol_handle *h,
+tcl_transceive(struct rfid_protocol_handle *h,
const unsigned char *tx_data, unsigned int tx_len,
unsigned char *rx_data, unsigned int *rx_len,
unsigned int timeout, unsigned int flags)
@@ -547,10 +547,10 @@ tcl_transcieve(struct rfid_protocol_handle *h,
*rx_len = 0;
do_tx:
- ret = rfid_layer2_transcieve(h->l2h, l2_to_frame(h->l2h->l2->id),
+ ret = rfid_layer2_transceive(h->l2h, l2_to_frame(h->l2h->l2->id),
_tx, _tx_len,
rx_buf, &_rx_len, _timeout, 0);
- DEBUGP("l2 transcieve finished\n");
+ DEBUGP("l2 transceive finished\n");
if (ret < 0)
goto out_rxb;
@@ -629,8 +629,8 @@ do_tx:
_tx_len = prlg_len+1;
_timeout = th->fwt * inf;
- /* start over with next transcieve */
- goto do_tx; /* FIXME: do transcieve locally since we use
+ /* start over with next transceive */
+ goto do_tx; /* FIXME: do transceive locally since we use
totally different buffer */
} else if (is_i_block(*rx_buf)) {
@@ -713,7 +713,7 @@ struct rfid_protocol rfid_protocol_tcl = {
.fn = {
.init = &tcl_init,
.open = &tcl_connect,
- .transcieve = &tcl_transcieve,
+ .transceive = &tcl_transceive,
.close = &tcl_deselect,
.fini = &tcl_fini,
},
diff --git a/src/rfid_protocol.c b/src/rfid_protocol.c
index c401a2c..46dc48d 100644
--- a/src/rfid_protocol.c
+++ b/src/rfid_protocol.c
@@ -57,12 +57,12 @@ rfid_protocol_open(struct rfid_protocol_handle *ph)
}
int
-rfid_protocol_transcieve(struct rfid_protocol_handle *ph,
+rfid_protocol_transceive(struct rfid_protocol_handle *ph,
const unsigned char *tx_buf, unsigned int len,
unsigned char *rx_buf, unsigned int *rx_len,
unsigned int timeout, unsigned int flags)
{
- return ph->proto->fn.transcieve(ph, tx_buf, len, rx_buf, rx_len,
+ return ph->proto->fn.transceive(ph, tx_buf, len, rx_buf, rx_len,
timeout, flags);
}
diff --git a/src/rfid_reader.c b/src/rfid_reader.c
index 9486cae..f41ae8f 100644
--- a/src/rfid_reader.c
+++ b/src/rfid_reader.c
@@ -39,13 +39,13 @@ rfid_reader_open(void *data, unsigned int id)
}
int
-rfid_reader_transcieve(struct rfid_reader_handle *rh,
+rfid_reader_transceive(struct rfid_reader_handle *rh,
enum rfid_frametype frametype,
const unsigned char *tx_buf, unsigned int len,
unsigned char *rx_buf, unsigned int *rx_len,
u_int64_t timeout, unsigned int flags)
{
- return rh->reader->transcieve(rh, frametype, tx_buf, len, rx_buf,
+ return rh->reader->transceive(rh, frametype, tx_buf, len, rx_buf,
rx_len, timeout, flags);
}
diff --git a/src/rfid_reader_cm5121.c b/src/rfid_reader_cm5121.c
index 2acc267..5affeb5 100644
--- a/src/rfid_reader_cm5121.c
+++ b/src/rfid_reader_cm5121.c
@@ -176,31 +176,31 @@ static int TestFIFO(struct rc632_handle *handle)
}
#endif
-static int cm5121_transcieve(struct rfid_reader_handle *rh,
+static int cm5121_transceive(struct rfid_reader_handle *rh,
enum rfid_frametype frametype,
const unsigned char *tx_data, unsigned int tx_len,
unsigned char *rx_data, unsigned int *rx_len,
u_int64_t timeout, unsigned int flags)
{
- return rh->ah->asic->priv.rc632.fn.transcieve(rh->ah, frametype,
+ return rh->ah->asic->priv.rc632.fn.transceive(rh->ah, frametype,
tx_data, tx_len, rx_data,
rx_len, timeout, flags);
}
-static int cm5121_transcieve_sf(struct rfid_reader_handle *rh,
+static int cm5121_transceive_sf(struct rfid_reader_handle *rh,
unsigned char cmd, struct iso14443a_atqa *atqa)
{
- return rh->ah->asic->priv.rc632.fn.iso14443a.transcieve_sf(rh->ah,
+ return rh->ah->asic->priv.rc632.fn.iso14443a.transceive_sf(rh->ah,
cmd,
atqa);
}
static int
-cm5121_transcieve_acf(struct rfid_reader_handle *rh,
+cm5121_transceive_acf(struct rfid_reader_handle *rh,
struct iso14443a_anticol_cmd *cmd,
unsigned int *bit_of_col)
{
- return rh->ah->asic->priv.rc632.fn.iso14443a.transcieve_acf(rh->ah,
+ return rh->ah->asic->priv.rc632.fn.iso14443a.transceive_acf(rh->ah,
cmd, bit_of_col);
}
@@ -346,11 +346,11 @@ struct rfid_reader rfid_reader_cm5121 = {
.name = "Omnikey CardMan 5121 RFID",
.open = &cm5121_open,
.close = &cm5121_close,
- .transcieve = &cm5121_transcieve,
+ .transceive = &cm5121_transceive,
.iso14443a = {
.init = &cm5121_14443a_init,
- .transcieve_sf = &cm5121_transcieve_sf,
- .transcieve_acf = &cm5121_transcieve_acf,
+ .transceive_sf = &cm5121_transceive_sf,
+ .transceive_acf = &cm5121_transceive_acf,
.speed = RFID_14443A_SPEED_106K | RFID_14443A_SPEED_212K |
RFID_14443A_SPEED_424K, //| RFID_14443A_SPEED_848K,
.set_speed = &cm5121_14443a_set_speed,
personal git repositories of Harald Welte. Your mileage may vary