EmbDev.net

Forum: ARM programming with GCC/GNU tools MCB2300 SD card problem


Author: Baltasar Reig (breig)
Posted on:

Rate this post
0 useful
not useful
Hi all,

I have been trying the demo "ChaN's FAT-Module and LPC23xx/24xx MCI" on
my MCB2300 board (with LPC2388 controller), using a Sandisk 512 MB SD
card:
http://gandalf.arubi.uni-kl.de/avr_projects/arm_pr...

My problem is the demo always gets stuck when initializing the disk,
that is, in the function MCI_CardInit(). The output debug information
is:

MCI_INIT ok
timeout CMD8-> SD-Card<Version 2.0 or MMC
MCI_Send_ACMD failed-> MMC, invalid power-range or no card
unknown card
....

I have tried some solutions proposed in this and another forums, like
disabling the MAM and/or reducing the clock speed. However the problem
is the same every time.

The demo is tested with a LPC2368 controller. Is there some important
change that I should take into account between the LPC2368 and the
LPC2388? I have not found it in the user's guide, but maybe I just
missed it.

If anyone has some kind of experience with this demo, any help would be
really appreciated.

Thanks in advance!

PD: I will try a different SD card too, even though the one I have works
fine under Windows...

Author: Martin Thomas (mthomas) (Moderator)
Posted on:

Rate this post
0 useful
not useful
Baltasar Reig wrote:
> Hi all,
>
> I have been trying the demo "ChaN's FAT-Module and LPC23xx/24xx MCI" on
> my MCB2300 board (with LPC2388 controller), using a Sandisk 512 MB SD
> card:
> http://gandalf.arubi.uni-kl.de/avr_projects/arm_pr...
>
> My problem is the demo always gets stuck when initializing the disk,
> that is, in the function MCI_CardInit(). The output debug information
> is:
>
> MCI_INIT ok
> timeout CMD8-> SD-Card<Version 2.0 or MMC
> MCI_Send_ACMD failed-> MMC, invalid power-range or no card
> unknown card
> ....
>
> I have tried some solutions proposed in this and another forums, like
> disabling the MAM and/or reducing the clock speed. However the problem
> is the same every time.
>
> The demo is tested with a LPC2368 controller. Is there some important
> change that I should take into account between the LPC2368 and the
> LPC2388? I have not found it in the user's guide, but maybe I just
> missed it.
>
> If anyone has some kind of experience with this demo, any help would be
> really appreciated.
>
> Thanks in advance!
>
> PD: I will try a different SD card too, even though the one I have works
> fine under Windows...

The example-project from my page is rather experimental. It's basically
a combination of NXP's MCI-driver and ChaN's fat-code. ChaN's new
example-package now includes a LPC MCI driver too so give it a try. You
may also try the MCI example from NXP's example-package for LPC23xx/24xx
first to verify that the hardware works correctly. The NXP-code is
prepared for RealView but the Keil MDK-ARM evaluation-version should do
for tests.

Author: Gregory Smith (Company: SKF) (gsmith)
Posted on:

Rate this post
0 useful
not useful
I had the same situation described by Baltasar Reig except I'm using a 
Kiel MCB2387 (Version 4.0) development card.

The solution was to change the definition of "MCB2300_VERSION_0" mci.h 
from zero to one as shown:
/* For the earliest MCB2300 board, set below bit to 1, for the newer
one, set it to zero. */
#define MCB2300_VERSION_0  1

(Thank you to Martin Thomas for the excellent example software).

Reply

Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]




Bild automatisch verkleinern, falls nötig
Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.