mirror of
https://github.com/hybridgroup/gobot.git
synced 2025-04-27 13:48:56 +08:00
20 lines
307 B
Go
20 lines
307 B
Go
package gobot
|
|
|
|
import "fmt"
|
|
|
|
type Driver struct {
|
|
Interval string
|
|
Pin string
|
|
Name string
|
|
Params map[string]string
|
|
Events map[string]chan interface{} `json:"-"`
|
|
}
|
|
|
|
func NewDriver(d Driver) Driver {
|
|
return d
|
|
}
|
|
|
|
func (d *Driver) Start() {
|
|
fmt.Println("Starting driver " + d.Name + "...")
|
|
}
|