...
This commit is contained in:
30
internal/PinControlService/HardwarePinEmu.go
Normal file
30
internal/PinControlService/HardwarePinEmu.go
Normal file
@@ -0,0 +1,30 @@
|
||||
//go:build !arm && !arm64
|
||||
|
||||
package PinControlService
|
||||
|
||||
type PinEmu struct {
|
||||
}
|
||||
|
||||
func (*PinEmu) Toggle() {}
|
||||
func (*PinEmu) High() {}
|
||||
func (*PinEmu) Low() {}
|
||||
func (*PinEmu) Input() {}
|
||||
func (*PinEmu) Output() {}
|
||||
func (*PinEmu) Detect(Edge) {}
|
||||
func (*PinEmu) PullUp() {}
|
||||
func (*PinEmu) PullDown() {}
|
||||
func (*PinEmu) PullOff() {}
|
||||
func (*PinEmu) Read() State { return LowState }
|
||||
func (*PinEmu) EdgeDetected() bool { return false }
|
||||
|
||||
type HardwarePin struct {
|
||||
Pin PinEmu
|
||||
}
|
||||
|
||||
func NewHardwarePin(n int) HardwarePinInterface {
|
||||
return &PinEmu{}
|
||||
}
|
||||
|
||||
func HardwarePinOpen() error {
|
||||
return nil
|
||||
}
|
||||
Reference in New Issue
Block a user