How to add or use 5th timer in robotC?

Hi,

I found that there is a limit of 4 timer (variables) to be used in RobotC. As we need to put timer conditions in more than 4 places in the program, could they be reused after a reset command? it seems to be not working.

thanks,

Jason

You can reset and reuse timers. Can you post your code? Remember to start and end with three ’ to get the code formatting.

Well, Timer is noting more than a resettable offset from the system time, so nothing prevents you from implementing your own timers. You can use the nSysTime variable (number of milliseconds since, like, boot?).
At the start of the interval, you’ll capture the current value of nSysTime, then every time you need the elapsed time, you just subtract that captured value from current nSysTime…

thanks, i’ll experiment a little more.