cancel
Showing results for 
Search instead for 
Did you mean: 

Smartcard mode

ari_v
Associate II
Posted on May 20, 2009 at 04:17

Smartcard mode

17 REPLIES 17
nguyenvanhiep_hd1985
Associate II
Posted on May 17, 2011 at 12:37

Hi Mark,

How can we choose properly value in the Guard Time register with each card ?

Thanks,

nguyenvanhiep_hd1985
Associate II
Posted on May 17, 2011 at 12:37

Hi all,

I have communicated with smartcard. But i have a new problem. When i want to know IMSI of card, i have to send verify command.

I transmitted PIN1 (CHV1) code to smartcard, but i didn't receive a responce

const uint8_t CHV1[8] = { '0', '0', '0', '0', '0', '0', '0', '0'};

          /* Verify CHV1 (PIN1) ------------------------------------------------*/

        SC_ADPU.Header.CLA = SC_CLA_GSM11;

        SC_ADPU.Header.INS = SC_VERIFY;

        SC_ADPU.Header.P1 = 0x00;

        SC_ADPU.Header.P2 = 0x00;

        SC_ADPU.Body.LC = 0x08;

        for(i = 0; i < SC_ADPU.Body.LC; i++)

        {

          SC_ADPU.Body.Data[i] = CHV1[i];

        }

        while(i < LC_MAX)

        {   

          SC_ADPU.Body.Data[i++] = 0;

        }

        SC_ADPU.Body.LE = 0;

        SC_Handler(&SCState, &SC_ADPU, &SC_Responce);

 

 
shopping
Associate II
Posted on September 26, 2014 at 22:14

I have the exact same problem as ari_v. Same peripheral (USART3), same pins, same issue on STM32F4. I've been stuck on this for the past 3 days.

When I send data out (the same data that I'm expecting to receive), it looks exactly like the data coming in, which proves that parity, number of bits and all that is properly configured.

If I disable smart card mode (SCEN), I can receive data just fine (via the RX pin, which I externally tied to TX - tried it with and without this external connection).

Is this another bug in the silicon or just another case of poor documentation?

I'm new to this forum, but I thought ST people are actually reading this stuff. Why has this thing remained unanswered for 5 years?
Posted on September 26, 2014 at 22:51

I'm new to this forum, but I thought ST people are actually reading this stuff. Why has this thing remained unanswered for 5 years?

 

This is a USER forum, and you clearly have a constituency of contributors approaching zero for this issue. Forums work like this, there are 99.99% of participants with issues/problems, and about 0.01% who care.

If you are a commercial client you would seek support through your normal ST rep and FAE channels.

The 2011 date is deceptive, it's when the forum last had a core meltdown. No one has posted anything to it since 2009, and you probably reanimated it via a Google/Bing search. People typically start new threads rather than find lost zombie ones.
Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
shopping
Associate II
Posted on September 26, 2014 at 23:39

Hey Clive,

I only reanimated this one because it's precisely my issue and because it was not answered so far. No point in generating more useless content for the search results.

Any suggestions regarding this issue?

Thanks,

Razvan
Posted on September 27, 2014 at 05:34

Compared to competitors ST has a pretty low defect density or issues related to steppings. Check the errata.

Are you doing this on a known reference board? There are number of EVAL series boards with Smartcard slots, these aren't things I've tinkered with, but there might well be some example code, and potentially other users.
Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
shopping
Associate II
Posted on September 27, 2014 at 14:41

I'm using a custom board, but as I said earlier, I can communicate with the card if I disable smartcard mode. The downside is that I'm losing the NACK handling and the internal connection between TX and RX.

I checked the errata before posting here. Says nothing about this. Also checked example code and nothing interesting popped up.
Posted on November 07, 2014 at 09:36

I had the same problem - coudn't receive anything in smart card mode, I've resolved it by setting

USART_CR3_SCEN afterUSART_CR1_UE. It isn't mentioned in datasheet.