Is the reception working with the SPI on the FRDM-K66?

Showing results for 
Search instead for 
Did you mean: 

Is the reception working with the SPI on the FRDM-K66?

Contributor III

Hello everyone,

I am working on the FRDM-K66 with MCUXpresso new release.

I have been working on the SPI communication for a long time and only the master emission works.

The master and slave receptions don't work with my code. Besides the reception function on SDK examples (polling and interrupt) doesn't seem to work too. With Kinetis ans MCUXpresso (which SPI1 can't be monitored).

Furthermore, RX FIFO registers (SPIx_RXFRn) are always empty especially when it should receive incoming data.

The second issue is the slave transmission. The TX FIFO registers are full during slave transmission but no signal appears on the scope when its channel is plugged on the MISO once the command line is executed (write in PUSHR_SLAVE).

Just below here is a screenshot of the SDK DSPI polling example from MCUXpresso.


Do you have any idea for these issues?

I also understood that the SPI1 monitoring issue come from MCUXpresso.

Does someone know when it will be resolved?

Is the reception working with the SPI on the FRDM-K66 for master and slave or not for the moment?

I need to know because I have already spent a lot of time on this topic for no conclusive results.

Best regards,


0 Kudos
2 Replies

NXP Employee
NXP Employee

Hi Benjamin Heder

Could you clarify what you mean with The master and slave receptions don't work with my code. Did you modify the example code in some way?

I tested the example code under \frdmk66f\driver_examples\dspi\polling_transfer\ and Interrupt_transfer, both of them worked for me and I could see the signal in both MOSI and MISO.


Have a great day,
Jorge Alcala

Note: If this post answers your question, please click the Correct Answer button. Thank you!

0 Kudos

Contributor III

Hello Jorge,

I didn't modify the example code. I just imported DSPI polling example and DSPI interrupt example on MCUXpresso 10.0.2.

I have a channel of a scope on MISO and another on MOSI.

In DSPI_polling_transfer

First of all I imported SDK example with "Import SDK Example".

Then I start debugging but it opens "startup_mk66f18" file, and mouse cursor is put on Hardfault_Handler...


Then when"DSPI_SlaveTransferNonBlocking(EXAMPLE_DSPI_SLAVE_BASEADDR, &g_s_handle, &slaveXfer);"

fonction line is executed nothing appears on the scope and transmission registers are empty (0x0).

Then when "DSPI_MasterTransferBlocking(EXAMPLE_DSPI_MASTER_BASEADDR, &masterXfer);"

fonction line is executed something appears on the scope and TX registers are full but RX registers are full of 0xff.


Clock issues ?

Therefore in my opinion this code only works to send data from the master.

In DSPI_interrupt_transfer

After "DSPI_SlaveTransferNonBlocking(EXAMPLE_DSPI_SLAVE_BASEADDR, &g_s_handle, &slaveXfer);"

I have this:


So slave transmission should be good.

And after "DSPI_MasterTransferNonBlocking(EXAMPLE_DSPI_MASTER_BASEADDR, &g_m_handle, &masterXfer);"

I also have this :


And even sometimes I have 0x0 in RX registers for both files...

Maybe these codes allow transmission. However it doesn't seem to work perfectly for me...

Do you have an idea?

Could you please send me your file?

Best regards,

Benjamin Heder

0 Kudos