ATtiny1624/1626/1627

DATA

Data

  0x04 8 - 0x00  

Data

Bit  7 6 5 4 3 2 1 0  
  DATA[7:0]  
Access  R/W R/W R/W R/W R/W R/W R/W R/W  
Reset  0 0 0 0 0 0 0 0  

Bits 7:0 – DATA[7:0]: SPI Data

SPI Data

The DATA register is used for sending and receiving data. Writing to the register initiates the data transmission when in Host mode while preparing data for sending in Client mode. The byte written to the register shifts out on the SPI output line when a transaction is initiated.

The SPIn.DATA register is not a physical register. Depending on what mode is configured, it is mapped to other registers, as described below.

  • Normal mode:
    • Writing the DATA register will write the shift register
    • Reading from DATA will read from the Receive Data register
  • Buffer mode:
    • Writing the DATA register will write to the Transmit Data Buffer register
    • Reading from DATA will read from the Receive Data Buffer register. The contents of the Receive Data register will then be moved to the Receive Data Buffer register.