Skip to content

library/spi_engine: SDO Extension upgrade #1808

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion docs/library/spi_engine/axi_spi_engine.rst
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,18 @@ If an application attempts to read data while the FIFO is empty undefined data
is returned and the state of the FIFO remains unmodified.
It is possible to read the first entry in the SDI FIFO without removing it by
reading from the SDI_FIFO_PEEK register.
It is important to point out that each read represents one lane of the SPI. So,
for ``NUM_OF_SDI`` lanes it is necessary to read ``NUM_OF_SDI`` times. Reading
always starts from lane 0.
The number of valid entries in the SDI FIFO register can be queried by reading
the SDI_FIFO_LEVEL register.
the SDI_FIFO_LEVEL register. This value must be a multiple of ``NUM_OF_SDI``.

Data can be inserted into the SDO FIFO by writing to the SDO_FIFO register
**only the valid lanes**. For example, if there are 4 lanes and just 2 of them
are enabled, then the programmer must write 2 values to this register. The
remaining lanes will contain ``SDO_DEFAULT`` value defined in
:ref:`spi_engine execution`. The number of valid lanes are defined in
:ref:`spi_engine configuration-registers`.

If the peripheral is disabled by setting the ENABLE register to 0 any data
stored in the FIFOs is discarded and the state of the FIFO is reset.
Expand Down
Loading
Loading