Processor time

Hello,

I’m using Connect ME 9210 with NET+OS.

I need to get processor clock time (number of ticks elapsed since the program was launched). So that I can compute how long the program has been running.
I noticed the function ‘clock()’ is used for this purpose, but I’m always getting zero.

Do I need to change some system configuration to make it work or is there any other way to get the processor time in NET+OS.

Thank you for answer

Look at ULONG tx_time_get(void);

Or, for time in seconds:
unsigned long ns_get_uptime_sec(void);

in sys/util/nsuptime.*

1 Like

Thanks very much.
ns_get_uptime_sec() is exactly what I needed.