Skip to main content
ALakh.1
Associate
December 28, 2021
Question

HI There!, I am new to STM32 and STM32CUBE IDE, i am trying to build a device using stm32f103c8 which can communicate with smartcard using St8024 smart card ic. and i have downloaded AN4800 example project and imported in to Stm32cube ide

but i don't know how to make it work and how i can use the libraries provided with my projects. Please any help will be highly appreciated Thanks.

This topic has been closed for replies.

5 replies

ST Technical Moderator
December 28, 2021

Hello @ALakh.1​ and welcome to the Community :)

Maybe you can review the Smartcard example available in the STM32CubeF1 MCU package, and follow the readme file to make the program work:

\STM32Cube_FW_F1_V1.8.4\Projects\STM3210C_EVAL\Examples\SMARTCARD\SMARTCARD_T0

To import the available Cube project from SW4STM32 to STM32CubeIDE, you can follow the guide UM2579: Migration guide from System Workbench to STM32CubeIDE.

I hope this helps !

When your question is answered, please close this topic by choosing Select as Best. This will help other users find that answer faster.

Imen

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Thanks
ALakh.1
ALakh.1Author
Associate
December 28, 2021

Hi Imen,

Thanks for your quick response, but i have tried importing the "en.x-cube-smcard_v1.0.0" in cube ide, and i have changed pins accordingly in platform config.h, selected STM3210B and buil and successfuly uploaded code using stlink, but i don't know what happens next and how to read the data or sent to uart 2. I am sorry but i am totally new in this. :(

ALakh.1
ALakh.1Author
Associate
December 28, 2021

and i don't want to use the library are there any commands like for HAL_uart, for smart card in cube ide when we initialize any usart as smart card with clock so i can use those and communicate with card. Thanks

ALakh.1
ALakh.1Author
Associate
December 30, 2021

Hi Imen,

I followed the guide you provided and now i have uploaded the code to mcu, but it is not reading any data from Smart card. where you think error could be.

Thanks

ALakh.1
ALakh.1Author
Associate
December 30, 2021

 while (HAL_OK != ATR_Read(&SCInterface, atr_buff, &atr_size));

this is the line where code stucks