Hardware description
2
. If
Do not use the SmartMedia macros at the same time as any other accesses to the CPLD
you have called
RC200SmartMediaSetLogicalAddress()
,
RC200SmartMediaSetAddress()
,
RC200SmartMediaRead()
or
RC200SmartMediaWrite()
, you need to get the return value from
RC200SmartMediaOperationEnd()
before accessing the CPLD again. If you have
used any of the other SmartMedia macros, you can access the CPLD after they have
completed.
5.15.2 SmartMed
o pr
Parameters:
in Hz.
Timing:
Description:
You must run this macro in parallel with the CPLD controller macro,
RC200CPLDRun()
. The SmartMedia can only function once you have enabled the
CPLD. You must ensure that communications with SmartMedia are not run in
commands.
lizing
macro pr
it (
ResultPtr
);
1
. Returns 0 for success, 1 for
Timing:
Description:
card is inserted. It performs a reset of the device and reads the ID to identify the
size of the card.
which the controller stores internally.
f a SmartMedia device can be determined after a successful call to
diaGetMakerCode()
and
es of type
unsigned 8.
For example:
unsigned 8 Maker, Device;
ode ();
ia management tasks
extern macr
oc RC200SmartMediaRun (
ClockRate
);
ClockRate
: Clock rate of the clock domain of the call to this macro,
Does not terminate in normal use.
Runs the SmartMedia physical layer driver.
parallel with other CPLD control
5.15.3 Initia
the SmartMedia device
extern
oc RC200SmartMediaIn
Parameters:
ResultPtr
: Pointer to register of type
unsigned
failure.
240 clock cycles or more.
Initializes the SmartMedia device and controller.
You must call this macro when the board is switched on, or when a SmartMedia
The ID read returns a Maker and Device code
5.15.4 SmartMedia manufacturer and device code
extern macro expr RC200SmartMediaGetMakerCode ();
extern macro expr RC200SmartMediaGetDeviceCode ();
The manufacturer and device code o
RC200SmartMediaInit()
by calling
RC200SmartMe
RC200SmartMediaGetDeviceCode()
. Both return valu
Maker = RC200SmartMediaGetMakerC
Device = RC200SmartMediaGetDeviceCode ();
www.celoxica.com
Page 59