Motorola ONCE SC140 Application Note page 23

Enhanced once stopwatch timer
Table of Contents

Advertisement

Appendix A
Complete Example of Profiling
A complete example of profiling using the Enhanced OnCE stopwatch timer in the SC140 platform is
presented in this appendix.
typedef enum { EONCE_SECOND, EONCE_MILLISECOND, EONCE_MICROSECOND } tunit;
#define READ_IOREG(reg,val) val = *((volatile long *)reg)
#define WRITE_IOREG(reg,val) *((volatile long *)reg) = val
#define MAX_32_BIT 0xffffffff
void EOnCE_stopwatch_timer_init();
void EOnCE_stopwatch_timer_start();
void EOnCE_stopwatch_timer_stop(unsigned long *clock_ext, unsigned long *clock_val);
void EOnCE_LED_init();
void EOnCE_LED_off();
unsigned long Convert_clock2time(unsigned long clock_ext, unsigned long clock_val, short option);
Code A-1. EOnCE_stopwatch.h
Complete Example of Profiling
A-1

Advertisement

Table of Contents
loading

Table of Contents