38 lines
815 B
Python
Raw Normal View History

2022-01-20 19:56:43 +08:00
from PikaObj import *
import PikaStdData
2022-01-23 21:50:05 +08:00
2022-01-20 19:56:43 +08:00
class Task(TinyObj):
2022-01-24 18:50:20 +08:00
calls = PikaStdData.List()
2022-01-23 21:50:05 +08:00
2022-01-20 19:56:43 +08:00
def __init__():
pass
# regist a function to be called always
2022-01-20 19:56:43 +08:00
def call_always(fun_todo: any):
pass
# regist a function to be called when fun_when() return 'True'
2022-01-20 21:50:38 +08:00
def call_when(fun_todo: any, fun_when: any):
2022-01-20 19:56:43 +08:00
pass
# regist a function to be called periodically
2022-01-23 21:50:05 +08:00
def call_period_ms(fun_todo: any, period_ms: int):
pass
# run all registed function once
2022-01-20 19:56:43 +08:00
def run_once():
pass
# run all registed function forever
def run_forever():
2022-01-20 19:56:43 +08:00
pass
2022-01-23 21:50:05 +08:00
# run all registed function until time is up
2022-01-24 19:34:43 +08:00
def run_until_ms(until_ms: int):
pass
# need be overried to supply the system tick
2022-01-23 21:50:05 +08:00
def platformGetTick():
pass