Update 'USB config & command protocol'

Triss 2021-07-15 13:13:16 +00:00
parent f9859ddd7f
commit 2ecaa8e138
1 changed files with 4 additions and 4 deletions

@ -95,16 +95,16 @@ Additionally, a number of nonstandard commands are supported as well, for more s
* Number of chip-select lines: 8-bit bitmap
* Minimum bits-per-transfer-word value (8 bit)
* Maximum bits-per-transfer-word value (8 bit)
* `S_CMD_S_SPI_CHIPN` (`0x41`): set which chip select lines are to be controlled. Has a single argument byte, a bitmap of chip select line values.
* `S_CMD_S_SPI_SETCS` (`0x42`): set the voltage level of the CS line(s) selected by `S_CMD_S_SPI_CHIPN`.
* `S_CMD_S_SPI_FLAGS` (`0x43`): set transfer settings flags, single argument byte:
* `S_CMD_S_SPI_CHIPN` (`0x41`): set which chip select lines are to be controlled. Has a single argument byte, a bitmap of chip select line values. No response (aside from an `ACK`).
* `S_CMD_S_SPI_SETCS` (`0x42`): set the voltage level of the CS line(s) selected by `S_CMD_S_SPI_CHIPN`. No response (aside from an `ACK`).
* `S_CMD_S_SPI_FLAGS` (`0x43`): set transfer settings flags, one response byte (actual flags applied), single argument byte:
* Bit 0 (lsb): `CPHA`
* Bit 1: `CPOL`
* Bit 2,3: frame format: `0=standard`, `1=SSP`, `2=MicroWire`. 3 is undefined.
* Bit 4: LSBit-first transfer (clear this bit for MSBit-first transfers)
* Bit 5: CS is used as active-high signal (clear this bit for active-low CS signals)
* Bit 6 (msb): Use 3-wire mode (clear this bit for regular 4-wire SPI)
* `S_CMD_S_SPI_BPW` (`0x44`): set bits per word used in a SPI transfer. Single argument byte denoting the number of bits.
* `S_CMD_S_SPI_BPW` (`0x44`): set bits per word used in a SPI transfer. Single argument byte denoting the number of bits. One response byte: bits per word applied.
* `S_CMD_SPI_READ` (`0x45`): similar to `SPIOP` (`0x13`), except without data to write (and no "write data length" argument).
* `S_CMD_SPI_WRITE` (`0x46`): similar to `SPIOP` (`0x13`), except without data to read (and no "read data length" argument).
* `S_CMD_SPI_RDWR` (`0x47`): full-duplex SPI transfer (as opposed to `SPIOP` (`0x13`), which is only half-duplex), same arguments and result format as `SPIOP` (`0x13`).