SLAAEU2 August 2025 MSPM0C1104
MSPM0C1104 communicate with MCF8315D over an I2C serial interface. MSPM0C1104 works as I2C controller, MCF8315D works as I2C target. The I2C communication follows the I2C data word format shown in Table 3-2.
| TARGET_ID | R/W | CONTROL WORD | DATA | CRC-8 |
|---|---|---|---|---|
| A6 - A0 | W0 | CW23 - CW0 | D15, D31, D63 - D0 | C7 - C0 |
Target ID and R/W Bit: The first byte includes the 7-bit I2C target ID, followed by the read or write command bit. Every packet in MCF8315D the communication protocol starts with writing a 24-bit control word, hence, the R/W bit is always 0.
24-bit Control Word: The control word format is shown in Table 3-2 and the detailed descriptions can be found in the MCF8315D Sensorless Field Oriented Control (FOC) Integrated FET BLDC Driver data sheet. In the demo code, CRC_EN is set to 1 to enable the CRC verification, DLEN set to 01b to use 32-bit data length, and MEM_SEC and MEM_PAGE are set to 0 since all other memory sectors and pages are not for external use.
| OP_R/W | CRC_EN | DLEN | MEM_SEC | MEM_PAGE | MEM_ADDR |
|---|---|---|---|---|---|
| CW23 | CW22 | CW21- CW20 | CW19 - CW16 | CW15 - CW12 | CW11 - CW0 |
Data Bytes: the data needs to be input in corresponding MEM_ADDR and the DLEN field in the control word corresponds with the number of bytes sent in this section. In case of mismatch between number of data bytes and DLEN, the write operation is discarded.
CRC Byte: If the CRC feature is enabled in the control word, CRC byte has to be sent at the end of a write transaction. The details of CRC Byte calculation is described in 3.3.2 CRC verification and parity verification
Figure 3-2 and Figure 3-3 show the I2C read or write sequence according to MCF8315D I2C protocol. To communicate with MCF8315D properly, MCU needs to support I2C clock stretch. For more information, refer to the MSPM0C110x, MSPS003 Mixed-Signal Microcontrollers data sheet and the MCF8315D Sensorless Field Oriented Control (FOC) Integrated FET BLDC Driver data sheet.
Figure 3-2 MCF8315D I2C Write Transaction
Sequence
Figure 3-3 MCF8315D I2C Read Transaction
Sequence