Changeset View
Changeset View
Standalone View
Standalone View
src/core/atcore.h
1 | /* AtCore | 1 | /* AtCore | ||
---|---|---|---|---|---|
2 | Copyright (C) <2016> | 2 | Copyright (C) <2016 - 2018> | ||
3 | 3 | | |||
4 | Authors: | 4 | Authors: | ||
5 | Tomaz Canabrava <tcanabrava@kde.org> | 5 | Tomaz Canabrava <tcanabrava@kde.org> | ||
6 | Chris Rizzitello <rizzitello@kde.org> | 6 | Chris Rizzitello <rizzitello@kde.org> | ||
7 | Patrick José Pereira <patrickjp@kde.org> | 7 | Patrick José Pereira <patrickjp@kde.org> | ||
8 | Lays Rodrigues <lays.rodrigues@kde.org> | 8 | Lays Rodrigues <lays.rodrigues@kde.org> | ||
9 | 9 | | |||
10 | This library is free software; you can redistribute it and/or | 10 | This library is free software; you can redistribute it and/or | ||
Show All 10 Lines | |||||
21 | Lesser General Public License for more details. | 21 | Lesser General Public License for more details. | ||
22 | 22 | | |||
23 | You should have received a copy of the GNU Lesser General Public | 23 | You should have received a copy of the GNU Lesser General Public | ||
24 | License along with this library. If not, see <http://www.gnu.org/licenses/>. | 24 | License along with this library. If not, see <http://www.gnu.org/licenses/>. | ||
25 | */ | 25 | */ | ||
26 | #pragma once | 26 | #pragma once | ||
27 | 27 | | |||
28 | #include <QObject> | 28 | #include <QObject> | ||
29 | #include <QSerialPort> | ||||
29 | #include <QSerialPortInfo> | 30 | #include <QSerialPortInfo> | ||
30 | 31 | | |||
31 | #include "ifirmware.h" | 32 | #include "ifirmware.h" | ||
32 | #include "temperature.h" | 33 | #include "temperature.h" | ||
33 | #include "atcore_export.h" | 34 | #include "atcore_export.h" | ||
34 | 35 | | |||
35 | class SerialLayer; | 36 | class SerialLayer; | ||
36 | class IFirmware; | 37 | class IFirmware; | ||
▲ Show 20 Lines • Show All 207 Lines • ▼ Show 20 Line(s) | 244 | signals: | |||
244 | 245 | | |||
245 | /** | 246 | /** | ||
246 | * @brief Message emit from atcore these should be displayed to the user for debug. | 247 | * @brief Message emit from atcore these should be displayed to the user for debug. | ||
247 | * | 248 | * | ||
248 | * Possable Messages Are: | 249 | * Possable Messages Are: | ||
249 | * - Waiting for firmware detect. | 250 | * - Waiting for firmware detect. | ||
250 | * - No Plugin found for (detected FW) | 251 | * - No Plugin found for (detected FW) | ||
251 | * - Failed to open device in Read / Write mode. | 252 | * - Failed to open device in Read / Write mode. | ||
253 | * - Device Errors. | ||||
252 | * @param msg: the message. | 254 | * @param msg: the message. | ||
253 | */ | 255 | */ | ||
254 | void atcoreMessage(const QString &msg); | 256 | void atcoreMessage(const QString &msg); | ||
255 | 257 | | |||
256 | /** | 258 | /** | ||
257 | * @brief New number of extruders | 259 | * @brief New number of extruders | ||
258 | * @sa extruderCount(), setExtruderCount(int newCount) | 260 | * @sa extruderCount(), setExtruderCount(int newCount) | ||
259 | */ | 261 | */ | ||
▲ Show 20 Lines • Show All 239 Lines • ▼ Show 20 Line(s) | 475 | private slots: | |||
499 | */ | 501 | */ | ||
500 | void locateSerialPort(); | 502 | void locateSerialPort(); | ||
501 | 503 | | |||
502 | /** | 504 | /** | ||
503 | * @brief Send request to the printer for the sd card file list. | 505 | * @brief Send request to the printer for the sd card file list. | ||
504 | */ | 506 | */ | ||
505 | void getSDFileList(); | 507 | void getSDFileList(); | ||
506 | 508 | | |||
509 | /** | ||||
510 | * @brief Handle serial Errors. | ||||
511 | */ | ||||
512 | void handleSerialError(QSerialPort::SerialPortError error); | ||||
513 | | ||||
507 | private: | 514 | private: | ||
508 | /** | 515 | /** | ||
509 | * @brief True if a firmware plugin is loaded | 516 | * @brief True if a firmware plugin is loaded | ||
510 | */ | 517 | */ | ||
511 | bool firmwarePluginLoaded() const; | 518 | bool firmwarePluginLoaded() const; | ||
512 | 519 | | |||
513 | /** | 520 | /** | ||
514 | * @brief True if a serial port is initialized | 521 | * @brief True if a serial port is initialized | ||
▲ Show 20 Lines • Show All 63 Lines • Show Last 20 Lines |