浏览代码

expose ccmicros for testing

micros() unchanged - minor systick_isr() diversion - one line added to systick_isr.
teensy4-core
Defragster 6 年前
父节点
当前提交
8cb4de3469
没有帐户链接到提交者的电子邮件
共有 1 个文件被更改,包括 5 次插入5 次删除
  1. +5
    -5
      teensy4/delay.c

+ 5
- 5
teensy4/delay.c 查看文件

@@ -62,7 +62,8 @@ void delay(uint32_t msec)
// TODO...
}

uint32_t micros(void)
extern uint32_t ccmicros(void);
uint32_t ccmicros(void)
{
uint32_t ccdelta, usec, smc, scc;
do {
@@ -74,9 +75,8 @@ uint32_t micros(void)
return usec;
}

#if 0 // kept to compare test to cycle count micro()
extern uint32_t otmicros(void);
uint32_t otmicros(void)
//#if 0 // kept to compare test to cycle count micro()
uint32_t micros(void)
{
uint32_t msec, tick, elapsed, istatus, usec;
//static uint32_t prev_msec=0;
@@ -133,4 +133,4 @@ uint32_t otmicros(void)
prev_usec = usec;
return usec;
}
#endif
//#endif

正在加载...
取消
保存