I want to config the register of a chip through SPI module of MPC5744P.
I want to clear the register of address 0x06.
My relevant configuration code is as follows:
MC_ME.PCTL99.B.RUN_CFG = 0x0; /* DSPI_0: select peri. cfg. RUN_PC
SPI_0.MCR.R = 0x80010001; /* Configure DSPI_0 as master */
SPI_0.MODE.CTAR.R = 0x78AA0220; /* Configure CTAR0 */
SPI_0.MCR.B.HALT = 0x0; /* Exit HALT mode: go from STOPPED to RUNNING state*/
//the message I need to sent to the chip is 0x3400
SPI_0.PUSHR.PUSHR.R = 0x08013400;
are there any mistakes in my code?