Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
16 years ago

alt_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.

thanks

2 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Did you change your BSP or System Library. Make sure you've still got your system timer set up.

    Jake