User manual

RC200/203 Manual
www.celoxica.com Page 77
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);