mirror of
https://github.com/g4klx/MMDVMHost.git
synced 2026-04-04 14:07:36 +00:00
Make the modem speed dynamic with a default of 115200.
This commit is contained in:
parent
9d08f1605c
commit
303a0163d3
13 changed files with 746 additions and 746 deletions
10
Display.cpp
10
Display.cpp
|
|
@ -511,7 +511,7 @@ CDisplay* CDisplay::createDisplay(const CConf& conf, CUMP* ump, CModem* modem)
|
|||
if (port == "modem")
|
||||
serial = new CModemSerialPort(modem);
|
||||
else
|
||||
serial = new CSerialController(port, (type == "TFT Serial") ? SERIAL_9600 : SERIAL_115200);
|
||||
serial = new CSerialController(port, (type == "TFT Serial") ? 9600U : 115200U);
|
||||
|
||||
if (type == "TFT Surenoo")
|
||||
display = new CTFTSurenoo(conf.getCallsign(), dmrid, serial, brightness, conf.getDuplex());
|
||||
|
|
@ -565,11 +565,11 @@ CDisplay* CDisplay::createDisplay(const CConf& conf, CUMP* ump, CModem* modem)
|
|||
display = new CNullDisplay;
|
||||
}
|
||||
} else {
|
||||
SERIAL_SPEED baudrate = SERIAL_9600;
|
||||
if (screenLayout==4U)
|
||||
baudrate = SERIAL_115200;
|
||||
unsigned int baudrate = 9600U;
|
||||
if (screenLayout == 4U)
|
||||
baudrate = 115200U;
|
||||
|
||||
LogInfo(" Display baudrate: %u ",baudrate);
|
||||
LogInfo(" Display baudrate: %u ", baudrate);
|
||||
ISerialPort* serial = new CSerialController(port, baudrate);
|
||||
display = new CNextion(conf.getCallsign(), dmrid, serial, brightness, displayClock, utc, idleBrightness, screenLayout, txFrequency, rxFrequency, displayTempInF, conf.getLocation());
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue