Re: [Fx2lib-devel] bulkloop example crashing FX2?
Status: Beta
Brought to you by:
mulicheng
From: Dennis M. <de...@ub...> - 2009-03-03 16:34:13
|
Aric Marheine wrote: > Dennis Muhlestein wrote: > >> I just tested it out again on my CY3684/CY3674 board. Is there a >> different chip on the Cy3681 board? >> >> If you have the serial console set up, you can see what is going on by >> following the printf statements. >> >> The example certainly won't work with EA=0 though because you have to >> have interrupts enabled to >> handle the vendor commands. >> >> -Dennis >> >> > Hi Dennis, > > The FX2 on this board is a CY7C68013-128AC, not sure what chip you have > on your boards. I do indeed have SIO set up. As mentioned earlier, as > soon as the interrupts are enabled, nothing more appears to happen. I > can printf() all the way up to that point then nothing more. I've tried > adding simple printfs() to each of the ISRs that are in the example to > see if one was being called continuously or something but none of them > do seem to be. > I have the CYC68013A-128AXC. You might want to check the Cypress site and see if there are any subtle differences. There could for instance be a slight register name or location mismatch between different chip versions. I know there are some differences between the FX and FX2 chips but I don't know which model numbers fall under which category. > My compiler setup seems ok as I can compile and test programs like > "lights" and my own app which does some port I/O. Could it be that some > interrupt vector is being called which doesn't have an ISR in the > example? I don't understand why it would work for you(and others, I > guess) but not me. I think I'll go over all the interrupts and be sure > that no others are being enabled which shouldn't be. > That will indeed cause problems if you have an interrupt firing but don't clear it (it'll go in a loop and pretty much nothing else will execute.) printf is a bad thing to put in the interrupt routines though. I prefer to test each one with a light instead. If you narrow it down to something that causes your program to break, you could send a test case that I can check on my board. It would be nice to have the library be smart enough to work across more than my variant of the Cypress chip if that is the problem. -Dennis |