Hardware description
Parameters:
None.
Timing:
Dependant on clock rate. Minimum: 4 clock cycles.
Description:
Sets the reset pin low for at least 100ns, forcing the Ethernet chip to reset.
You need to call
RC200EthernetEnable()
after you reset the device.
5.16.6 Reading a packet
Starting the read process
extern macro proc RC200EthernetReadBegin (
StatusPtr
,
DestinationPtr
,
SourcePtr
,
DataByteCountPtr
,
ResultPtr
);
Parameters:
StatusPtr
: Pointer to data of type
unsigned 16
. Returns the status data from
the received packet.
DestinationPtr
: Pointer to data of type
unsigned 48
. Returns the destination
MAC address from the received packet.
SourcePtr
: Pointer to data of type
unsigned 48
. Returns the source MAC
address from the received packet.
DataByteCountPtr
: Pointer to data of type
unsigned 11
. Returns the number
of data bytes in the received packet.
ResultPtr
: Pointer to data of type
unsigned 1
. Returns 1 if the macro has
timed out while waiting for a packet (failure) or 0 (success).
Timing:
At least 70 clock cycles. There is a timeout of 0.5s if no packet is received.
Description:
Checks if a packet is waiting to be read, and if it is, starts the read process and
returns destination, source, status and byte count from the packet header.
If it times out while waiting for a packet,
ResultPtr
is returned as '1', otherwise it
is returned as '0'. In this case, no further packet read commands should be issued.
Reading a byte of data from a packet
extern macro proc RC200EthernetRead (
DataPtr
,
ResultPtr
);
Parameters:
DataPtr
: Pointer to data of type
unsigned 8
. Returns a byte of data from the
received packet.
ResultPtr
: Pointer to data of type
unsigned 1
. Returns 1 (failure) or 0
(success).
Timing:
2 or 7 clock cycles alternately, and up to 12 clock cycles for the final read.
The macro reads a byte at a time, but Ethernet accesses are 16-bit. When a byte
of data is already buffered on the chip the read only takes 2 clock cycles.
Timing may differ if other accesses to the chip precede a read operation.
Description:
Reads a single data byte from the packet currently being read.
Returns
ResultPtr
= 1 to indicate an error if there is no data remaining in the
packet or if there is no read in progress.
Data is read a byte at a time, but communications with the Ethernet chip are 16-bit,
so a byte is buffered in the Ethernet data structure, until there are 16 bits to read.
You must call
RC200EthernetReadBegin()
before this macro.
www.celoxica.com
Page 66
Содержание RC200
Страница 1: ...Platform Developer s Kit RC200 203 Manual ...
Страница 72: ......
Страница 76: ...RC200 203 PSL reference TFT 28 writing data 50 www celoxica com Page 76 ...