
Confidential Information Rev. 1.1
1849 Fortune Drive, San Jose CA951 1, USA• (408)955-0800 • http://www.micrel.com
- Page
8 -
2008 Micrel Semiconductor
KSZ8851 16Bit BSP User’s Manual
The follo ing CLI commands to prepare an Ethernet packet and transmit from
CLI command to KSZ8851 device. There are total six data buffer for the user
to store the Ethernet packet. One data buffer can only store one Ethernet
packet, and must be a completed Ethernet packet.
hwbufwrite BufNum BufOffset WData [...] -- Write data to debug buffer.
=>hwbufwrite 0 0 ff ff ff ff ff ff 08 00 70 22 55
Write a destination MAC address (broadcast), source MAC address
(08:00:70:22:44:55) to the data buffer 0, data buffer offset 0.
hwbuffill BufNum BufOffset FData BufInc Len -- Fill data to debug
buffer.=>hwbuffill 0 0c 01 02 3c
Fill data buffer 0, start from data buffer offset 0x0c, ith data 0x01, and
increasing by 0x02, totally filling data length is 0x3c (60 bytes).
hwbufread BufNum BufOffset Len -- Display contents of debug buffer
=>hwbufread 0 0 3c
=>
00000000 ff ff ff ff ff ff 08 00 - 70 22 55 01 03 05 07
00000010 09 0b 0d 0f 11 13 15 17 - 19 1b 1d 1f 21 23 25 27
00000020 29 2b 2d 2f 31 33 35 37 - 39 3b 3d 3f 1 3 5 7
00000030 9 b d f 51 53 55 57 - 59 5b 5d 5f
Display the contents of data buffer 0, offset 0, data length 0x3c (60
bytes).
hwbuftx BufNum Len Repeat SameBuf Delay -- Tx packet from buffer to KSZ8851
=>hwbuftx 0 3c 2 1 0
Transmit packet to KSZ8851, from data buffer 0, ith packet length 60 bytes,
transmit 2 times, using the same buffer, no delay bet een transmit packets.
=>hwbuftx 0 5ea 10 1 0
Transmit packet to KSZ8851, from data buffer 0, ith packet length 1514
bytes, transmit 16 times, using the same buffer, no delay bet een transmit
packets.
=>hwbuftx 0 5ea 3e8 1 1
Transmit packet to KSZ8851, from data buffer 0, ith packet length 1514
bytes, transmit 1000 times, using the same buffer, delay 1ms bet een
transmit packets.
=>hwbuftx 0 3c 6 0 0
Transmit packet to KSZ8851, from data buffer 0, ith packet length 60 bytes,
transmit 6 times, continuous next buffer for next transmit
5
, no delay
bet een transmit packets.
5
If you already prepare the six buffers with different Ethernet packets data, it will transmit data buffer from 0 to 5 one by one.