mirror of
https://github.com/markqvist/Reticulum.git
synced 2025-05-20 15:20:59 -04:00
Conditional imports for serial-based interfaces
This commit is contained in:
parent
259c2aa397
commit
c44c6f9086
4 changed files with 4 additions and 0 deletions
|
@ -39,6 +39,7 @@ class KISSInterface(Interface):
|
|||
serial = None
|
||||
|
||||
def __init__(self, owner, name, port, speed, databits, parity, stopbits, preamble, txtail, persistence, slottime, flow_control, beacon_interval, beacon_data):
|
||||
import importlib
|
||||
if importlib.util.find_spec('serial') != None:
|
||||
import serial
|
||||
else:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue