Changeset View
Changeset View
Standalone View
Standalone View
src/core/atcore.cpp
Show First 20 Lines • Show All 402 Lines • ▼ Show 20 Line(s) | 400 | if (firmwarePluginLoaded()) { | |||
---|---|---|---|---|---|
403 | if (firmwarePlugin()->name() != QStringLiteral("Grbl")) { | 403 | if (firmwarePlugin()->name() != QStringLiteral("Grbl")) { | ||
404 | disconnect(d->tempTimer, &QTimer::timeout, this, &AtCore::checkTemperature); | 404 | disconnect(d->tempTimer, &QTimer::timeout, this, &AtCore::checkTemperature); | ||
405 | d->tempTimer->stop(); | 405 | d->tempTimer->stop(); | ||
406 | } | 406 | } | ||
407 | //Attempt to unload the firmware plugin. | 407 | //Attempt to unload the firmware plugin. | ||
408 | QString name = firmwarePlugin()->name(); | 408 | QString name = firmwarePlugin()->name(); | ||
409 | QString msg = d->pluginLoader.unload() ? QStringLiteral("closed.") : QStringLiteral("Failed to close."); | 409 | QString msg = d->pluginLoader.unload() ? QStringLiteral("closed.") : QStringLiteral("Failed to close."); | ||
410 | qCDebug(ATCORE_CORE) << QStringLiteral("Firmware plugin %1 %2").arg(name, msg); | 410 | qCDebug(ATCORE_CORE) << QStringLiteral("Firmware plugin %1 %2").arg(name, msg); | ||
411 | d->firmwarePlugin = nullptr; | ||||
411 | } | 412 | } | ||
412 | //Do not reset the connect on disconnect when closing this will cause a reset on connect for the next connection. | 413 | //Do not reset the connect on disconnect when closing this will cause a reset on connect for the next connection. | ||
413 | disconnect(d->serial, &SerialLayer::serialError, this, &AtCore::handleSerialError); | 414 | disconnect(d->serial, &SerialLayer::serialError, this, &AtCore::handleSerialError); | ||
414 | disconnect(d->serial, &SerialLayer::pushedCommand, this, &AtCore::newMessage); | 415 | disconnect(d->serial, &SerialLayer::pushedCommand, this, &AtCore::newMessage); | ||
415 | d->serial->close(); | 416 | d->serial->close(); | ||
416 | //Clear our copy of the sdcard filelist | 417 | //Clear our copy of the sdcard filelist | ||
417 | clearSdCardFileList(); | 418 | clearSdCardFileList(); | ||
418 | setState(AtCore::STATES::DISCONNECTED); | 419 | setState(AtCore::STATES::DISCONNECTED); | ||
▲ Show 20 Lines • Show All 443 Lines • Show Last 20 Lines |