From 67d9be99569c49671b4cc2217824307202b92439 Mon Sep 17 00:00:00 2001 From: henryk Date: Mon, 3 Dec 2007 04:48:43 +0000 Subject: Fix copy and paste error in prefill_buffer (Add debug output in main loop) git-svn-id: https://svn.openpcd.org:2342/trunk@365 6dc7ffe9-61d6-0310-9af1-9938baff3ed1 --- openpicc/application/iso14443_layer3a.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'openpicc/application') diff --git a/openpicc/application/iso14443_layer3a.c b/openpicc/application/iso14443_layer3a.c index e412760..7694feb 100644 --- a/openpicc/application/iso14443_layer3a.c +++ b/openpicc/application/iso14443_layer3a.c @@ -107,7 +107,7 @@ static int prefill_buffer(ssc_dma_tx_buffer_t *dest, const iso14443_frame *src) dest->len = sizeof(ssc_tx_buffer.data); int ret = manchester_encode(dest->data, dest->len, - &ATQA_FRAME); + src); if(ret>0) { dest->len = ret; portENTER_CRITICAL(); @@ -203,6 +203,13 @@ void iso14443_layer3a_state_machine (void *pvParameters) case POWERED_OFF: if(switch_on == 1) { if(prefill_buffer(&ssc_tx_buffer, &ATQA_FRAME)) { + LAYER3_DEBUG("Buffer prefilled\n\r"); + DumpUIntToUSB(ssc_tx_buffer.state); + DumpStringToUSB(" "); + DumpUIntToUSB((unsigned int)ssc_tx_buffer.source); + DumpStringToUSB(" "); + DumpUIntToUSB((unsigned int)&ATQA_FRAME); + DumpStringToUSB("\n\r"); state=INITIAL_STATE; if(INITIAL_STATE == IDLE) ssc_rx_mode_set(SSC_MODE_14443A_SHORT); -- cgit v1.2.3