Skip to content

Commit

Permalink
lavalab-gen: Fix ser2net_keepopen
Browse files Browse the repository at this point in the history
Fix typo in ser2net_keepopen

Signed-off-by: Alice Ferrazzi <[email protected]>
  • Loading branch information
aliceinwire authored and montjoie committed Dec 4, 2022
1 parent 871a31c commit 56a03a1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lavalab-gen.py
Original file line number Diff line number Diff line change
Expand Up @@ -710,13 +710,13 @@ def main():
dockcomp_add_device(dockcomp, worker_name, "/dev/%s:/dev/%s" % (board_name, board_name))
use_conmux = False
use_ser2net = False
set2net_keepopen = False
ser2net_keepopen = False
if "use_conmux" in uart:
use_conmux = uart["use_conmux"]
if "use_ser2net" in uart:
use_ser2net = uart["use_ser2net"]
if "set2net_keepopen" in uart:
set2net_keepopen = uart["set2net_keepopen"]
if "ser2net_keepopen" in uart:
ser2net_keepopen = uart["ser2net_keepopen"]
if (use_conmux and use_ser2net):
print("ERROR: Only one uart handler must be configured")
sys.exit(1)
Expand All @@ -740,7 +740,7 @@ def main():
fp.write("connection: &con%d\n" % ser2net_ports[worker_name])
fp.write(" accepter: telnet(rfc2217),tcp,%d\n" % ser2net_ports[worker_name])
fp.write(" enable: on\n")
if set2net_keepopen:
if ser2net_keepopen:
ser2net_yaml_line= " connector: keepopen(retry-time=2000,discard-badwrites),serialdev,/dev/%s,%dn81,local" % (board_name, baud)
else:
ser2net_yaml_line = " connector: serialdev,/dev/%s,%dn81,local" % (board_name, baud)
Expand Down

0 comments on commit 56a03a1

Please sign in to comment.