Error in eMMC example iMX6 platform SDK

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Error in eMMC example iMX6 platform SDK

1,149件の閲覧回数
dirkschäfer
Contributor III

In mmc_read_esd in usdhc_mmc.c is an error in CMD8

This line is correct:

card_cmd_config(&cmd, CMD8, NO_ARG, READ, (1<<0)|(1<<2)|(1<<4), DATA_PRESENT, TRUE, TRUE);

or host_data_read will never return.

ラベル(1)
0 件の賞賛
返信
3 返答(返信)

975件の閲覧回数
Yuri
NXP Employee
NXP Employee

Thanks for this information, I will try to check.

Regards,

Yuri.

0 件の賞賛
返信

975件の閲覧回数
dirkschäfer
Contributor III

It is not possible to put the card into transfer mode.

card_enter_trans in usdhc.c CMD7 send fails.

card_cmd_config(&cmd, CMD7, card_address, READ, (1<<0)|(1<<2)|(1<<4),//RESPONSE_48_CHECK_BUSY,

                    DATA_PRESENT_NONE, TRUE, TRUE);

If I ignore this, I can use card_data_read and card_data_write. Written data are saved, to weherever. Even after power down the data is still there, but whatever offset I choose, I get the same data.

It is a 4GB Toshiba eMMC chip on a Toradex Apalis board. Program is loaded over the serial bootloader, DCD and IVT from u-boot. Serial, GPIO and SPI works fine.

0 件の賞賛
返信

975件の閲覧回数
Yuri
NXP Employee
NXP Employee

  Parameters of C-function card_cmd_config() are used to fill bit fields of Command Transfer Type
(uSDHCx_CMD_XFR_TYP)  register. Your pattern (1<<0)|(1<<2)|(1<<4) concerns the following
bit fields :

- CICEN (Command Index Check Enable) ;
- CCCEN (Command CRC Check Enable) ;
- RSPTYP[1:0] (Response Type Select).

The table below from the i.MX6 Reference Manual shows meaning of possible settings.

response.jpg

The last two parameters of C-function card_cmd_config() are used to configure

CICEN and CCCEN. Perhaps it would be better  to change them.

Have a great day,
Yuri

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 件の賞賛
返信