require "import"
import "com.androlua.Ticker"
if ti then
ti.stop()
service.speak("整点报时已关闭")
ti=nil
return true end
ti=Ticker()
ti.Period=900
ti.onTick=function()
if
os.date("%M:%S")=="00:00"
then
service.speak(os.date("%H:%M:%S"))return true
end
end
ti.start()
service.speak("已开启了整点报时")return true