Set serialPort name from config
This commit is contained in:
parent
bbce2b02e3
commit
080c00eda1
@ -20,10 +20,10 @@ PLUGIN_STATE ATBDeviceControllerPlugin::initDCPlugin(QObject *healthEventReceive
|
|||||||
{
|
{
|
||||||
this->healthEventReceiver = healthEventReceiver;
|
this->healthEventReceiver = healthEventReceiver;
|
||||||
|
|
||||||
// Read a sample variable from setting
|
// read variables from setting
|
||||||
QString sampleSetting = settings.value("DEVICE_CONTROLLER/sampleVariable", "defaultValue").toString();
|
QString serialPort = settings.value("DEVICE_CONTROLLER/serialPort", "ttymxc2").toString();
|
||||||
|
|
||||||
hw->dc_openSerial(5, "115200", "ttymxc2", 1);
|
hw->dc_openSerial(5, "115200", serialPort, 1);
|
||||||
|
|
||||||
this->pluginState = PLUGIN_STATE::INITIALIZED;
|
this->pluginState = PLUGIN_STATE::INITIALIZED;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user