diff options
author | Harsh Sharma <harsh.sharma@multitech.com> | 2022-03-09 16:03:00 -0600 |
---|---|---|
committer | John Klug <john.klug@multitech.com> | 2022-03-10 14:32:25 -0600 |
commit | ffd9203c66c7665afb28b25cc43bc616a5c6db45 (patch) | |
tree | 86ca0481db0943a5e7339bd918098dc2859efcab /src | |
parent | b1eaaeca6fdcb38d9a247e2deabe1da788a1e1f0 (diff) | |
download | mts-io-sysfs-ffd9203c66c7665afb28b25cc43bc616a5c6db45.tar.gz mts-io-sysfs-ffd9203c66c7665afb28b25cc43bc616a5c6db45.tar.bz2 mts-io-sysfs-ffd9203c66c7665afb28b25cc43bc616a5c6db45.zip |
Updated lora 2g4 class to support dual cards
Diffstat (limited to 'src')
-rw-r--r-- | src/AccessoryCards/LoraCard2G4.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/AccessoryCards/LoraCard2G4.cpp b/src/AccessoryCards/LoraCard2G4.cpp index 10691ce..aca092f 100644 --- a/src/AccessoryCards/LoraCard2G4.cpp +++ b/src/AccessoryCards/LoraCard2G4.cpp @@ -24,7 +24,8 @@ void Device::Lora2G4Card::AddToDeviceInfo(const std::string Port, const std::string ProductID) { LoraCard::AddToDeviceInfo(Port, ProductID); - std::string ttyPath = "/dev/ttyACM0"; + rapidjson::SizeType deviceNumber = device.accessoryCards.Size() + 1; + std::string ttyPath = "/dev/ttyACM" + std::to_string(deviceNumber); device.accessoryCard.AddMember( "ttyPath", rapidjson::Value().SetString(ttyPath.c_str(), device.acAlloc), |