Events 计时器()不';毫秒不能工作

Events 计时器()不';毫秒不能工作,events,julia,Events,Julia,我需要每0.05秒调用一个函数,但计时器的粒度似乎最低,只有一秒: Timer(function(timer) print("Hai!\n") # executed once a second end, 0.05, true) 有没有办法让计时器以毫秒为单位工作?呜呜,丢失的类型声明让我觉得第三个“repeat”参数是Bool,但实际上是时间。因此true被转换为1。问题“已解决” 正确: Timer(function(timer) print("Hai!\n") # exec

我需要每0.05秒调用一个函数,但
计时器
的粒度似乎最低,只有一秒:

Timer(function(timer)
    print("Hai!\n") # executed once a second
end, 0.05, true)

有没有办法让计时器以毫秒为单位工作?

呜呜,丢失的类型声明让我觉得第三个“repeat”参数是Bool,但实际上是时间。因此
true
被转换为1。问题“已解决”

正确:

Timer(function(timer)
    print("Hai!\n") # executed every 0.05 seconds now
end, 0, 0.05) # callback, delay time in seconds, repeat time in seconds

请将答案复制到答案框中,而不是编辑问题:)哎,哎,船长