I am using PHYCORE iMX6 module. I am interfacing FPGA via SPI. I am able to communicate with FPGA with speeds upto 10Mhz. If I increase the SPI clock more than 10Mhz, the SCLK is getting distorted and the communication with FPGA is failing. I have a pull up resistor of 3.3K on SCLK and FPGA hardware looks fine.
SCLK waveform is slowly distorting from square to triangular as i increase the speed beyond 10Mhz. Do I need to configure any clocks in iMX6?
Hello vijesh,
In theory, the speed of SPI on i.mx6 can be up to 52MHz. According to your description, the issue you encountered is not related to CPU or software. It seems there are some issues with PCB layout.
you can try to connect a capacitor with 15pF~30pF between SCLK and GND, then check if the way can improve waveform.
Have a nice day!
Regards,
Weidong
Thanks Weidong,
I tried by adding the capacitor but found no major improvement . PCB layout looks fine as per SPI standards.
I am new to linux and have only limited knowledge on dtbs. Our linux guy has set the SPI max freq to 20Mhz in the dts file and I am changing it using IOCTL.
Don't we require any clock setting for SPI module ??