I'm using MQX 4.2.0, and a MK60DN512VLQ10.
I'm trying to send some information by SPI with fopen, fwrite, etc. The problem is that spi outputs are not working. There are nothing in the outputs. No Signal, nothing. I check my _bsp_dspi_io_initand it is in the right pines. I don't know if there is a configuration that aren't allow me to produce a SPI.
Original Attachment has been moved to: user_config.h.zip
What we need to do is the BSPCFG_ENABLE_SPIx macro must be set to 1 in the user_config.h. I noticed in your config file, this macro is set.
Do you use the TWR-K60D100M board or your custom board? and your device is a master or a slave ?
I think you need to check the connection between the master and slave first.
Here is a SPI demo in MQX installation folder, you can refer to it.
Hi Norberto Jiménez
Just for information, the SPI demo creates one task for spi master, which is responsible for configuring the SPI protocol, erasing memory in memory board and reading data from and writing data the the memory board. The MCU is the master and the SPI serial flash memroy is the slave in the SPI data transfer.
you need to connect your TWR-MCU board with TWR-MEM board when you test the SPI demo.
Please also check your jumper setting in your TWR-MEM board
J4: Serial Flash Configuration options 1-2
J14: Serial Flash Chip-select 1-2