Spi — Requirements
Normative
Defines what a conformant SPI driver MUST do. Keywords per Requirement Keywords; conformance per Conformance. Requirements do not carry individual status — the set-level status applies to all of them. Signatures, error codes, and configuration properties are in the API Reference, Errors, and Configuration Reference pages. Cross-module rules (types, error model, naming, memory mapping) are in General.
Mandatory (MUST) - 23 Requirements
The conformance contract — an implementation MUST satisfy every requirement here.
CHI-SPI-MUST-01 — Controller mode
|
The driver MUST support operating a channel as an SPI controller, initiating a full-duplex transaction to a chip-select-addressed device and driving the chip select. |
CHI-SPI-MUST-02 — Target mode
|
The driver MUST support operating a channel as an SPI target, responding to a
controller that selects it, using data staged by the integration code (or |
CHI-SPI-MUST-03 — Event handling mode
|
For each channel, event handling MUST be statically configurable as interrupt or polling.
In interrupt mode |
CHI-SPI-MUST-04 — State after reset
|
After reset the driver MUST be in |
CHI-SPI-MUST-05 — State after initialization
|
|
CHI-SPI-MUST-06 — State after de-initialization
|
|
CHI-SPI-MUST-07 — Controller channel state transitions
|
A controller channel MUST follow the controller-mode state machine in
Concepts: |
CHI-SPI-MUST-08 — Target channel state transitions
|
A target channel MUST follow the target-mode state machine: |
CHI-SPI-MUST-09 — Initialization
|
|
CHI-SPI-MUST-10 — De-initialization
|
|
CHI-SPI-MUST-11 — Start a transaction
|
|
CHI-SPI-MUST-12 — Buffer-set model
|
A transaction MUST transfer a buffer set ( |
CHI-SPI-MUST-13 — Data transfer and consistency
|
During interrupt or poll handling the driver MUST transfer the elements to/from the buffer
sets supplied to |
CHI-SPI-MUST-14 — Controller completion and notification
|
On transferring the whole buffer set on a controller channel the driver MUST move the
channel to |
CHI-SPI-MUST-15 — Target completion and notification
|
On detecting chip-select deactivation the driver MUST move the target channel to |
CHI-SPI-MUST-16 — GPIO chip-select control
|
Where a controller’s chip select is configured as GPIO control, the driver MUST call
|
CHI-SPI-MUST-17 — Cancel a staged transaction
|
|
CHI-SPI-MUST-18 — Bus error handling
|
On an SPI bus error the driver MUST report it via |
CHI-SPI-MUST-19 — Channel state query
|
|
CHI-SPI-MUST-20 — Development error detection
|
When development error reporting is enabled, each API MUST detect the conditions listed in
Errors and report them via |
CHI-SPI-MUST-21 — Callout notifications
|
The driver MUST call |
CHI-SPI-MUST-22 — Public types and error identifiers
|
The driver MUST provide |
CHI-SPI-MUST-23 — Configuration model
|
The driver MUST support the configuration model in Configuration Reference — a
|
Recommended (SHOULD) - 1 Requirement
CHI-SPI-SHOULD-01 — Chip-select detection service
|
Where a target channel’s hardware cannot detect chip-select control, the driver SHOULD
provide |
Optional (MAY) - 1 Requirement
CHI-SPI-MAY-01 — Poll function
|
The driver MAY provide |