[En-Nut-Discussion] SD card perf issue on EIR
Mathieu SOULARD
kazh29 at gmail.com
Mon Feb 8 14:51:48 CET 2010
Hi,
Thanks for your answer.
Actually I had just sent another mail about that issue, I didn't see your
answer before...
It is true that this should be better through DMA, but actually on the EIR
the SD card IO lines are driven by gpio, since the HW SPI controller is
dedicated to the audio codec.
So the mmc driver is powered by software bit banging, which is the worst
case regarding data rate and CPU load. Anyway, I'm shure it is possible to
get it working enough since the data line of the SD card can work up to
25MBit/sec.
About the GPIO access from the driver, it is done with outr().
I'll try to understand the architecture of this driver, and the SD standard
to check if there is a way to improve the data rate.
Moreover, maybe it is possible to implement a driver using SD BUS bit
banging instead of SPI bit banging, since SD BUS allows up to 4 data lines,
making transferts 4x faster.
I'll let you know if I get improvements. Maybe someone had expenrienced that
issue on the EIR and will join the discussion.
For information, I use the EIR to implement a multimedia audio system, to
play music from network, internet and SD card (if I can improve the data
rate...).
Thanks
Regards
Mathieu
2010/2/8 <uprinz2 at netscape.net>
>
> Hi Mathieu,
>
> I didn't do anything with SD on my EIR so far. So I never checked for
> proper configuration of that part. But I know that Nut/OS is using a
> combination of hardware and software interfacing on the SPI bus. So, while
> using interrupt driven SPI, the chipselects are done by GPIO. There is a
> two-step improvement possible for that.
> First speed-up is possible by exchanging every NutGpioCfg() by its
> appropriate direct access outr(GPIO_xy, value).
> Second it is possible to configure the SPI interface to directly drive the
> chipselects by hardware. For that some real deep changes have to be
> implemented. Additionally one has to respect some problematic
> constellations given by the chips errata sheet.
>
> In general SD-Access should be done with DMA/PDC and then there are another
> one or two erratas to be obeyed.
>
> I am not sure if I am actually the only one experimenting with the EIR in
> this list ( besides Harald). This is the first support request on EIR since
> the few month I have the device. But I am actually busy with the http
> frontend of it. SD was on my list for a later date.
>
> Best regards, Ulrich
>
> On Mon, 8 Feb 2010 00:20:10 +0100, Mathieu SOULARD <kazh29 at gmail.com>
> wrote:
> > Hi all,
> >
> > I'm facing performances issues using SD cards on my EIR board powered by
> > nut/os 4.8.6.
> >
> > It seems that I can read a file about 10Ko/seconds, which is not enough
> to
> > feed the audio codec with data.
> > The SD card is formated in FAT32.
> >
> > I would like to know someone has experienced such issue, and if you know
> > what could I do to improve it ?
> >
> >
> > Thanks
> > Regards
> >
> > Mathieu
> > _______________________________________________
> > http://lists.egnite.de/mailman/listinfo/en-nut-discussion
> _______________________________________________
> http://lists.egnite.de/mailman/listinfo/en-nut-discussion
>
More information about the En-Nut-Discussion
mailing list