summaryrefslogtreecommitdiff
path: root/julia-arduino-master/tools/functions/ServoDetach.jl
blob: 830471c974b176a86c1970fbdbe6cc0d2880e24d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
using SerialPorts

function ServoDetach(file_des::SerialPorts.SerialPort, servo_no::Int64)
  if servo_no == 1
    pin = "Sd1"
    write(file_des,pin)
  elseif servo_no == 2
    pin = "Sd2"
    write(file_des,pin)
  else
    println("Error")
  end
end