Transmitting
Sending data to the card
If the Clock Bit isn't 0 or the Multiplier Select is 0 (in the LoCoMo SPI Mode register)
For each byte to send:
- Wait for the Write Ready bit in the LoCoMo SPI Status register to be set (Number of busy loops depends on the clock, see below)
- Write one byte to LoCoMo SPI TX Data Write
- Wait for the Write Ready bit in the LoCoMo SPI Status register to be set (Number of busy loops depends on the clock, see below)
Otherwise
For each byte to send:
- Wait for the Write Ready bit in the LoCoMo SPI Status register to be set (Busy loop up to 8 times)
- Write one byte to LoCoMo SPI TX Data Write
After transmitting the bits above, wait for the Transfer Complete bit to be set in the LoCoMo SPI Status register (Number of busy loops depends on the clock, see below)
Max Wait Table
Check the LoCoMo SPI Status register on each loop
| Clock Bit Value | Wait Loops |
| 4 | 0x10001 |
| Otherwise | 0xA |