Skip to content

Commit 541e76f

Browse files
committed
esp8266/modutime: Actually implement ticks_cpu().
1 parent f71f37e commit 541e76f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

esp8266/modutime.c

+1-2
Original file line numberDiff line numberDiff line change
@@ -134,8 +134,7 @@ STATIC mp_obj_t time_ticks_us(void) {
134134
STATIC MP_DEFINE_CONST_FUN_OBJ_0(time_ticks_us_obj, time_ticks_us);
135135

136136
STATIC mp_obj_t time_ticks_cpu(void) {
137-
// TODO
138-
return MP_OBJ_NEW_SMALL_INT(0 & MP_SMALL_INT_POSITIVE_MASK);
137+
return MP_OBJ_NEW_SMALL_INT(mp_hal_ticks_cpu() & MP_SMALL_INT_POSITIVE_MASK);
139138
}
140139
STATIC MP_DEFINE_CONST_FUN_OBJ_0(time_ticks_cpu_obj, time_ticks_cpu);
141140

0 commit comments

Comments
 (0)