This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Re: Atmel DataFlash commands?


Hi Stano

Stanislav Meduna wrote:

> John Dallaway wrote:
> 
>> It looks like the existing read command opcodes in the DataFlash driver
>> refer to an older SCK/CLK mode which is not supported in newer devices.
>> Can you determine whether we need to continue to support the old SCK/CLK
>> mode from the timing diagrams?
> 
> Hmm.. the older Inactive Clock Polarity Low mode actually differs from
> SPI Mode 0 exactly in the way I have observed - the first data bit
> is put to the SO after 64th falling clock edge in the SPI mode
> and after 65th edge in the older one.
> 
> So the answer depends on 1) whether someone uses a hardware
> that only does the older mode and cannot do SPI 0/3 and
> 2) how to do the transition so that working code out there
> does not break in a quite unpleasant way.

The only contributed board support which uses this driver is for the
Atmel AT91EB55 evaluation board which uses an AT45DB321 DataFlash part.
The original version of this part did not support the newer "SPI Mode
0/3" commands:

  http://www.atmel.com/dyn/resources/prod_documents/DOC1121.PDF

> I'd guess we'll need a configuration option for the mode here...

Yes. It seems best to add a CYGOPT_DEVS_FLASH_ATMEL_DATAFLASH_ICP_READ
option which is disabled by default and must be enabled to select the
older "Inactive Clock Polarity High/Low" read commands. We can tweak the
AT91EB55 HAL to require that this option is enabled.

John Dallaway

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]