mirror of
https://github.com/tinygo-org/drivers.git
synced 2026-08-18 13:43:58 +00:00
all: refactor all current drivers to use new machine.Pin interface
Signed-off-by: Ron Evans <ron@hybridgroup.com>
This commit is contained in:
+2
-2
@@ -8,12 +8,12 @@ import (
|
||||
|
||||
// Device wraps a pin object for an easy driver interface.
|
||||
type Device struct {
|
||||
Pin machine.GPIO
|
||||
Pin machine.Pin
|
||||
}
|
||||
|
||||
// New returns a new WS2812 driver. It does not touch the pin object: you have
|
||||
// to configure it as an output pin before calling New.
|
||||
func New(pin machine.GPIO) Device {
|
||||
func New(pin machine.Pin) Device {
|
||||
return Device{pin}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user