| vlabifhw commands |
| Command name |
Sent by |
Documentation |
| RX_COMMAND_INFO |
Software | Format:
0x70
Requests an information packet from the hardware.
|
| RX_COMMAND_SEND_CHANNEL |
Software | Format:
0x71 <code> <data...>
Writes up to 15 bytes to a specific channel. The
<code> byte is constructed from the channel
number (low nibble) and the number of bytes (high nibble).
The data follows the <code> byte. Escape
codes are not used here; they are only used for data
being received from the hardware.
|
| TX_PACKET_INFO |
Hardware | Format:
0x80 <code>
Provides information about the vlabifhw device. The high nibble
of the <code> byte is the total number of channels (ext_channels)
plus two. If this nibble is zero, then the total is 16.
The low nibble is the hardware version, currently always 1.
|
| TX_PACKET_CHANNEL_DATA |
Hardware | Format:
0x81 <channel_code> <data...>
Contains data that has been sent to a channel. The high
nibble of the <channel_code> byte gives the channel
number. It is followed by zero or more bytes of channel data.
The data ends with a command. Note that if the data contains
bytes that could be interpreted as commands (e.g. 0x81) then
these will be preceded by the escape code 0x87. The same is
true for the channel code.
|
| TX_PACKET_READY |
Hardware | Format:
0x82
Indicates that the hardware is ready for further commands.
|
| TX_PACKET_OVERFLOW |
Hardware | Format:
0x83 <code>
Indicates that a send operation on a specific channel has
(partially or completely) failed due to the channel FIFO
being full. The high nibble of <code> is the channel number.
The low nibble is the counter value at the time of overflow.
You can calculate the number of bytes that were successfully sent
using the equation:
successfully_sent = ( outgoing_size - low_nibble ) - 1
where outgoing_size is the number of bytes that were written
to the channel using RX_COMMAND_SEND_CHANNEL.
|
| TX_PACKET_END_TX |
Hardware | Format:
0x84
Indicates that a packet of data from a channel has finished.
|
| TX_ESCAPE_CODE |
Hardware | Format:
0x87
Indicates that the next byte is not a command and must
be taken literally.
|
| Debugger commands
(sent to the highest numbered channel
using RX_COMMAND_SEND_CHANNEL)
|
| Command name |
Sent by |
Documentation |
| RX_COMMAND_CLOCK_STEP |
Software | Format:
0xa0 <count (high byte)> <count (low byte)>
The debug_clock output is stepped through <count>
cycles. The command 0xa0 is echoed by the hardware.
|
| RX_COMMAND_GET_DEBUG_CHAIN |
Software | Format:
0xa1 <length (high byte)> <length (low byte)>
The current value of the debug chain is downloaded. The
debug chain length is specified in bytes. The command 0xa1 is
echoed by the hardware followed by the debug chain bytes.
|
| RX_COMMAND_SET_DEBUG_CHAIN |
Software | Format:
0xa2 <length (high byte)> <length (low byte)> <data...>
The current value of the debug chain is programmed. The
debug chain length is specified in bytes, followed by the
debug chain data. The command 0xa2 is echoed by the hardware.
|
| RX_COMMAND_SET_CTRL |
Software | Format:
0xa3 <control byte>
The control byte is set. The bits of this byte correspond to control
lines (0 = least significant):
| Bit name | Number | Documentation |
| RX_FREE_RUN_BIT | 0 |
When this bit is '1', the debug_clock output is cycled as quickly as
possible (at half the frequency of the clk input).
|
| RX_CLOCK_BIT | 1 |
Provided that ( RX_FREE_RUN_BIT or RX_FREE_RUN_BREAK_BIT ) = '0',
the debug_clock output is set to the value of this bit.
|
| RX_RESET_BIT | 2 |
The debug_reset output is set to the value of this bit.
|
| RX_FREE_RUN_BREAK_BIT | 3 |
When this bit is '1' and the breakpoint input is '0',
the debug_clock output is cycled as quickly as possible.
|
| RX_CAPTURE_BIT | 4 |
The read and read/write registers in the debug chain are
loaded from the hardware under test, updating the debug chain.
|
| RX_READY_BIT | 5 |
The write and read/write register outputs from the debug chain
are programmed from the current debug chain value.
|
|
| RX_COMMAND_NOP |
Software | Format:
0xa4
The NOP command is echoed.
|