Skip to content

Navigation Menu

Sign in
Sign up

Latest commit

History

26 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

Example

package main
import (
	"log"
	"github.com/goburrow/serial"
)
func main() {
	port, err := serial.Open(&serial.Config{Address: "/dev/ttyUSB0"})
	if err != nil {
		log.Fatal(err)
	}
	defer port.Close()
	_, err = port.Write([]byte("serial"))
	if err != nil {
		log.Fatal(err)
	}
}

Testing

Linux and Mac OS

  • socat -d -d pty,raw,echo=0 pty,raw,echo=0
  • on Mac OS, the socat command can be installed using homebrew: brew install socat

Windows

About

Go (golang) serial library for modbus

Resources

Stars

210 stars

Watchers

7 watching

Forks

Releases

Packages

Used by

Contributors

Languages

AltStyle によって変換されたページ (->オリジナル) /