FPGARelated.com
Forums

Configure Spartan-3E w SD-Card?

Started by Unknown March 20, 2008
I think someone here mentioned the possibility to configure an Xilinx
Spartan-3E fpga with an SD-Card (MMC) in SPI mode. However when checking on
this by chance today I found that it seems to not work because:

Read commands are defined as:
http://www.sdcard.org/about/memory_card/pls/Simplified_Physical_Layer_Spec.pdf
  READ_SINGLE_BLOCK  0x51
  READ_MULTI..       0x52

But Spartan-3E SPI uses the commands:
http://direct.xilinx.com/bvdocs/publications/ds312.pdf  Page79
  Fast read   0x0B
  Read        0x03
  Read array  0xE8

Or did I miss something?
On 20 Mrz., 13:07, sky46...@trline4.org wrote:
> I think someone here mentioned the possibility to configure an Xilinx > Spartan-3E fpga with an SD-Card (MMC) in SPI mode. However when checking on > this by chance today I found that it seems to not work because: > > Read commands are defined as:http://www.sdcard.org/about/memory_card/pls/Simplified_Physical_Layer... > READ_SINGLE_BLOCK 0x51 > READ_MULTI.. 0x52 > > But Spartan-3E SPI uses the commands:http://direct.xilinx.com/bvdocs/publications/ds312.pdf Page79 > Fast read 0x0B > Read 0x03 > Read array 0xE8 > > Or did I miss something?
think you missed something. FPGA's can get configured from DATAFLASH mounted in SDCARD plastic (atmel sells those!) and sure mmc-sd can be used in spi or sd mode, but there is extra circuitry required, either mcu or cpld Antti
>think you missed something.
>FPGA's can get configured from DATAFLASH mounted in SDCARD plastic >(atmel sells those!) >and sure mmc-sd can be used in spi or sd mode, but there is extra >circuitry required, either mcu or cpld
I think my point was to accomplish this without adding an extra chip.. Using a MCU/CPLD it would ofcourse work.
On 20 Mrz., 13:48, sky46...@trline4.org wrote:
> >think you missed something. > >FPGA's can get configured from DATAFLASH mounted in SDCARD plastic > >(atmel sells those!) > >and sure mmc-sd can be used in spi or sd mode, but there is extra > >circuitry required, either mcu or cpld > > I think my point was to accomplish this without adding an extra chip.. > Using a MCU/CPLD it would ofcourse work.
well dont think it can be done, would be too good to be true ;) Antti
On Mar 20, 1:07 pm, sky46...@trline4.org wrote:
> I think someone here mentioned the possibility to configure an Xilinx > Spartan-3E fpga with an SD-Card (MMC) in SPI mode. However when checking on > this by chance today I found that it seems to not work because: > > Read commands are defined as:http://www.sdcard.org/about/memory_card/pls/Simplified_Physical_Layer... > READ_SINGLE_BLOCK 0x51 > READ_MULTI.. 0x52 > > But Spartan-3E SPI uses the commands:http://direct.xilinx.com/bvdocs/publications/ds312.pdf Page79 > Fast read 0x0B > Read 0x03 > Read array 0xE8 > > Or did I miss something?
SPI bus means to have one Master and one Slave. SD card cannot be master, you need to have a Master to get the data from! FPGA CONFIG RAM cannot be master, you need to have a master to write the data to the FPGA RAM ! For programming FPGA, you need a master getting the data from SD and writing to FPGA RAM. Larry, http://www.amontec.com
On 20 Mrz., 14:22, j...@amontec.com wrote:
> On Mar 20, 1:07 pm, sky46...@trline4.org wrote: > > > I think someone here mentioned the possibility to configure an Xilinx > > Spartan-3E fpga with an SD-Card (MMC) in SPI mode. However when checking on > > this by chance today I found that it seems to not work because: > > > Read commands are defined as:http://www.sdcard.org/about/memory_card/pls/Simplified_Physical_Layer... > > READ_SINGLE_BLOCK 0x51 > > READ_MULTI.. 0x52 > > > But Spartan-3E SPI uses the commands:http://direct.xilinx.com/bvdocs/publications/ds312.pdfPage79 > > Fast read 0x0B > > Read 0x03 > > Read array 0xE8 > > > Or did I miss something? > > SPI bus means to have one Master and one Slave. > > SD card cannot be master, you need to have a Master to get the data > from! > FPGA CONFIG RAM cannot be master, you need to have a master to write > the data to the FPGA RAM ! > > For programming FPGA, you need a master getting the data from SD and > writing to FPGA RAM. > > Larry,http://www.amontec.com
SD card doesnt need to be master, the issue is that it is not compatible to the FPGA command used in master serial mode, etc. with MMC card (not SD!) a RECONFIGURATION from MMC card could be possible, if 1 S3E is configured from SPI flash 2 S3E puts SPI flash into DEEP powerdown or any other mode that prevents configuration in case of PROG toggle 3 S3E prepares MMC card to enter STREAMING READ (not available on SD cards) mode and pre shifts instruction and address 4 S3E pulses its own PROG pin 5 S3E would be configured from a file located on the MMC card so while INITIAL load from card is no way possible a repeated secondary configuration can be possible S3E should be connected properly SPI flash and MMC card pins in parallel, MMC card should be operating in non SPI mode Antti
On Mar 20, 3:15 pm, Antti <Antti.Luk...@googlemail.com> wrote:
> On 20 Mrz., 14:22, j...@amontec.com wrote: > > > > > On Mar 20, 1:07 pm, sky46...@trline4.org wrote: > > > > I think someone here mentioned the possibility to configure an Xilinx > > > Spartan-3E fpga with an SD-Card (MMC) in SPI mode. However when checking on > > > this by chance today I found that it seems to not work because: > > > > Read commands are defined as:http://www.sdcard.org/about/memory_card/pls/Simplified_Physical_Layer... > > > READ_SINGLE_BLOCK 0x51 > > > READ_MULTI.. 0x52 > > > > But Spartan-3E SPI uses the commands:http://direct.xilinx.com/bvdocs/publications/ds312.pdfPage79 > > > Fast read 0x0B > > > Read 0x03 > > > Read array 0xE8 > > > > Or did I miss something? > > > SPI bus means to have one Master and one Slave. > > > SD card cannot be master, you need to have a Master to get the data > > from! > > FPGA CONFIG RAM cannot be master, you need to have a master to write > > the data to the FPGA RAM ! > > > For programming FPGA, you need a master getting the data from SD and > > writing to FPGA RAM. > > > Larry,http://www.amontec.com > > SD card doesnt need to be master, the issue is that it is not > compatible to the FPGA command used in master serial mode, etc. > > with MMC card (not SD!) a RECONFIGURATION from MMC card could be > possible, if > > 1 S3E is configured from SPI flash > 2 S3E puts SPI flash into DEEP powerdown or any other mode that > prevents configuration in case of PROG toggle > 3 S3E prepares MMC card to enter STREAMING READ (not available on SD > cards) mode and pre shifts instruction and address > 4 S3E pulses its own PROG pin > 5 S3E would be configured from a file located on the MMC card > > so while INITIAL load from card is no way possible a repeated > secondary configuration can be possible > > S3E should be connected properly SPI flash and MMC card pins in > parallel, MMC card should be operating in non SPI mode > > Antti
> SD card doesnt need to be master ...
Do you mean a SD Card could be Master ????? - Larry http://www.amontec.com
On 20 Mrz., 15:50, j...@amontec.com wrote:
> On Mar 20, 3:15 pm, Antti <Antti.Luk...@googlemail.com> wrote: > > > > > On 20 Mrz., 14:22, j...@amontec.com wrote: > > > > On Mar 20, 1:07 pm, sky46...@trline4.org wrote: > > > > > I think someone here mentioned the possibility to configure an Xilinx > > > > Spartan-3E fpga with an SD-Card (MMC) in SPI mode. However when checking on > > > > this by chance today I found that it seems to not work because: > > > > > Read commands are defined as:http://www.sdcard.org/about/memory_card/pls/Simplified_Physical_Layer... > > > > READ_SINGLE_BLOCK 0x51 > > > > READ_MULTI.. 0x52 > > > > > But Spartan-3E SPI uses the commands:http://direct.xilinx.com/bvdocs/publications/ds312.pdfPage79 > > > > Fast read 0x0B > > > > Read 0x03 > > > > Read array 0xE8 > > > > > Or did I miss something? > > > > SPI bus means to have one Master and one Slave. > > > > SD card cannot be master, you need to have a Master to get the data > > > from! > > > FPGA CONFIG RAM cannot be master, you need to have a master to write > > > the data to the FPGA RAM ! > > > > For programming FPGA, you need a master getting the data from SD and > > > writing to FPGA RAM. > > > > Larry,http://www.amontec.com > > > SD card doesnt need to be master, the issue is that it is not > > compatible to the FPGA command used in master serial mode, etc. > > > with MMC card (not SD!) a RECONFIGURATION from MMC card could be > > possible, if > > > 1 S3E is configured from SPI flash > > 2 S3E puts SPI flash into DEEP powerdown or any other mode that > > prevents configuration in case of PROG toggle > > 3 S3E prepares MMC card to enter STREAMING READ (not available on SD > > cards) mode and pre shifts instruction and address > > 4 S3E pulses its own PROG pin > > 5 S3E would be configured from a file located on the MMC card > > > so while INITIAL load from card is no way possible a repeated > > secondary configuration can be possible > > > S3E should be connected properly SPI flash and MMC card pins in > > parallel, MMC card should be operating in non SPI mode > > > Antti > > SD card doesnt need to be master ... > > Do you mean a SD Card could be Master ????? > > - Larryhttp://www.amontec.com
no no, but when FPGA is configured as MASTER SERIAL then FPGA would generate CCLK if CCLK -> SD_CLK and MMC preinited for streaming read then FPGA would clock out its bitstream from MMC card Antti