Re: [Fx2lib-devel] Interrupting on GPIF idle
Status: Beta
Brought to you by:
mulicheng
From: Dennis M. <de...@ub...> - 2009-05-05 16:34:47
|
Eric Winsor wrote: > In the Cypress frameworks code (pariph.c) there are two interrupt functions: > > void ISR_GpifComplete(void) interrupt 0 > { > } > void ISR_GpifWaveform(void) interrupt 0 > { > } > > From my study yesterday I believe that I can have ISR_GpifComplete() > execute when a GPIF transaction goes idle. I would like to use this to > count GPIF transactions and insert a USB packet containing this count > and a marker between GPIF transactions. To date I have been starting > the GPIF only with GpifInit() at the start of my firmware. Is there > another way to restart the GPIF after it goes idle without calling > GpifInit() again? > > GpifInit doesn't actuall start a transaction. You need to start the single read, single write, fifo read or fifo write explicitly each time a transaction is started. fx2lib defines all these function by the way. There are MACROS for enabling/disabling the gpif interrupts too. -Dennis |