Micropython-based on utime library to realize the timing of program execution time

utime-time related functions

For specific API usage, please refer to the official document above.

The following is the timing code of the test program:

import utime

start = utime.ticks_ms()
'''
你需要测试运行时间的程序
'''
end = utime.ticks_ms()
print("running time:", end - start)

Guess you like

Origin blog.csdn.net/qq_45779334/article/details/112791096