Skip to content

Commit

Permalink
Added IP and MTU options to Monitor() implementation per FaradayRF#29
Browse files Browse the repository at this point in the history
* Added the command line arguments to the Monitor() instance
  • Loading branch information
kb1lqc committed Mar 9, 2018
1 parent dc8b037 commit ec46aae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions faradayio_cli/faradayio_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def setupArgparse():
help="Set IP Address of TUN adapter (Farday Radio)")
parser.add_argument("-l", "--loopback", action="store_true",
help="Use software loopback serial port")
parser.add_argument("-m", "--mtu", default="1500",
parser.add_argument("-m", "--mtu", default=1500,
help="Set Maximum Transmission Unit (MTU)")
parser.add_argument("-p", "--port", default="/dev/ttyUSB0",
help="Physical serial port of radio")
Expand Down Expand Up @@ -100,7 +100,7 @@ def main():

# Setup TUN adapter and start
try:
tun = Monitor(serialPort=serialPort, name=tunName, isRunning=isRunning)
tun = Monitor(serialPort=serialPort, name=tunName, isRunning=isRunning, addr=args.addr, mtu=int(args.mtu))
tun.start()

except pytun.Error as error:
Expand Down

0 comments on commit ec46aae

Please sign in to comment.