Go to previous topic
Go to next topic
Last Post 27 Feb 2007 12:42 PM by  kurtl@logicpd.com
Access to CompactFlash card?
 6 Replies
Author Messages

rbwinchell



New Member


Posts:
New Member


--
13 Feb 2007 08:27 AM
    Is there a sample/explaination/etc of how to access the CF card programatically (e.g. not through Lolo)?

    Thanks.

    ashwinb@logicpd.com



    New Member


    Posts:
    New Member


    --
    13 Feb 2007 01:33 PM
    You would want to access the CF within an OS? If so, which OS?

    rbwinchell



    New Member


    Posts:
    New Member


    --
    14 Feb 2007 07:47 AM
    Sorry I should have been more clear. I'd like to do this without using an OS, or using the Sharp BlueStreak library.

    I see that the CF only works in memory-mapped mode, so all I'm really interested in is how I access that at a basic level.

    rbwinchell



    New Member


    Posts:
    New Member


    --
    20 Feb 2007 09:31 AM
    I've gotten a bit further and I understand what is involved here.

    The problem I am having is that I can see the attribute memory of the CF card (0x4c700000), but if I try to read/write any of the card registers, I am getting bad data. Trying to write does not change the values. Any tips or ANY information would be appreciated.

    kurtl@logicpd.com



    New Member


    Posts:
    New Member


    --
    22 Feb 2007 11:22 AM
    The Sharp ARM7 and ARM9 CPUs do not deassert the chip select line to external devices upon consecutive accesses to the same area. Some devices require this, including CompactFlash devices. This may be partially related to your problem. To work around this you must insert dummy accesses to other external memory areas. This document provides further details.
    http://www.logicpd.com/do...AN_1003185_Rev_A.pdf

    rbwinchell



    New Member


    Posts:
    New Member


    --
    27 Feb 2007 12:37 PM
    I have this working now. Turns out it was a problem with the read/write timings getting set correctly for the CS3 area (write-enable line not being asserted long enough).

    kurtl@logicpd.com



    New Member


    Posts:
    New Member


    --
    27 Feb 2007 12:42 PM
    Good work!


    ---