2026-04-26 04:43:50 +00:00
|
|
|
//go:build !linux && !darwin && !windows
|
|
|
|
|
|
|
|
|
|
package hardwaretools
|
|
|
|
|
|
|
|
|
|
import (
|
2026-04-28 04:57:09 +00:00
|
|
|
"context"
|
2026-04-26 04:43:50 +00:00
|
|
|
"fmt"
|
|
|
|
|
"time"
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
func serialListPorts() ([]serialPortInfo, error) {
|
2026-04-28 04:56:47 +00:00
|
|
|
return nil, fmt.Errorf("serial is not supported on this platform")
|
2026-04-26 04:43:50 +00:00
|
|
|
}
|
|
|
|
|
|
2026-04-28 04:57:09 +00:00
|
|
|
func serialRead(ctx context.Context, cfg serialConfig, length int, timeout time.Duration) ([]byte, error) {
|
2026-04-26 04:43:50 +00:00
|
|
|
return nil, fmt.Errorf("serial is not supported on this platform")
|
|
|
|
|
}
|
|
|
|
|
|
2026-04-28 04:57:09 +00:00
|
|
|
func serialWrite(ctx context.Context, cfg serialConfig, data []byte, timeout time.Duration) (int, error) {
|
2026-04-26 04:43:50 +00:00
|
|
|
return 0, fmt.Errorf("serial is not supported on this platform")
|
|
|
|
|
}
|