Hello Michael,
I executed the folowing steps to switch to SPI2:
1. One change in the twrk60f120m.h to define BSP_SPI_MEMORY_CHANNEL as 2
2. two changes in the user_config.h to disable BSPCFG_ENABLE_SPI0 and enable BSPCFG_ENABLE_SPI2
3. A new build of the MQX
4. A new build of the spi example program
In addition please verify the below configuration in the that you have the below configuration in the init_gpio.c file.
Case 2:
/* Configure GPIOD for DSPI2 peripheral function */
pctl = (PORT_MemMapPtr)PORTB_BASE_PTR;
pctl->PCR[20] = PORT_PCR_MUX(2); /* DSPI2.PCS0 */
pctl->PCR[21] = PORT_PCR_MUX(2); /* DSPI2.SCK */
pctl->PCR[22] = PORT_PCR_MUX(2); /* DSPI2.SOUT */
pctl->PCR[23] = PORT_PCR_MUX(2); /* DSPI2.SIN */
Have a great day,
Sol
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------