Serial port name is object variable

This commit is contained in:
Siegfried Siegert 2023-06-30 10:39:24 +02:00
parent f76a30cb07
commit 37d45f3c69
Signed by: SiegfriedSiegert
GPG Key ID: 68371E015E8F0B03
2 changed files with 3 additions and 2 deletions

View File

@ -60,11 +60,11 @@ PLUGIN_STATE ATBDeviceControllerPlugin::initDCPlugin(QObject *eventReceiver, con
this->eventReceiver = eventReceiver;
// read variables from setting
QString serialPort = settings.value("DEVICE_CONTROLLER/serialPort", "ttymxc2").toString();
this->serialPortName = settings.value("DEVICE_CONTROLLER/serialPort", "ttymxc2").toString();
QByteArray printerEncoding = settings.value("DEVICE_CONTROLLER/printerEnconding", "ISO 8859-2").toString().toLatin1();
// open serial port
hw->dc_openSerial(5, "115200", serialPort, 1);
hw->dc_openSerial(5, "115200", this->serialPortName, 1);
hw->dc_autoRequest(true);

View File

@ -86,6 +86,7 @@ private:
QList<int> templateList;
QString serialPortName;
bool useDebug;