Skip to content

Commit

Permalink
python: RCInput: add Navio+ support
Browse files Browse the repository at this point in the history
Add Navio+ entry and auto choice shield
  • Loading branch information
Igor Anokhin committed Jan 10, 2018
1 parent fd610e8 commit 5a7a23a
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions Python/RCInput.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
import sys, time
import time

import navio.rcinput
import navio.util
import navio.Common.util

navio.util.check_apm()

rcin = navio.rcinput.RCInput()
if navio.Common.util.get_navio_version() == "NAVIO2":
import navio.Navio2.RCInput as RCInput
else:
import navio.Navio.RCInput as RCInput

navio.Common.util.check_apm()

rcin = RCInput()
while (True):
period = rcin.read(2)
print period
time.sleep(1)

0 comments on commit 5a7a23a

Please sign in to comment.