From 856d590eeba1a9619768d5183d7c751678482c57 Mon Sep 17 00:00:00 2001 From: Akira Naru Takizawa Date: Sat, 19 Oct 2019 21:30:06 +0200 Subject: [PATCH] Use baud rate from lora.conf or default --- rn2483lora/cli.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/rn2483lora/cli.py b/rn2483lora/cli.py index 8aa65c7..eb7c2e3 100644 --- a/rn2483lora/cli.py +++ b/rn2483lora/cli.py @@ -13,7 +13,10 @@ if __name__ == '__main__': conf = ConfigParser() conf.read("lora.conf") - root = RN2483(conf.get("DEFAULT", "port")) + root = RN2483( + conf.get("DEFAULT", "port"), + conf.get("DEFAULT", "baud", fallback=57600), + ) def first_init() -> None: """Init our RN2483 after firmware startup."""