Calcolatore Spazio Indirizzi MemoriaFormula

## SPI Data Rate

SPI (Serial Peripheral Interface) transfers one bit per clock cycle. The effective rate depends on clock speed and protocol overhead.

### Formulas

**Raw Rate = Clock Speed / 8** (bytes per second)

**Effective Rate = Clock x Data Bits / (Data Bits + Idle) / 8**

Idle clocks account for chip-select toggling and inter-transfer gaps. SPI has no addressing overhead unlike I2C, making it faster for bulk transfers.

Esempio Risolto

8 MHz SPI clock, 8-bit transfers, 2 idle clocks between transfers.

  1. Raw rate: 8e6 / 8 = 1.00 MB/s
  2. Clocks per transfer: 8 + 2 = 10
  3. Effective rate: 8e6 x 8 / 10 / 8 = 0.80 MB/s
  4. Bus efficiency: 8 / 10 = 80%