Forum Discussion
Altera_Forum
Honored Contributor
16 years agoalt_nticks() stopped working?
in my app, i have used alt_nticks() before and it worked fine. sometime lately(?) it stopped working. For instance:
alt_u32 deltaTicks = alt_nticks(); usleep(1000000); alt_u32 MoreTicks = alt_nticks(); fprintf(stdout,"%uL %uL %uL\n",MoreTicks , deltaTicks); Every time I loop thru this code deltaTicks and MoreTicks each equal the same value. It appears to work on the first call, but after that the return value from alt_nticks() is *always* the same value. What could cause this? I know it is self inflicted, I just don't know what I could have done elsewhere to cause this kind of behavior. thanks2 Replies
- Altera_Forum
Honored Contributor
Is the compiler optimizing away the second call to alt_nticks()?
- Altera_Forum
Honored Contributor
Did you change your BSP or System Library. Make sure you've still got your system timer set up.
Jake