Skip to content

Commit

Permalink
Update serial_linux.go
Browse files Browse the repository at this point in the history
  • Loading branch information
colinrgodsey committed Jul 20, 2020
1 parent a6eef20 commit 31ebb6f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions serial_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,12 @@ func openPort(name string, baud int, databits byte, parity Parity, stopbits Stop

// simiulate an arduino reset using DTR
dtrFlag := unix.TIOCM_DTR
unix.Syscall6(
unix.Syscall(
unix.SYS_IOCTL,
uintptr(fd),
uintptr(unix.TIOCMBIS), // set DTR pin
uintptr(unsafe.Pointer(&dtrFlag)))
unix.Syscall6(
unix.Syscall(
unix.SYS_IOCTL,
uintptr(fd),
uintptr(unix.TIOCMBIC), // clear DTR pin
Expand Down

0 comments on commit 31ebb6f

Please sign in to comment.