hybridgroup.gobot/examples/hello.go

19 lines
201 B
Go
Raw Normal View History

2013-10-23 07:45:31 +08:00
package main
import (
2013-11-14 12:47:21 +08:00
"fmt"
. "gobot"
"time"
2013-10-23 07:45:31 +08:00
)
func main() {
2013-11-14 12:47:21 +08:00
robot := Robot{
Work: func() {
Every(300*time.Millisecond, func() { fmt.Println("Greetings human") })
},
}
robot.Start()
2013-10-23 07:45:31 +08:00
}