Forum Discussion
Altera_Forum
Honored Contributor
9 years ago --- Quote Start --- Thank you for your replying We decided to use SPI or I2C. The thing I wanna do for the moment is really simple, CPU send a signal, then FPGA received that signal and light up a LED. But still, how could I checked in quartus if I received correctly the signal from CPU. I've never communicate FPGA and CPU before thanks a lot --- Quote End --- If you're just testing the GPIO, the easiest way is toggle a GPIO on the i.MX7, and directly wire that output in the FPGA to an LED (pass through). If you want to just confirm the signal is reaching the FPGA, you can use a clock, register the input, and look at it using SignalTap, the Altera built-in logic analyzer tool. I'd recommend using SPI, as it is a faster protocol, and really worth understanding if doing firmware development. Now, if you're using SPI things get a bit more complicated. You probably want to start by experimenting with an n-bit SPI word from the i.MX, and decode the message in the FPGA. SPI works that whenever the chip select goes low, data is clocked in to the slave device using the SPI clock at some rate. Once chip select goes high, the data is valid, and the FPGA can then process the received message. Or just tie the chip select from the i.MX to an FPGA output, and probe the signals. Lots of options!