Added SetDataBits function (linux only for now)

This commit is contained in:
Cristian Maglie
2014-12-14 18:38:44 +01:00
parent 83038c8ed9
commit 3351cd50e0
3 changed files with 30 additions and 0 deletions

View File

@@ -33,6 +33,9 @@ func ExampleCommunication() {
if err := port.SetParity(serial.PARITY_NONE); err != nil {
log.Fatal(err)
}
if err := port.SetDataBits(8); err != nil {
log.Fatal(err)
}
n, err := port.Write([]byte("10,20,30\n\r"))
if err != nil {