Compare commits
210 Commits
v0.1-alpha
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| cf81418938 | |||
|
|
9a3af3047f | ||
|
|
f94938b372 | ||
| 60bb57f374 | |||
| 98b10de3f4 | |||
| 1589d1a4ae | |||
| 5c790251c1 | |||
| 094d7a04b3 | |||
| 1533625411 | |||
| 747b9ebe62 | |||
| b5b4af8a2e | |||
| 549d7a76f5 | |||
| de6e25391a | |||
| 705e6ef5b6 | |||
| c64598d640 | |||
| bd76f479e7 | |||
| a0fb0d588b | |||
| 5ae242b4e4 | |||
| 8469e2a6b6 | |||
| 10365239a5 | |||
| 7eabc94adf | |||
| c90153a750 | |||
| f7ff8882f2 | |||
| 169cb07d28 | |||
| ce33d5a804 | |||
| deceb81c8b | |||
| 2d6d09743e | |||
| ecc6e5570d | |||
| 136c2f1077 | |||
| a6b57d0da0 | |||
| 74ec8c9806 | |||
| 83a5f0eb1d | |||
| b986c98f9c | |||
| c4ba7c8e4f | |||
| ae27a3cc96 | |||
| 7f57b698a1 | |||
| 6e52256bd9 | |||
| 70963c8f59 | |||
| 3cc2dcabb5 | |||
| 1294d65618 | |||
| 7e18e2fd2f | |||
| 933163257d | |||
| c7b4ba29de | |||
| dd59c0c54a | |||
| 908f49389a | |||
| 2fdd05cac1 | |||
| b0190ded97 | |||
| ec902e01b6 | |||
| 2e24c28bbf | |||
| 7e354a56d7 | |||
| 9fff9d6743 | |||
| 157f3e5535 | |||
| 5f1c9d68f7 | |||
| f38e1bf069 | |||
| 6cd2ac8d2e | |||
| b24017e138 | |||
| c99f298348 | |||
| e28c4d71fc | |||
| 2f4519634a | |||
| c94afa3986 | |||
| a5a74d5581 | |||
| 17ba5d7e11 | |||
| 1b8ca64fc9 | |||
| c6aab765b5 | |||
| 079594f6dc | |||
| 61f1fc66c2 | |||
|
|
866aa1bc3d | ||
|
|
7bc963e526 | ||
| 82b444f066 | |||
| 7831246599 | |||
| 16b3adf8dc | |||
| 16de411b2d | |||
|
|
376428070c | ||
| 1162748acd | |||
| 9fa7e3d2c8 | |||
| 71bb8a7fa3 | |||
| 654c0b6546 | |||
| bdb3660134 | |||
| 12edb52d0c | |||
| a5a8dc662b | |||
| 53283605e0 | |||
| a30e869e61 | |||
| 5db118ebf6 | |||
| 8803269616 | |||
| 0942248989 | |||
| aa05845e51 | |||
| 690388624f | |||
| d62be051dd | |||
| e57406ee6b | |||
| 3f0d2a135f | |||
| fb02f184ed | |||
| 228d7abd78 | |||
| b4ce73c959 | |||
| fea7f342c1 | |||
| 314f853e40 | |||
| d007eb32d9 | |||
|
|
0942f54ab7 | ||
|
|
0b6b327b0e | ||
|
|
d33612959b | ||
|
|
81b1a73fbb | ||
|
|
20ab52821b | ||
|
|
c9f84dc22d | ||
| 527ecae540 | |||
|
|
0d1cd46bc9 | ||
| 5f8d344cc4 | |||
|
|
936e316e48 | ||
| 5331f73cc0 | |||
| cb32e983ac | |||
|
|
003d5a6bab | ||
| e17e6d2087 | |||
| 6017309bd9 | |||
| 367cbb1c0d | |||
|
|
de87588d62 | ||
| a8e8bbd333 | |||
| f10324ac81 | |||
| da63af5709 | |||
| ba4d605aae | |||
| b19ee6d8fb | |||
| da4d7aaf06 | |||
| 5caf1db1fa | |||
| d95b278a62 | |||
| 3149332c82 | |||
| d0ff271d82 | |||
| e2586dd157 | |||
| 2d0bbd3efb | |||
| f920d00c0a | |||
| ff1e5698ef | |||
| 6ae1651c0a | |||
| bf79613ffb | |||
| a59f9b79e7 | |||
| ee019e42f8 | |||
| 47644cccb8 | |||
| 9fa65d922f | |||
| a1dea35dc9 | |||
| d8ba1b1880 | |||
| 003eea17b5 | |||
| e375f0e9ca | |||
| ccf8b362b6 | |||
| e8a062c0d3 | |||
| 87a967e9fd | |||
| 993669d8a3 | |||
| b6b76b9433 | |||
| 07794afabb | |||
| 7cfd1aedb3 | |||
| e62bfe3949 | |||
| 172215b3cb | |||
| 32cece30fb | |||
| 218a5c3897 | |||
| 3dd344f51b | |||
| b759337f4d | |||
| 4b29cc979d | |||
| 2c09580633 | |||
| c2ed9f3ba3 | |||
| ed810d23e6 | |||
| 0b25c5709d | |||
| a83a677bfa | |||
| 7dd5da143e | |||
| e904d4499e | |||
| a89153adc8 | |||
| d50d077508 | |||
| e9edde0932 | |||
| e7ad6a0013 | |||
| c174c93ed8 | |||
| 1f287f3b58 | |||
| ec04f3340b | |||
| 763bc62b26 | |||
| 3bb5133ea9 | |||
| af4c29ecdd | |||
| dbc69f2264 | |||
| f27e5f92f0 | |||
| 608f9b6ebd | |||
| 1e774b0321 | |||
| fad2c570bc | |||
| 77505f5325 | |||
| 946bfb3d2c | |||
| c68fc4dca5 | |||
| f3487fae38 | |||
| 41d396fe2a | |||
| d0c4a73cc9 | |||
| d8197ef617 | |||
| 4ec43e3176 | |||
| c0ca93a6a2 | |||
| 7a654b6ec6 | |||
| 983aed1916 | |||
| caf9a47fb9 | |||
| a8744c5cd8 | |||
| 96081a7588 | |||
| 868530ab52 | |||
| 35fe77e08c | |||
| 7dbe5c64eb | |||
| 34c23b69e4 | |||
| 8a43041ed6 | |||
| 3fb77294f3 | |||
| 1418b230f5 | |||
| f6e1c117d8 | |||
| aed98997a0 | |||
| 8423eda54a | |||
| 8ba3ba1646 | |||
| 49e011ac85 | |||
| f920b8cf34 | |||
| 3b0dd64aac | |||
| 0bb86f6d83 | |||
| 5ac29719a1 | |||
| 6a60c5915c | |||
| b4ff066b11 | |||
| a2d9e8e5eb | |||
| 5fc539d300 | |||
| d0ca34ca53 | |||
| 47aa59860e | |||
| ded139334d |
8
.gitignore
vendored
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
RepRaptor
|
||||||
|
Makefile
|
||||||
|
*.user
|
||||||
|
*.o
|
||||||
|
ui_*.h
|
||||||
|
moc_*
|
||||||
|
qrc_*
|
||||||
|
*~
|
||||||
26
.travis.yml
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
language: cpp
|
||||||
|
compiler: gcc
|
||||||
|
sudo: require
|
||||||
|
dist: trusty
|
||||||
|
|
||||||
|
before_install:
|
||||||
|
- sudo add-apt-repository ppa:beineri/opt-qt58-trusty -y
|
||||||
|
- sudo apt-get update -qq
|
||||||
|
|
||||||
|
install:
|
||||||
|
- sudo apt-get -y install qt58base qt58serialport qt58tools
|
||||||
|
- source /opt/qt58/bin/qt58-env.sh
|
||||||
|
|
||||||
|
script:
|
||||||
|
- qmake PREFIX=/usr
|
||||||
|
- make -j4
|
||||||
|
- sudo make INSTALL_ROOT=appdir install ; sudo chown -R $USER appdir ; find appdir/
|
||||||
|
|
||||||
|
after_success:
|
||||||
|
- wget -c "https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage"
|
||||||
|
- chmod a+x linuxdeployqt*.AppImage
|
||||||
|
- unset QTDIR; unset QT_PLUGIN_PATH ; unset LD_LIBRARY_PATH
|
||||||
|
- ./linuxdeployqt*.AppImage ./appdir/usr/share/applications/*.desktop -bundle-non-qt-libs
|
||||||
|
- ./linuxdeployqt*.AppImage ./appdir/usr/share/applications/*.desktop -appimage
|
||||||
|
- find ./appdir -executable -type f -exec ldd {} \; | grep " => /usr" | cut -d " " -f 2-3 | sort | uniq
|
||||||
|
- curl --upload-file ./RepRaptor*.AppImage https://transfer.sh/RepRaptor-git.$(git rev-parse --short HEAD)-x86_64.AppImage
|
||||||
26
README.md
@ -1,16 +1,24 @@
|
|||||||

|

|
||||||
# RepRaptor
|
# RepRaptor [](https://travis-ci.org/NeoTheFox/RepRaptor)
|
||||||
A Qt RepRap gcode sender/host controller aimed to be fast and minimalistic.
|
A Qt RepRap gcode sender/host controller aimed to be fast and minimalistic.
|
||||||
|
|
||||||
Right now the project is in early stage, nigtly builds are available.
|
Right now the project is in early stage. This means some features are still absent, but it is already usable.
|
||||||
|
|
||||||
## Screenshots
|
## Screenshots
|
||||||

|

|
||||||
|
|
||||||
## Building on Ubuntu 14.04.2
|
## Install via PPA
|
||||||
|
Since 0.3 release PPA is available for Ubuntu 14.04 and Linux Mint 17 (and later).
|
||||||
|
```
|
||||||
|
sudo add-apt-repository ppa:soniczerops/repraptor-dev
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install repraptor
|
||||||
|
```
|
||||||
|
|
||||||
|
## Building on Ubuntu 14.04
|
||||||
|
|
||||||
```
|
```
|
||||||
sudo apt-get install libqt5serialport5-dev git build-essential
|
sudo apt-get install qt5-default libqt5serialport libqt5serialport5-dev git build-essential libudev-dev
|
||||||
|
|
||||||
git clone https://github.com/NeoTheFox/RepRaptor && cd RepRaptor
|
git clone https://github.com/NeoTheFox/RepRaptor && cd RepRaptor
|
||||||
|
|
||||||
@ -18,9 +26,15 @@ qmake RepRaptor.pro
|
|||||||
|
|
||||||
make
|
make
|
||||||
```
|
```
|
||||||
|
And if you want to install system-wide
|
||||||
|
```
|
||||||
|
sudo make install
|
||||||
|
```
|
||||||
|
|
||||||
## Links
|
## Links
|
||||||
|
- [Binary release downloads (Windows, Linux)](https://github.com/NeoTheFox/RepRaptor/releases)
|
||||||
- [RepRap wiki](http://reprap.org/wiki/RepRaptor)
|
- [RepRap wiki](http://reprap.org/wiki/RepRaptor)
|
||||||
- [Windows dev builds](http://reprap.org/wiki/File:RepRaptor-000-windows.zip)
|
- [AUR](https://aur.archlinux.org/packages/repraptor-git/)
|
||||||
|
|
||||||
[](https://gratipay.com/NeoTheFox/)
|
[](https://gratipay.com/NeoTheFox/)
|
||||||
|
|
||||||
|
|||||||
8
RepRaptor.desktop
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
[Desktop Entry]
|
||||||
|
Name=RepRaptor
|
||||||
|
Comment=A Qt RepRap gcode sender/host controller aimed to be fast and minimalistic.
|
||||||
|
Exec=RepRaptor
|
||||||
|
Icon=repraptor
|
||||||
|
Terminal=false
|
||||||
|
Type=Application
|
||||||
|
Categories=Utility;Application;
|
||||||
@ -1,6 +1,7 @@
|
|||||||
#-------------------------------------------------
|
#-------------------------------------------------
|
||||||
#
|
#
|
||||||
# Project created by QtCreator 2015-02-26T16:14:20
|
# Project created by QtCreator 2015-02-26T16:14:20
|
||||||
|
# Licenced on terms of GNU GPL v2 licence
|
||||||
#
|
#
|
||||||
#-------------------------------------------------
|
#-------------------------------------------------
|
||||||
|
|
||||||
@ -10,24 +11,65 @@ greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
|
|||||||
|
|
||||||
TARGET = RepRaptor
|
TARGET = RepRaptor
|
||||||
TEMPLATE = app
|
TEMPLATE = app
|
||||||
|
CONFIG += static
|
||||||
|
|
||||||
|
unix {
|
||||||
|
#VARIABLES
|
||||||
|
isEmpty(PREFIX) {
|
||||||
|
PREFIX = /usr
|
||||||
|
}
|
||||||
|
BINDIR = $$PREFIX/bin
|
||||||
|
DATADIR =$$PREFIX/share
|
||||||
|
|
||||||
|
DEFINES += DATADIR=\\\"$$DATADIR\\\" PKGDATADIR=\\\"$$PKGDATADIR\\\"
|
||||||
|
|
||||||
|
#MAKE INSTALL
|
||||||
|
|
||||||
|
INSTALLS += target desktop icon
|
||||||
|
|
||||||
|
target.path =$$BINDIR
|
||||||
|
|
||||||
|
desktop.path = $$DATADIR/applications
|
||||||
|
desktop.files += $${TARGET}.desktop
|
||||||
|
|
||||||
|
icon.path = $$DATADIR/icons
|
||||||
|
icon.files += icons/repraptor.png
|
||||||
|
}
|
||||||
|
|
||||||
SOURCES += main.cpp\
|
SOURCES += main.cpp\
|
||||||
mainwindow.cpp \
|
mainwindow.cpp \
|
||||||
settingswindow.cpp \
|
settingswindow.cpp \
|
||||||
aboutwindow.cpp
|
aboutwindow.cpp \
|
||||||
|
errorwindow.cpp \
|
||||||
|
erroricon.cpp \
|
||||||
|
sdwindow.cpp \
|
||||||
|
eepromwindow.cpp \
|
||||||
|
parser.cpp \
|
||||||
|
sender.cpp
|
||||||
|
|
||||||
HEADERS += mainwindow.h \
|
HEADERS += mainwindow.h \
|
||||||
settingswindow.h \
|
settingswindow.h \
|
||||||
aboutwindow.h
|
aboutwindow.h \
|
||||||
|
errorwindow.h \
|
||||||
|
erroricon.h \
|
||||||
|
sdwindow.h \
|
||||||
|
repraptor.h \
|
||||||
|
eepromwindow.h \
|
||||||
|
parser.h \
|
||||||
|
sender.h
|
||||||
|
|
||||||
FORMS += mainwindow.ui \
|
FORMS += mainwindow.ui \
|
||||||
settingswindow.ui \
|
settingswindow.ui \
|
||||||
aboutwindow.ui
|
aboutwindow.ui \
|
||||||
|
errorwindow.ui \
|
||||||
|
sdwindow.ui \
|
||||||
|
eepromwindow.ui
|
||||||
|
|
||||||
RESOURCES += \
|
RESOURCES += \
|
||||||
graphics.qrc
|
graphics.qrc
|
||||||
|
|
||||||
DISTFILES += \
|
DISTFILES += \
|
||||||
LICENCE \
|
LICENCE \
|
||||||
README.md
|
README.md \
|
||||||
|
RepRaptor.desktop \
|
||||||
|
.travis.yml
|
||||||
|
|||||||
@ -6,6 +6,11 @@ AboutWindow::AboutWindow(QWidget *parent) :
|
|||||||
ui(new Ui::AboutWindow)
|
ui(new Ui::AboutWindow)
|
||||||
{
|
{
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
|
QString info;
|
||||||
|
info += "RepRaptor v" + qApp->applicationVersion() + ", ";
|
||||||
|
info += "built with Qt " + QString(QT_VERSION_STR) + " on ";
|
||||||
|
info += QString(__DATE__) + ", " + QString(__TIME__);
|
||||||
|
ui->versionLabel->setText(info);
|
||||||
}
|
}
|
||||||
|
|
||||||
AboutWindow::~AboutWindow()
|
AboutWindow::~AboutWindow()
|
||||||
|
|||||||
@ -3,6 +3,8 @@
|
|||||||
|
|
||||||
#include <QDialog>
|
#include <QDialog>
|
||||||
|
|
||||||
|
#include "repraptor.h"
|
||||||
|
|
||||||
namespace Ui {
|
namespace Ui {
|
||||||
class AboutWindow;
|
class AboutWindow;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -6,56 +6,25 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>424</width>
|
<width>359</width>
|
||||||
<height>308</height>
|
<height>363</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>About</string>
|
<string>About RepRaptor</string>
|
||||||
|
</property>
|
||||||
|
<property name="windowIcon">
|
||||||
|
<iconset resource="graphics.qrc">
|
||||||
|
<normaloff>:/icons/about.png</normaloff>:/icons/about.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<item row="0" column="0">
|
<item row="3" column="0">
|
||||||
<widget class="QGroupBox" name="groupBox">
|
|
||||||
<property name="title">
|
|
||||||
<string>About RepRaptor</string>
|
|
||||||
</property>
|
|
||||||
<property name="checkable">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout_2">
|
|
||||||
<item row="0" column="0">
|
|
||||||
<widget class="QTextBrowser" name="textBrowser">
|
|
||||||
<property name="acceptDrops">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<property name="html">
|
|
||||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
|
||||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
|
||||||
p, li { white-space: pre-wrap; }
|
|
||||||
</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;">
|
|
||||||
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><img src=":/icons/logo.png" /></p>
|
|
||||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">RepRaptor</span> is a free and open source software for controlling RepRap and similar mashines. This software is distributed by terms of <a href="https://www.gnu.org/licenses/gpl-2.0.html"><span style=" text-decoration: underline; color:#0000ff;">GPL v2 licence.</span></a></p>
|
|
||||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; text-decoration: underline; color:#0000ff;"><br /></p>
|
|
||||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">RepRaptor's main goal is to be as simple as possible and fast, yet functional. This software is being developed as a primary host software for <span style=" font-weight:600;">MGTU MIREA</span> university's 3D printing labratory by</p>
|
|
||||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="mailto:repraptor-dev@repraptor.33mail.com"><span style=" text-decoration: underline; color:#0000ff;">Nickolay (aka &quot;NeoTheFox&quot;) Mardanov.</span></a></p>
|
|
||||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><br /></p>
|
|
||||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="https://github.com/NeoTheFox/RepRaptor"><span style=" text-decoration: underline; color:#0000ff;">GitHub</span></a></p>
|
|
||||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="http://www.reprap.org"><span style=" text-decoration: underline; color:#0000ff;">RepRap</span></a></p>
|
|
||||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; text-decoration: underline; color:#0000ff;"><br /></p>
|
|
||||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; text-decoration: underline; color:#0000ff;"><br /></p></body></html></string>
|
|
||||||
</property>
|
|
||||||
<property name="openExternalLinks">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
<property name="openLinks">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="0">
|
|
||||||
<widget class="QDialogButtonBox" name="buttonBox">
|
<widget class="QDialogButtonBox" name="buttonBox">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
@ -65,9 +34,46 @@ p, li { white-space: pre-wrap; }
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QTextBrowser" name="textBrowser">
|
||||||
|
<property name="acceptDrops">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
|
<property name="html">
|
||||||
|
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||||
|
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||||
|
p, li { white-space: pre-wrap; }
|
||||||
|
</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;">
|
||||||
|
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><img src=":/icons/logo.png" /></p>
|
||||||
|
<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;"> RepRaptor</span> is free and open source software for controlling RepRap and similar machines. This software is distributed by terms of <a href="https://www.gnu.org/licenses/gpl-2.0.html"><span style=" text-decoration: underline; color:#0000ff;">GPL v2 licence.</span></a> Some graphical images (Fugue Icons) are distributed by terms of <a href="https://creativecommons.org/licenses/by/3.0/deed.ru"><span style=" text-decoration: underline; color:#0000ff;">Creative Commons 3 licence</span></a>.</p>
|
||||||
|
<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"> RepRaptor's main goal is to be as simple as possible and fast, yet functional. This software is being developed as a primary host software for <span style=" font-weight:600;">MGTU MIREA</span> university's 3D printing laboratory by</p>
|
||||||
|
<p align="justify" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="mailto:repraptor-dev@repraptor.33mail.com"><span style=" text-decoration: underline; color:#0000ff;">Nickolay (aka &quot;NeoTheFox&quot;) Mardanov.</span></a></p>
|
||||||
|
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><br /></p>
|
||||||
|
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="https://github.com/NeoTheFox/RepRaptor"><span style=" text-decoration: underline; color:#0000ff;">GitHub</span></a></p>
|
||||||
|
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="http://www.reprap.org"><span style=" text-decoration: underline; color:#0000ff;">RepRap wiki</span></a></p>
|
||||||
|
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; text-decoration: underline; color:#0000ff;"><br /></p>
|
||||||
|
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; text-decoration: underline; color:#0000ff;"><br /></p></body></html></string>
|
||||||
|
</property>
|
||||||
|
<property name="openExternalLinks">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<property name="openLinks">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLabel" name="versionLabel">
|
||||||
|
<property name="text">
|
||||||
|
<string>Build info</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
<resources/>
|
<resources>
|
||||||
|
<include location="graphics.qrc"/>
|
||||||
|
</resources>
|
||||||
<connections>
|
<connections>
|
||||||
<connection>
|
<connection>
|
||||||
<sender>buttonBox</sender>
|
<sender>buttonBox</sender>
|
||||||
|
|||||||
139
eepromwindow.cpp
Normal file
@ -0,0 +1,139 @@
|
|||||||
|
#include "eepromwindow.h"
|
||||||
|
#include "ui_eepromwindow.h"
|
||||||
|
|
||||||
|
EEPROMWindow::EEPROMWindow(QStringList eepromLines, QWidget *parent) :
|
||||||
|
QDialog(parent),
|
||||||
|
ui(new Ui::EEPROMWindow)
|
||||||
|
{
|
||||||
|
ui->setupUi(this);
|
||||||
|
|
||||||
|
QSettings settings;
|
||||||
|
firmware = settings.value("printer/firmware").toInt();
|
||||||
|
|
||||||
|
QLayout *layout = new QVBoxLayout();
|
||||||
|
|
||||||
|
if(firmware == Repetier)
|
||||||
|
{
|
||||||
|
int j = 0;
|
||||||
|
foreach (QString str, eepromLines)
|
||||||
|
{
|
||||||
|
str.remove("EPR:"); // Clear the unneeded part
|
||||||
|
|
||||||
|
repetierEEPROMline currentLine; //Storage for EEPROM values
|
||||||
|
|
||||||
|
QStringList tmp = str.split(' ');
|
||||||
|
|
||||||
|
currentLine.T = tmp.at(0).toInt();
|
||||||
|
currentLine.P = tmp.at(1).toInt();
|
||||||
|
currentLine.S = tmp.at(2);
|
||||||
|
|
||||||
|
lines.append(currentLine);
|
||||||
|
|
||||||
|
QString msg;
|
||||||
|
for(int i = 3; i < tmp.size(); i++) msg+=(tmp.at(i) + " "); //Rejoin the rest
|
||||||
|
|
||||||
|
QLayout *line = new QGridLayout();
|
||||||
|
|
||||||
|
QLabel *label = new QLabel(msg, this);
|
||||||
|
QLineEdit *edit = new QLineEdit(currentLine.S,this);
|
||||||
|
|
||||||
|
QFrame* hline = new QFrame();
|
||||||
|
hline->setFrameShape(QFrame::HLine);
|
||||||
|
hline->setFrameShadow(QFrame::Sunken);
|
||||||
|
line->addWidget(hline);
|
||||||
|
|
||||||
|
edit->setObjectName("e"+QString::number(j)); //Name the LineEdit, so when it emits signal we know where it came from
|
||||||
|
|
||||||
|
QRegExpValidator *doublevalidator = new QRegExpValidator(
|
||||||
|
QRegExp("^\\-?\\d+\\.?\\d+(e\\-?\\d+)?$",
|
||||||
|
Qt::CaseInsensitive), this);
|
||||||
|
doublevalidator->setLocale(QLocale::English);
|
||||||
|
|
||||||
|
switch(currentLine.T) // set right validator for the line
|
||||||
|
{
|
||||||
|
case 0:
|
||||||
|
edit->setValidator(new QIntValidator(-128, 255, this));
|
||||||
|
case 1:
|
||||||
|
case 2:
|
||||||
|
edit->setValidator(new QIntValidator(this));
|
||||||
|
break;
|
||||||
|
case 3:
|
||||||
|
edit->setValidator(doublevalidator);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
connect(edit, &QLineEdit::textChanged, this, &EEPROMWindow::lineChanged);
|
||||||
|
|
||||||
|
line->addWidget(label);
|
||||||
|
line->addWidget(edit);
|
||||||
|
|
||||||
|
line->setMargin(2);
|
||||||
|
|
||||||
|
layout->addItem(line);
|
||||||
|
|
||||||
|
j++; // increase counter
|
||||||
|
}
|
||||||
|
|
||||||
|
for(int i = 0; i < lines.size(); i++) changed.append(false);
|
||||||
|
ui->eepromWidgets->setLayout(layout);
|
||||||
|
}
|
||||||
|
else if(firmware == Marlin)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
EEPROMWindow::~EEPROMWindow()
|
||||||
|
{
|
||||||
|
delete ui;
|
||||||
|
}
|
||||||
|
|
||||||
|
void EEPROMWindow::lineChanged(QString s)
|
||||||
|
{
|
||||||
|
if(firmware == Repetier)
|
||||||
|
{
|
||||||
|
int num = sender()->objectName().remove(0, 1).toInt();
|
||||||
|
|
||||||
|
lines[num].S = s;
|
||||||
|
changed[num] = true;
|
||||||
|
}
|
||||||
|
else if(firmware == Marlin)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void EEPROMWindow::on_buttonBox_accepted()
|
||||||
|
{
|
||||||
|
QStringList gcode;
|
||||||
|
|
||||||
|
if(firmware == Repetier)
|
||||||
|
{
|
||||||
|
for(int i=0; i < changed.size(); i++)
|
||||||
|
{
|
||||||
|
if(changed.at(i))
|
||||||
|
{
|
||||||
|
QString command;
|
||||||
|
|
||||||
|
command+=QString("M206");
|
||||||
|
command+=QString("T");
|
||||||
|
command+=QString::number(lines.at(i).T);
|
||||||
|
command+=QString("P");
|
||||||
|
command+=QString::number(lines.at(i).P);
|
||||||
|
if(lines.at(i).T == 3) command+=QString("X");
|
||||||
|
else command+=QString("S");
|
||||||
|
command+=lines.at(i).S;
|
||||||
|
|
||||||
|
gcode.append(command);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if(firmware == Marlin)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
emit changesComplete(gcode);
|
||||||
|
}
|
||||||
37
eepromwindow.h
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
#ifndef EEPROMWINDOW_H
|
||||||
|
#define EEPROMWINDOW_H
|
||||||
|
|
||||||
|
#include <QDialog>
|
||||||
|
#include <QtWidgets>
|
||||||
|
|
||||||
|
#include "repraptor.h"
|
||||||
|
|
||||||
|
using namespace RepRaptor;
|
||||||
|
|
||||||
|
namespace Ui {
|
||||||
|
class EEPROMWindow;
|
||||||
|
}
|
||||||
|
|
||||||
|
class EEPROMWindow : public QDialog
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit EEPROMWindow(QStringList eepromLines, QWidget *parent = 0);
|
||||||
|
~EEPROMWindow();
|
||||||
|
|
||||||
|
private:
|
||||||
|
Ui::EEPROMWindow *ui;
|
||||||
|
QVector <repetierEEPROMline> lines;
|
||||||
|
QVector <bool> changed;
|
||||||
|
int firmware;
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void changesComplete(QStringList changed);
|
||||||
|
|
||||||
|
private slots:
|
||||||
|
void on_buttonBox_accepted();
|
||||||
|
void lineChanged(QString s);
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // EEPROMWINDOW_H
|
||||||
93
eepromwindow.ui
Normal file
@ -0,0 +1,93 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>EEPROMWindow</class>
|
||||||
|
<widget class="QDialog" name="EEPROMWindow">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>287</width>
|
||||||
|
<height>300</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>EEPROM Editor</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
|
<item>
|
||||||
|
<widget class="QScrollArea" name="scrollArea">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Expanding">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="locale">
|
||||||
|
<locale language="English" country="UnitedStates"/>
|
||||||
|
</property>
|
||||||
|
<property name="widgetResizable">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<widget class="QWidget" name="eepromWidgets">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>267</width>
|
||||||
|
<height>251</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QDialogButtonBox" name="buttonBox">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="standardButtons">
|
||||||
|
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
|
||||||
|
</property>
|
||||||
|
<property name="centerButtons">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
<resources/>
|
||||||
|
<connections>
|
||||||
|
<connection>
|
||||||
|
<sender>buttonBox</sender>
|
||||||
|
<signal>accepted()</signal>
|
||||||
|
<receiver>EEPROMWindow</receiver>
|
||||||
|
<slot>accept()</slot>
|
||||||
|
<hints>
|
||||||
|
<hint type="sourcelabel">
|
||||||
|
<x>227</x>
|
||||||
|
<y>282</y>
|
||||||
|
</hint>
|
||||||
|
<hint type="destinationlabel">
|
||||||
|
<x>157</x>
|
||||||
|
<y>274</y>
|
||||||
|
</hint>
|
||||||
|
</hints>
|
||||||
|
</connection>
|
||||||
|
<connection>
|
||||||
|
<sender>buttonBox</sender>
|
||||||
|
<signal>rejected()</signal>
|
||||||
|
<receiver>EEPROMWindow</receiver>
|
||||||
|
<slot>reject()</slot>
|
||||||
|
<hints>
|
||||||
|
<hint type="sourcelabel">
|
||||||
|
<x>277</x>
|
||||||
|
<y>288</y>
|
||||||
|
</hint>
|
||||||
|
<hint type="destinationlabel">
|
||||||
|
<x>286</x>
|
||||||
|
<y>274</y>
|
||||||
|
</hint>
|
||||||
|
</hints>
|
||||||
|
</connection>
|
||||||
|
</connections>
|
||||||
|
</ui>
|
||||||
40
erroricon.cpp
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
#include "erroricon.h"
|
||||||
|
|
||||||
|
ErrorIcon::ErrorIcon(QWidget *parent) : QWidget(parent)
|
||||||
|
{
|
||||||
|
framenum = 0;
|
||||||
|
frame = ":icons/error_a.png";
|
||||||
|
animation = new QTimer(this);
|
||||||
|
animation->setInterval(300);
|
||||||
|
animation->start();
|
||||||
|
|
||||||
|
connect(animation, &QTimer::timeout, this, &ErrorIcon::changeFrame);
|
||||||
|
}
|
||||||
|
|
||||||
|
void ErrorIcon::paintEvent(QPaintEvent *)
|
||||||
|
{
|
||||||
|
QPainter painter(this);
|
||||||
|
QPixmap pframe(frame);
|
||||||
|
painter.drawPixmap(0,0,pframe.width(),pframe.height(),pframe);
|
||||||
|
}
|
||||||
|
|
||||||
|
void ErrorIcon::changeFrame()
|
||||||
|
{
|
||||||
|
if(framenum == 0)
|
||||||
|
{
|
||||||
|
frame = ":icons/error_a.png";
|
||||||
|
framenum = 1;
|
||||||
|
}
|
||||||
|
else if(framenum == 1)
|
||||||
|
{
|
||||||
|
frame = ":icons/error_b.png";
|
||||||
|
framenum = 0;
|
||||||
|
}
|
||||||
|
this->update();
|
||||||
|
}
|
||||||
|
|
||||||
|
ErrorIcon::~ErrorIcon()
|
||||||
|
{
|
||||||
|
animation->stop();
|
||||||
|
}
|
||||||
|
|
||||||
27
erroricon.h
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
#ifndef ERRORICON_H
|
||||||
|
#define ERRORICON_H
|
||||||
|
|
||||||
|
#include <QWidget>
|
||||||
|
#include <QTimer>
|
||||||
|
#include <QPainter>
|
||||||
|
|
||||||
|
class ErrorIcon : public QWidget
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit ErrorIcon(QWidget *parent = 0);
|
||||||
|
~ErrorIcon();
|
||||||
|
QTimer *animation;
|
||||||
|
QString frame;
|
||||||
|
int framenum;
|
||||||
|
|
||||||
|
protected:
|
||||||
|
virtual void paintEvent(QPaintEvent *);
|
||||||
|
|
||||||
|
signals:
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void changeFrame();
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // ERRORICON_H
|
||||||
33
errorwindow.cpp
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
#include "errorwindow.h"
|
||||||
|
#include "ui_errorwindow.h"
|
||||||
|
|
||||||
|
using namespace RepRaptor;
|
||||||
|
|
||||||
|
ErrorWindow::ErrorWindow(QWidget *parent, QString errorText, int errType):
|
||||||
|
QDialog(parent),
|
||||||
|
ui(new Ui::ErrorWindow)
|
||||||
|
{
|
||||||
|
ui->setupUi(this);
|
||||||
|
switch(errType)
|
||||||
|
{
|
||||||
|
case SerialPortError:
|
||||||
|
ui->label->setText(tr("Serial port error:"));
|
||||||
|
break;
|
||||||
|
case OpenFileError:
|
||||||
|
ui->label->setText(tr("File open error:"));
|
||||||
|
break;
|
||||||
|
case HardwareFailure:
|
||||||
|
ui->label->setText(tr("Hardware failure:"));
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
ui->label->setText(tr("Unknown error type:"));
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
ui->errorlabel->setText(errorText);
|
||||||
|
}
|
||||||
|
|
||||||
|
ErrorWindow::~ErrorWindow()
|
||||||
|
{
|
||||||
|
delete ui;
|
||||||
|
}
|
||||||
25
errorwindow.h
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
#ifndef ERRORWINDOW_H
|
||||||
|
#define ERRORWINDOW_H
|
||||||
|
|
||||||
|
#include <QDialog>
|
||||||
|
|
||||||
|
#include "erroricon.h"
|
||||||
|
#include "repraptor.h"
|
||||||
|
|
||||||
|
namespace Ui {
|
||||||
|
class ErrorWindow;
|
||||||
|
}
|
||||||
|
|
||||||
|
class ErrorWindow : public QDialog
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit ErrorWindow(QWidget *parent = 0, QString errorText = "Unknown error", int errType = 0);
|
||||||
|
~ErrorWindow();
|
||||||
|
|
||||||
|
private:
|
||||||
|
Ui::ErrorWindow *ui;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // ERRORWINDOW_H
|
||||||
130
errorwindow.ui
Normal file
@ -0,0 +1,130 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>ErrorWindow</class>
|
||||||
|
<widget class="QDialog" name="ErrorWindow">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>350</width>
|
||||||
|
<height>139</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>Error</string>
|
||||||
|
</property>
|
||||||
|
<widget class="QDialogButtonBox" name="buttonBox">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>90</x>
|
||||||
|
<y>100</y>
|
||||||
|
<width>171</width>
|
||||||
|
<height>32</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="standardButtons">
|
||||||
|
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
|
||||||
|
</property>
|
||||||
|
<property name="centerButtons">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
<widget class="ErrorIcon" name="widget" native="true">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>10</x>
|
||||||
|
<y>10</y>
|
||||||
|
<width>128</width>
|
||||||
|
<height>87</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>128</width>
|
||||||
|
<height>87</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
<widget class="QLabel" name="label">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>180</x>
|
||||||
|
<y>10</y>
|
||||||
|
<width>121</width>
|
||||||
|
<height>31</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Serial port error:</string>
|
||||||
|
</property>
|
||||||
|
<property name="textFormat">
|
||||||
|
<enum>Qt::AutoText</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
<widget class="QLabel" name="errorlabel">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>180</x>
|
||||||
|
<y>40</y>
|
||||||
|
<width>151</width>
|
||||||
|
<height>41</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>NaN</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</widget>
|
||||||
|
<customwidgets>
|
||||||
|
<customwidget>
|
||||||
|
<class>ErrorIcon</class>
|
||||||
|
<extends>QWidget</extends>
|
||||||
|
<header location="global">erroricon.h</header>
|
||||||
|
<container>1</container>
|
||||||
|
</customwidget>
|
||||||
|
</customwidgets>
|
||||||
|
<resources/>
|
||||||
|
<connections>
|
||||||
|
<connection>
|
||||||
|
<sender>buttonBox</sender>
|
||||||
|
<signal>accepted()</signal>
|
||||||
|
<receiver>ErrorWindow</receiver>
|
||||||
|
<slot>accept()</slot>
|
||||||
|
<hints>
|
||||||
|
<hint type="sourcelabel">
|
||||||
|
<x>248</x>
|
||||||
|
<y>254</y>
|
||||||
|
</hint>
|
||||||
|
<hint type="destinationlabel">
|
||||||
|
<x>157</x>
|
||||||
|
<y>274</y>
|
||||||
|
</hint>
|
||||||
|
</hints>
|
||||||
|
</connection>
|
||||||
|
<connection>
|
||||||
|
<sender>buttonBox</sender>
|
||||||
|
<signal>rejected()</signal>
|
||||||
|
<receiver>ErrorWindow</receiver>
|
||||||
|
<slot>reject()</slot>
|
||||||
|
<hints>
|
||||||
|
<hint type="sourcelabel">
|
||||||
|
<x>316</x>
|
||||||
|
<y>260</y>
|
||||||
|
</hint>
|
||||||
|
<hint type="destinationlabel">
|
||||||
|
<x>286</x>
|
||||||
|
<y>274</y>
|
||||||
|
</hint>
|
||||||
|
</hints>
|
||||||
|
</connection>
|
||||||
|
</connections>
|
||||||
|
</ui>
|
||||||
10
graphics.qrc
@ -1,6 +1,14 @@
|
|||||||
<RCC>
|
<RCC>
|
||||||
<qresource prefix="/">
|
<qresource prefix="/">
|
||||||
<file>icons/icon.png</file>
|
<file>icons/repraptor.png</file>
|
||||||
<file>icons/logo.png</file>
|
<file>icons/logo.png</file>
|
||||||
|
<file>icons/error_a.png</file>
|
||||||
|
<file>icons/error_b.png</file>
|
||||||
|
<file>icons/g.png</file>
|
||||||
|
<file>icons/sd.png</file>
|
||||||
|
<file>icons/settings.png</file>
|
||||||
|
<file>icons/about.png</file>
|
||||||
|
<file>icons/exit.png</file>
|
||||||
|
<file>icons/eeprom.png</file>
|
||||||
</qresource>
|
</qresource>
|
||||||
</RCC>
|
</RCC>
|
||||||
|
|||||||
BIN
icons/about.png
Normal file
|
After Width: | Height: | Size: 766 B |
BIN
icons/eeprom.png
Normal file
|
After Width: | Height: | Size: 349 B |
BIN
icons/error_a.png
Normal file
|
After Width: | Height: | Size: 44 KiB |
BIN
icons/error_b.png
Normal file
|
After Width: | Height: | Size: 44 KiB |
BIN
icons/exit.png
Normal file
|
After Width: | Height: | Size: 544 B |
BIN
icons/g.png
Normal file
|
After Width: | Height: | Size: 604 B |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
BIN
icons/sd.png
Normal file
|
After Width: | Height: | Size: 1.3 KiB |
BIN
icons/settings.png
Normal file
|
After Width: | Height: | Size: 699 B |
3
main.cpp
@ -1,13 +1,16 @@
|
|||||||
#include "mainwindow.h"
|
#include "mainwindow.h"
|
||||||
|
#include "repraptor.h"
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
|
|
||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
QApplication a(argc, argv);
|
QApplication a(argc, argv);
|
||||||
|
|
||||||
|
//Set some props in order to fetch and save QSettings
|
||||||
QCoreApplication::setOrganizationName("NeoTheFox");
|
QCoreApplication::setOrganizationName("NeoTheFox");
|
||||||
QCoreApplication::setOrganizationDomain("https://github.com/NeoTheFox");
|
QCoreApplication::setOrganizationDomain("https://github.com/NeoTheFox");
|
||||||
QCoreApplication::setApplicationName("RepRaptor");
|
QCoreApplication::setApplicationName("RepRaptor");
|
||||||
|
QCoreApplication::setApplicationVersion(REPRAPTOR_VERSION);
|
||||||
|
|
||||||
MainWindow w;
|
MainWindow w;
|
||||||
w.show();
|
w.show();
|
||||||
|
|||||||
1061
mainwindow.cpp
115
mainwindow.h
@ -3,18 +3,27 @@
|
|||||||
|
|
||||||
#include <QMainWindow>
|
#include <QMainWindow>
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
|
#include <QSystemTrayIcon>
|
||||||
#include <QtSerialPort/QtSerialPort>
|
#include <QtSerialPort/QtSerialPort>
|
||||||
#include <QFile>
|
#include <QFile>
|
||||||
#include <QFuture>
|
#include <QThread>
|
||||||
#include <QVector>
|
#include <QVector>
|
||||||
#include <QTextStream>
|
#include <QTextStream>
|
||||||
#include <QTimer>
|
|
||||||
#include <QSettings>
|
#include <QSettings>
|
||||||
#include <QElapsedTimer>
|
#include <QElapsedTimer>
|
||||||
|
#include <QRegExp>
|
||||||
|
#include <QMap>
|
||||||
|
|
||||||
#include "settingswindow.h"
|
#include "settingswindow.h"
|
||||||
#include "aboutwindow.h"
|
#include "aboutwindow.h"
|
||||||
|
#include "errorwindow.h"
|
||||||
|
#include "sdwindow.h"
|
||||||
|
#include "repraptor.h"
|
||||||
|
#include "eepromwindow.h"
|
||||||
|
#include "parser.h"
|
||||||
|
#include "sender.h"
|
||||||
|
|
||||||
|
using namespace RepRaptor;
|
||||||
|
|
||||||
namespace Ui {
|
namespace Ui {
|
||||||
class MainWindow;
|
class MainWindow;
|
||||||
@ -28,43 +37,81 @@ public:
|
|||||||
explicit MainWindow(QWidget *parent = 0);
|
explicit MainWindow(QWidget *parent = 0);
|
||||||
~MainWindow();
|
~MainWindow();
|
||||||
|
|
||||||
|
Parser *parserWorker;
|
||||||
|
Sender *senderWorker;
|
||||||
|
QThread *parserThread;
|
||||||
|
QThread *senderThread;
|
||||||
|
|
||||||
|
protected:
|
||||||
|
QMap <QString, QString> macros;
|
||||||
QFile gfile;
|
QFile gfile;
|
||||||
QVector<QString> gcode;
|
QVector<QString> gcode;
|
||||||
QTimer sendTimer;
|
QQueue <QString> userCommands;
|
||||||
QTimer statusTimer;
|
QTimer *progressSDTimer;
|
||||||
QTimer tempWarning;
|
QTimer *statusTimer;
|
||||||
QElapsedTimer sinceLastTemp;
|
QSystemTrayIcon *trayIcon;
|
||||||
|
QMenu *recentMenu;
|
||||||
|
QMenu *trayIconMenu;
|
||||||
|
QElapsedTimer *sinceLastTemp;
|
||||||
|
QElapsedTimer *sinceLastSDStatus;
|
||||||
QSettings settings;
|
QSettings settings;
|
||||||
QStringList recentFiles;
|
QStringList recentFiles;
|
||||||
|
QStringList EEPROMSettings;
|
||||||
|
QStringList userHistory;
|
||||||
|
QSerialPortInfo printerinfo;
|
||||||
|
QTextCursor terminalCursor;
|
||||||
|
|
||||||
|
void closeEvent(QCloseEvent *event);
|
||||||
|
bool eventFilter(QObject *target, QEvent *event);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Ui::MainWindow *ui;
|
Ui::MainWindow *ui;
|
||||||
|
|
||||||
void parseFile(QFile &file);
|
QString lastDir;
|
||||||
QSerialPort printer;
|
bool opened;
|
||||||
QSerialPortInfo printerinfo;
|
bool firstrun;
|
||||||
|
bool autolock;
|
||||||
|
bool printing;
|
||||||
bool sending;
|
bool sending;
|
||||||
bool paused;
|
bool paused;
|
||||||
bool commandDone;
|
|
||||||
bool checkingTemperature;
|
bool checkingTemperature;
|
||||||
bool injectingCommand;
|
bool sdprinting;
|
||||||
int currentLine;
|
bool echo;
|
||||||
QString userCommand;
|
bool chekingSDStatus;
|
||||||
|
bool trayIconEnabled;
|
||||||
|
bool supressWait;
|
||||||
|
int firmware;
|
||||||
|
int feedrate;
|
||||||
|
int extruderFeedrate;
|
||||||
|
int userHistoryPos;
|
||||||
|
unsigned long int sdBytes;
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void open();
|
void open();
|
||||||
void serialconnect();
|
void serialconnect();
|
||||||
void serialupdate();
|
void serialupdate();
|
||||||
bool sendLine(QString line);
|
void updatesettings();
|
||||||
|
void readSerial(QByteArray data);
|
||||||
void readSerial();
|
|
||||||
void printMsg(QString text);
|
void printMsg(QString text);
|
||||||
void printMsg(const char* text);
|
|
||||||
void sendNext();
|
|
||||||
void checkStatus();
|
void checkStatus();
|
||||||
void updateRecent();
|
void updateRecent();
|
||||||
void injectCommand(QString command);
|
void initSDprinting(QStringList sdFiles);
|
||||||
|
void selectSDfile(QString file);
|
||||||
|
void checkSDStatus();
|
||||||
|
void updateSDStatus(SDProgress p);
|
||||||
|
void requestEEPROMSettings();
|
||||||
|
void openEEPROMeditor();
|
||||||
|
void sendEEPROMsettings(QStringList changes);
|
||||||
|
void updateTemperature(TemperatureReadings r);
|
||||||
|
void EEPROMSettingReceived(QString esetting);
|
||||||
|
void receivedError();
|
||||||
|
void receivedSDDone();
|
||||||
|
void receivedNotSDPrinting();
|
||||||
|
void parseFile(QString filename);
|
||||||
|
void recentClicked();
|
||||||
|
void updateFileProgress(FileProgress);
|
||||||
|
void baudrateSetFailed(int b);
|
||||||
|
void trayIconClicked(QSystemTrayIcon::ActivationReason reason);
|
||||||
|
|
||||||
void xplus();
|
void xplus();
|
||||||
void yplus();
|
void yplus();
|
||||||
@ -91,10 +138,38 @@ private slots:
|
|||||||
void on_btmpoff_clicked();
|
void on_btmpoff_clicked();
|
||||||
void on_sendBtn_clicked();
|
void on_sendBtn_clicked();
|
||||||
void on_pauseBtn_clicked();
|
void on_pauseBtn_clicked();
|
||||||
|
void on_haltbtn_clicked();
|
||||||
|
void on_actionAbout_Qt_triggered();
|
||||||
|
void on_speedslider_valueChanged(int value);
|
||||||
|
void on_speededit_textChanged(const QString &arg1);
|
||||||
|
void on_speedsetbtn_clicked();
|
||||||
|
void on_flowedit_textChanged(const QString &arg1);
|
||||||
|
void on_flowslider_valueChanged(int value);
|
||||||
|
void on_flowbutton_clicked();
|
||||||
void on_checktemp_stateChanged(int arg1);
|
void on_checktemp_stateChanged(int arg1);
|
||||||
void on_actionSettings_triggered();
|
void on_actionSettings_triggered();
|
||||||
|
void on_stepspin_valueChanged(const QString &arg1);
|
||||||
|
void on_estepspin_valueChanged(const QString &arg1);
|
||||||
void on_releasebtn_clicked();
|
void on_releasebtn_clicked();
|
||||||
void on_actionAbout_triggered();
|
void on_actionAbout_triggered();
|
||||||
|
void serialError(QSerialPort::SerialPortError error);
|
||||||
|
void on_actionPrint_from_SD_triggered();
|
||||||
|
void on_actionSet_SD_printing_mode_triggered();
|
||||||
|
void on_actionEEPROM_editor_triggered();
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void sdReady();
|
||||||
|
void startedReadingEEPROM();
|
||||||
|
|
||||||
|
void openPort(QSerialPortInfo i);
|
||||||
|
void closePort();
|
||||||
|
void startPrinting();
|
||||||
|
void stopPrinting();
|
||||||
|
void pause(bool p);
|
||||||
|
void setBaudrate(int b);
|
||||||
|
void setFile(QVector <QString> f);
|
||||||
|
void injectCommand(QString command);
|
||||||
|
void flushInjectionBuffer();
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // MAINWINDOW_H
|
#endif // MAINWINDOW_H
|
||||||
|
|||||||
1251
mainwindow.ui
123
parser.cpp
Normal file
@ -0,0 +1,123 @@
|
|||||||
|
#include "parser.h"
|
||||||
|
|
||||||
|
Parser::Parser(QObject *parent):
|
||||||
|
QObject(parent)
|
||||||
|
{
|
||||||
|
//Init regexp
|
||||||
|
temperatureRegxp.setCaseSensitivity(Qt::CaseInsensitive);
|
||||||
|
temperatureRegxp.setPatternSyntax(QRegExp::RegExp);
|
||||||
|
temperatureRegxp.setPattern("\\d+\\.\\d+"); // Find float in string
|
||||||
|
|
||||||
|
//Init values
|
||||||
|
readingFiles = false;
|
||||||
|
readingEEPROM = false;
|
||||||
|
EEPROMReadingStarted = false;
|
||||||
|
|
||||||
|
//Load settings
|
||||||
|
QSettings settings;
|
||||||
|
firmware = settings.value("printer/firmware").toInt();
|
||||||
|
}
|
||||||
|
|
||||||
|
Parser::~Parser()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void Parser::parse(QByteArray data)
|
||||||
|
{
|
||||||
|
if(!data.isEmpty()) //Dont need to process empty strings
|
||||||
|
{
|
||||||
|
if(readingFiles) //SD files list reading mode
|
||||||
|
{
|
||||||
|
if(!data.contains("End file list")) SDFilesList.append(data.remove(data.size()-2, 2));
|
||||||
|
else
|
||||||
|
{
|
||||||
|
readingFiles = false;
|
||||||
|
emit receivedSDFilesList(SDFilesList);
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(readingEEPROM) // EEPROM reading mode
|
||||||
|
{
|
||||||
|
if(firmware == Repetier)
|
||||||
|
{
|
||||||
|
if(data.startsWith("EPR"))
|
||||||
|
{
|
||||||
|
emit receivedEEPROMLine(QString(data));
|
||||||
|
EEPROMReadingStarted = true;
|
||||||
|
}
|
||||||
|
else if(EEPROMReadingStarted)
|
||||||
|
{
|
||||||
|
readingEEPROM = false;
|
||||||
|
EEPROMReadingStarted = false;
|
||||||
|
emit recievingEEPROMDone();
|
||||||
|
}
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
if(data.startsWith("ok"))
|
||||||
|
{
|
||||||
|
QStringList tmp = QString(data).split(' ');
|
||||||
|
if(tmp.size() > 1)
|
||||||
|
emit receivedOkNum(tmp.at(1).toInt());
|
||||||
|
else emit receivedOkNum(0);
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
else if(data.contains("T:"))
|
||||||
|
{
|
||||||
|
TemperatureReadings r;
|
||||||
|
|
||||||
|
if(temperatureRegxp.indexIn(QString(data)) != -1)
|
||||||
|
r.e = temperatureRegxp.cap(0).toDouble();
|
||||||
|
else r.e = 0;
|
||||||
|
if(temperatureRegxp.indexIn(QString(data), temperatureRegxp.matchedLength()) != -1)
|
||||||
|
r.b = temperatureRegxp.cap(0).toDouble();
|
||||||
|
else r.b = 0;
|
||||||
|
|
||||||
|
r.raw = QString(data);
|
||||||
|
|
||||||
|
emit receivedTemperature(r);
|
||||||
|
}
|
||||||
|
//else if(data.startsWith("wait")) emit receivedOkWait();
|
||||||
|
else if(data.startsWith("rs") || data.toLower().startsWith("resend"))
|
||||||
|
emit receivedResend(data.split(':').at(1).toInt());
|
||||||
|
else if(data.startsWith("!!")) emit receivedError();
|
||||||
|
else if(data.startsWith("Done")) emit receivedSDDone();
|
||||||
|
else if(data.startsWith("start")) emit receivedStart();
|
||||||
|
else if(data.startsWith("SD pr"))
|
||||||
|
{
|
||||||
|
SDProgress p;
|
||||||
|
QRegExp rxp("\\d+/\\d+");
|
||||||
|
QStringList tmp;
|
||||||
|
|
||||||
|
if(rxp.indexIn(data) != -1)
|
||||||
|
{
|
||||||
|
tmp = rxp.cap(0).split('/');
|
||||||
|
|
||||||
|
p.progress = tmp.at(0).toLong();
|
||||||
|
p.total = tmp.at(1).toLong();
|
||||||
|
}
|
||||||
|
else return;
|
||||||
|
|
||||||
|
emit receivedSDUpdate(p);
|
||||||
|
|
||||||
|
}
|
||||||
|
else if(data.startsWith("Not SD ")) emit receivedNotSDPrinting();
|
||||||
|
else if(data.contains("Begin file list"))
|
||||||
|
{
|
||||||
|
SDFilesList.clear();
|
||||||
|
readingFiles = true; //start reading files from SD
|
||||||
|
}
|
||||||
|
//else if(data.contains("REPETIER")) emit receivedFirmware(Repetier);
|
||||||
|
//else if(data.contains("MARLIN")) emit receivedFirmware(Marlin);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void Parser::setEEPROMReadingMode()
|
||||||
|
{
|
||||||
|
readingEEPROM = true;
|
||||||
|
}
|
||||||
48
parser.h
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
#ifndef PARSETHREAD_H
|
||||||
|
#define PARSETHREAD_H
|
||||||
|
|
||||||
|
#include <QThread>
|
||||||
|
#include <QSettings>
|
||||||
|
|
||||||
|
#include "repraptor.h"
|
||||||
|
|
||||||
|
using namespace RepRaptor;
|
||||||
|
|
||||||
|
class Parser : public QObject
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit Parser(QObject *parent = 0);
|
||||||
|
~Parser();
|
||||||
|
|
||||||
|
protected:
|
||||||
|
QByteArray data;
|
||||||
|
QStringList SDFilesList;
|
||||||
|
QRegExp temperatureRegxp;
|
||||||
|
int firmware;
|
||||||
|
bool readingFiles;
|
||||||
|
bool readingEEPROM;
|
||||||
|
bool EEPROMReadingStarted;
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void receivedTemperature(TemperatureReadings);
|
||||||
|
void receivedSDUpdate(SDProgress);
|
||||||
|
void receivedNotSDPrinting();
|
||||||
|
void receivedEEPROMLine(QString);
|
||||||
|
void recievingEEPROMDone();
|
||||||
|
void receivedSDFilesList(QStringList);
|
||||||
|
void receivedOkWait();
|
||||||
|
void receivedOkNum(int);
|
||||||
|
void receivedStart();
|
||||||
|
void receivedResend(int);
|
||||||
|
void receivedError();
|
||||||
|
void receivedFirmware(int);
|
||||||
|
void receivedSDDone();
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void parse(QByteArray data);
|
||||||
|
void setEEPROMReadingMode();
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // PARSETHREAD_H
|
||||||
52
repraptor.h
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
/////////////////////////////////////////////////
|
||||||
|
//This file contains RepRaptor - specific stuff//
|
||||||
|
/////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#ifndef REPRAPTOR_H
|
||||||
|
#define REPRAPTOR_H
|
||||||
|
|
||||||
|
#ifndef REPRAPTOR_VERSION
|
||||||
|
#define REPRAPTOR_VERSION "0.3.9"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
namespace RepRaptor
|
||||||
|
{
|
||||||
|
typedef struct
|
||||||
|
{
|
||||||
|
double e, b;
|
||||||
|
QString raw;
|
||||||
|
} TemperatureReadings;
|
||||||
|
|
||||||
|
enum Firmware
|
||||||
|
{
|
||||||
|
Marlin,
|
||||||
|
Repetier,
|
||||||
|
OtherFirmware
|
||||||
|
};
|
||||||
|
|
||||||
|
enum ErrorType
|
||||||
|
{
|
||||||
|
SerialPortError,
|
||||||
|
OpenFileError,
|
||||||
|
HardwareFailure
|
||||||
|
};
|
||||||
|
|
||||||
|
typedef struct
|
||||||
|
{
|
||||||
|
int T, P;
|
||||||
|
QString S;
|
||||||
|
} repetierEEPROMline;
|
||||||
|
|
||||||
|
typedef struct
|
||||||
|
{
|
||||||
|
unsigned long int progress, total;
|
||||||
|
} SDProgress;
|
||||||
|
|
||||||
|
typedef struct
|
||||||
|
{
|
||||||
|
unsigned int T, P;
|
||||||
|
} FileProgress;
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif // REPRAPTOR_H
|
||||||
|
|
||||||
33
sdwindow.cpp
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
#include "sdwindow.h"
|
||||||
|
#include "ui_sdwindow.h"
|
||||||
|
|
||||||
|
SDWindow::SDWindow(QStringList files, QWidget *parent) :
|
||||||
|
QDialog(parent),
|
||||||
|
ui(new Ui::SDWindow)
|
||||||
|
{
|
||||||
|
ui->setupUi(this);
|
||||||
|
|
||||||
|
ui->fileslist->setSelectionMode(QListView::SingleSelection);
|
||||||
|
|
||||||
|
if(!files.isEmpty())
|
||||||
|
{
|
||||||
|
ui->fileslist->addItems(files);
|
||||||
|
ui->fileslist->setCurrentItem(ui->fileslist->itemAt(0,0));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
SDWindow::~SDWindow()
|
||||||
|
{
|
||||||
|
delete ui;
|
||||||
|
}
|
||||||
|
|
||||||
|
void SDWindow::on_buttonBox_accepted()
|
||||||
|
{
|
||||||
|
if(ui->fileslist->count() > 0) emit fileSelected(ui->fileslist->currentItem()->text());
|
||||||
|
}
|
||||||
|
|
||||||
|
void SDWindow::on_fileslist_doubleClicked(const QModelIndex &)
|
||||||
|
{
|
||||||
|
if(ui->fileslist->count() > 0) emit fileSelected(ui->fileslist->currentItem()->text());
|
||||||
|
this->close();
|
||||||
|
}
|
||||||
30
sdwindow.h
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
#ifndef SDWINDOW_H
|
||||||
|
#define SDWINDOW_H
|
||||||
|
|
||||||
|
#include <QDialog>
|
||||||
|
|
||||||
|
namespace Ui {
|
||||||
|
class SDWindow;
|
||||||
|
}
|
||||||
|
|
||||||
|
class SDWindow : public QDialog
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit SDWindow(QStringList files, QWidget *parent = 0);
|
||||||
|
~SDWindow();
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void fileSelected(QString filename);
|
||||||
|
|
||||||
|
private slots:
|
||||||
|
void on_buttonBox_accepted();
|
||||||
|
|
||||||
|
void on_fileslist_doubleClicked(const QModelIndex &);
|
||||||
|
|
||||||
|
private:
|
||||||
|
Ui::SDWindow *ui;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // SDWINDOW_H
|
||||||
99
sdwindow.ui
Normal file
@ -0,0 +1,99 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>SDWindow</class>
|
||||||
|
<widget class="QDialog" name="SDWindow">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>274</width>
|
||||||
|
<height>302</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="MinimumExpanding" vsizetype="MinimumExpanding">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>Print from SD</string>
|
||||||
|
</property>
|
||||||
|
<property name="windowIcon">
|
||||||
|
<iconset resource="graphics.qrc">
|
||||||
|
<normaloff>:/icons/sd.png</normaloff>:/icons/sd.png</iconset>
|
||||||
|
</property>
|
||||||
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLabel" name="label">
|
||||||
|
<property name="text">
|
||||||
|
<string>Select file:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="0">
|
||||||
|
<widget class="QDialogButtonBox" name="buttonBox">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="standardButtons">
|
||||||
|
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
|
||||||
|
</property>
|
||||||
|
<property name="centerButtons">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QListWidget" name="fileslist">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="MinimumExpanding" vsizetype="MinimumExpanding">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="autoScroll">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
<resources>
|
||||||
|
<include location="graphics.qrc"/>
|
||||||
|
</resources>
|
||||||
|
<connections>
|
||||||
|
<connection>
|
||||||
|
<sender>buttonBox</sender>
|
||||||
|
<signal>accepted()</signal>
|
||||||
|
<receiver>SDWindow</receiver>
|
||||||
|
<slot>accept()</slot>
|
||||||
|
<hints>
|
||||||
|
<hint type="sourcelabel">
|
||||||
|
<x>248</x>
|
||||||
|
<y>254</y>
|
||||||
|
</hint>
|
||||||
|
<hint type="destinationlabel">
|
||||||
|
<x>157</x>
|
||||||
|
<y>274</y>
|
||||||
|
</hint>
|
||||||
|
</hints>
|
||||||
|
</connection>
|
||||||
|
<connection>
|
||||||
|
<sender>buttonBox</sender>
|
||||||
|
<signal>rejected()</signal>
|
||||||
|
<receiver>SDWindow</receiver>
|
||||||
|
<slot>reject()</slot>
|
||||||
|
<hints>
|
||||||
|
<hint type="sourcelabel">
|
||||||
|
<x>316</x>
|
||||||
|
<y>260</y>
|
||||||
|
</hint>
|
||||||
|
<hint type="destinationlabel">
|
||||||
|
<x>286</x>
|
||||||
|
<y>274</y>
|
||||||
|
</hint>
|
||||||
|
</hints>
|
||||||
|
</connection>
|
||||||
|
</connections>
|
||||||
|
</ui>
|
||||||
224
sender.cpp
Normal file
@ -0,0 +1,224 @@
|
|||||||
|
#include "sender.h"
|
||||||
|
|
||||||
|
Sender::Sender(QObject *parent) : QObject(parent)
|
||||||
|
{
|
||||||
|
//Initial values
|
||||||
|
currentLine=0;
|
||||||
|
totalLineNum=0;
|
||||||
|
baudrate=115200;
|
||||||
|
resendNum = 0;
|
||||||
|
resending = false;
|
||||||
|
sendingChecksum=false;
|
||||||
|
paused=false;
|
||||||
|
sending=false;
|
||||||
|
readyReceive = false;
|
||||||
|
printer = new QSerialPort(this);
|
||||||
|
sendTimer = new QTimer(this);
|
||||||
|
|
||||||
|
//Fetch settings
|
||||||
|
QSettings settings(this);
|
||||||
|
sendTimer->setInterval(settings.value("core/senderinterval", 2).toInt());
|
||||||
|
sendingChecksum = settings.value("core/checksums", 0).toBool();
|
||||||
|
dtr = settings.value("core/dtr", 1).toBool();
|
||||||
|
flowcontrol = settings.value("core/flowcontrol", 0).toInt();
|
||||||
|
|
||||||
|
sendTimer->start();
|
||||||
|
|
||||||
|
connect(printer, SIGNAL(error(QSerialPort::SerialPortError)), this, SLOT(receivedError(QSerialPort::SerialPortError)));
|
||||||
|
connect(printer, &QSerialPort::readyRead, this, &Sender::receivedData);
|
||||||
|
connect(sendTimer, &QTimer::timeout, this, &Sender::sendNext);
|
||||||
|
}
|
||||||
|
|
||||||
|
Sender::~Sender()
|
||||||
|
{
|
||||||
|
closePort();
|
||||||
|
sendTimer->stop();
|
||||||
|
}
|
||||||
|
|
||||||
|
//Mainloop of sending
|
||||||
|
void Sender::sendNext()
|
||||||
|
{
|
||||||
|
if(printer->isWritable() && readyReceive)
|
||||||
|
{
|
||||||
|
//Checksums
|
||||||
|
if(sendingChecksum && resending)
|
||||||
|
{
|
||||||
|
if(resendNum < sentCommands.size())
|
||||||
|
{
|
||||||
|
sendLine(sentCommands.at(resendNum));
|
||||||
|
resendNum++;
|
||||||
|
}
|
||||||
|
else if(resendNum == sentCommands.size())
|
||||||
|
{
|
||||||
|
resending = false;
|
||||||
|
resendNum = 0;
|
||||||
|
}
|
||||||
|
else if(resendNum > sentCommands.size())
|
||||||
|
{
|
||||||
|
sendLine("M110 N0");
|
||||||
|
totalLineNum = 0;
|
||||||
|
resendNum = 0;
|
||||||
|
sentCommands.clear();
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if(!userCommands.isEmpty()) //Inject user command
|
||||||
|
{
|
||||||
|
sendLine(userCommands.dequeue());
|
||||||
|
readyReceive = false;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
else if(sending && !paused) //Send line of gcode
|
||||||
|
{
|
||||||
|
FileProgress p;
|
||||||
|
if(currentLine >= gcode.size()) //check if we are at the end of array
|
||||||
|
{
|
||||||
|
sending = false;
|
||||||
|
currentLine = 0;
|
||||||
|
if(sendingChecksum) sendLine("M110 N0");
|
||||||
|
|
||||||
|
p.P = gcode.size();
|
||||||
|
p.T = gcode.size();
|
||||||
|
emit reportProgress(p);
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
sendLine(gcode.at(currentLine));
|
||||||
|
currentLine++;
|
||||||
|
readyReceive=false;
|
||||||
|
|
||||||
|
p.P = currentLine;
|
||||||
|
p.T = gcode.size();
|
||||||
|
emit reportProgress(p);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bool Sender::sendLine(QString line)
|
||||||
|
{
|
||||||
|
sentCommands.clear();
|
||||||
|
if(printer->isOpen())
|
||||||
|
{
|
||||||
|
if(sendingChecksum)
|
||||||
|
{
|
||||||
|
if(line.contains("M110")) totalLineNum = 0;
|
||||||
|
sentCommands.append(line);
|
||||||
|
//Checksum algorithm from RepRap wiki
|
||||||
|
line = "N"+QString::number(totalLineNum)+line+"*";
|
||||||
|
int cs = 0;
|
||||||
|
for(int i = 0; line.at(i) != '*'; i++) cs = cs ^ line.at(i).toLatin1();
|
||||||
|
cs &= 0xff;
|
||||||
|
line += QString::number(cs);
|
||||||
|
totalLineNum++;
|
||||||
|
}
|
||||||
|
if(printer->write(line.toUtf8()+'\n')) return true;
|
||||||
|
else return false;
|
||||||
|
}
|
||||||
|
else return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::openPort(QSerialPortInfo i)
|
||||||
|
{
|
||||||
|
printer->setPort(i);
|
||||||
|
|
||||||
|
if(!printer->isOpen() && printer->open(QIODevice::ReadWrite))
|
||||||
|
{
|
||||||
|
//Moved here to be compatible with Qt 5.2.1
|
||||||
|
printer->setDataTerminalReady(dtr);
|
||||||
|
if(!printer->setBaudRate(baudrate))
|
||||||
|
emit baudrateSetFailed(baudrate);
|
||||||
|
printer->setFlowControl(static_cast<QSerialPort::FlowControl>(flowcontrol));
|
||||||
|
}
|
||||||
|
|
||||||
|
readyReceive = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::closePort()
|
||||||
|
{
|
||||||
|
if(printer->isOpen()) printer->close();
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::startPrinting()
|
||||||
|
{
|
||||||
|
currentLine = 0;
|
||||||
|
paused = false;
|
||||||
|
sending = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::stopPrinting()
|
||||||
|
{
|
||||||
|
currentLine = 0;
|
||||||
|
paused = false;
|
||||||
|
sending = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::pause(bool p)
|
||||||
|
{
|
||||||
|
paused = p;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::setBaudrate(int b)
|
||||||
|
{
|
||||||
|
baudrate = b;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::setFile(QVector <QString> f)
|
||||||
|
{
|
||||||
|
gcode = f;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::injectCommand(QString command)
|
||||||
|
{
|
||||||
|
if(!userCommands.contains(command)) userCommands.enqueue(command);
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::receivedOkWait()
|
||||||
|
{
|
||||||
|
readyReceive = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::receivedOkNum(int)
|
||||||
|
{
|
||||||
|
readyReceive = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::receivedStart()
|
||||||
|
{
|
||||||
|
readyReceive = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::flushInjectionBuffer()
|
||||||
|
{
|
||||||
|
userCommands.clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::receivedResend(int r)
|
||||||
|
{
|
||||||
|
if(sendingChecksum)
|
||||||
|
{
|
||||||
|
resending = true;
|
||||||
|
resendNum = r;
|
||||||
|
}
|
||||||
|
else currentLine--;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::receivedData()
|
||||||
|
{
|
||||||
|
if(printer->canReadLine())
|
||||||
|
{
|
||||||
|
QByteArray data = printer->readLine();
|
||||||
|
if(data == "") return;
|
||||||
|
emit dataReceived(data);
|
||||||
|
//Yeah, yeah, I know. This class is called "Sender", but checking this here is faster.
|
||||||
|
if(data.startsWith("ok") || data.startsWith("wait")) readyReceive=true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void Sender::receivedError(QSerialPort::SerialPortError error)
|
||||||
|
{
|
||||||
|
if(error > 0)
|
||||||
|
{
|
||||||
|
closePort();
|
||||||
|
emit errorReceived(error);
|
||||||
|
}
|
||||||
|
}
|
||||||
71
sender.h
Normal file
@ -0,0 +1,71 @@
|
|||||||
|
#ifndef SENDER_H
|
||||||
|
#define SENDER_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QSerialPort>
|
||||||
|
#include <QSerialPortInfo>
|
||||||
|
#include <QQueue>
|
||||||
|
#include <QTimer>
|
||||||
|
#include <QSettings>
|
||||||
|
#include <QVector>
|
||||||
|
|
||||||
|
#include "repraptor.h"
|
||||||
|
|
||||||
|
using namespace RepRaptor;
|
||||||
|
|
||||||
|
class Sender : public QObject
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit Sender(QObject *parent = 0);
|
||||||
|
~Sender();
|
||||||
|
|
||||||
|
protected:
|
||||||
|
QSerialPort *printer;
|
||||||
|
QTimer *sendTimer;
|
||||||
|
long int currentLine;
|
||||||
|
long int totalLineNum;
|
||||||
|
long int resendNum;
|
||||||
|
long int baudrate;
|
||||||
|
long int flowcontrol;
|
||||||
|
bool paused;
|
||||||
|
bool sending;
|
||||||
|
bool dtr;
|
||||||
|
bool readyReceive;
|
||||||
|
bool sendingChecksum;
|
||||||
|
bool resending;
|
||||||
|
QQueue <QString> userCommands;
|
||||||
|
QStringList sentCommands;
|
||||||
|
QVector <QString> gcode;
|
||||||
|
|
||||||
|
bool sendLine(QString s);
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void errorReceived(QSerialPort::SerialPortError error);
|
||||||
|
void dataReceived(QByteArray data);
|
||||||
|
void reportProgress(FileProgress p);
|
||||||
|
void baudrateSetFailed(int b);
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void openPort(QSerialPortInfo i);
|
||||||
|
void closePort();
|
||||||
|
void startPrinting();
|
||||||
|
void stopPrinting();
|
||||||
|
void pause(bool p);
|
||||||
|
void setBaudrate(int b);
|
||||||
|
void setFile(QVector <QString> f);
|
||||||
|
void injectCommand(QString);
|
||||||
|
void flushInjectionBuffer();
|
||||||
|
|
||||||
|
void receivedOkWait();
|
||||||
|
void receivedOkNum(int);
|
||||||
|
void receivedStart();
|
||||||
|
void receivedResend(int r);
|
||||||
|
|
||||||
|
void sendNext();
|
||||||
|
|
||||||
|
void receivedData();
|
||||||
|
void receivedError(QSerialPort::SerialPortError error);
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // SENDER_H
|
||||||
151
settings.ui
@ -1,151 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<ui version="4.0">
|
|
||||||
<class>Dialog</class>
|
|
||||||
<widget class="QDialog" name="Dialog">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>0</x>
|
|
||||||
<y>0</y>
|
|
||||||
<width>400</width>
|
|
||||||
<height>300</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="windowTitle">
|
|
||||||
<string>Dialog</string>
|
|
||||||
</property>
|
|
||||||
<widget class="QGroupBox" name="hardwaregroup">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>10</x>
|
|
||||||
<y>10</y>
|
|
||||||
<width>181</width>
|
|
||||||
<height>65</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="title">
|
|
||||||
<string>Hardware</string>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
|
||||||
<item row="0" column="0">
|
|
||||||
<widget class="QLabel" name="label">
|
|
||||||
<property name="text">
|
|
||||||
<string>Bed Size</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="1">
|
|
||||||
<widget class="QLineEdit" name="xsize">
|
|
||||||
<property name="text">
|
|
||||||
<string>200</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="2">
|
|
||||||
<widget class="QLabel" name="label_2">
|
|
||||||
<property name="text">
|
|
||||||
<string>X</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="3">
|
|
||||||
<widget class="QLineEdit" name="ysize">
|
|
||||||
<property name="text">
|
|
||||||
<string>200</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
<widget class="QPushButton" name="savebtn">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>220</x>
|
|
||||||
<y>270</y>
|
|
||||||
<width>80</width>
|
|
||||||
<height>23</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>Save</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
<widget class="QPushButton" name="cancelbtn">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>310</x>
|
|
||||||
<y>270</y>
|
|
||||||
<width>80</width>
|
|
||||||
<height>23</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>Cancel</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
<widget class="QGroupBox" name="intervalgroup">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>10</x>
|
|
||||||
<y>90</y>
|
|
||||||
<width>181</width>
|
|
||||||
<height>96</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="title">
|
|
||||||
<string>Intervals</string>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout_2">
|
|
||||||
<item row="0" column="0">
|
|
||||||
<widget class="QLabel" name="label_3">
|
|
||||||
<property name="text">
|
|
||||||
<string>Sender</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="1">
|
|
||||||
<widget class="QSpinBox" name="sendinterval">
|
|
||||||
<property name="maximum">
|
|
||||||
<number>9999</number>
|
|
||||||
</property>
|
|
||||||
<property name="value">
|
|
||||||
<number>50</number>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="2">
|
|
||||||
<widget class="QLabel" name="label_5">
|
|
||||||
<property name="text">
|
|
||||||
<string>ms</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="0">
|
|
||||||
<widget class="QLabel" name="label_4">
|
|
||||||
<property name="text">
|
|
||||||
<string>Status</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="1">
|
|
||||||
<widget class="QSpinBox" name="statusinterval">
|
|
||||||
<property name="maximum">
|
|
||||||
<number>9999</number>
|
|
||||||
</property>
|
|
||||||
<property name="value">
|
|
||||||
<number>3000</number>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="2">
|
|
||||||
<widget class="QLabel" name="label_6">
|
|
||||||
<property name="text">
|
|
||||||
<string>ms</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
<resources/>
|
|
||||||
<connections/>
|
|
||||||
</ui>
|
|
||||||
@ -6,18 +6,39 @@ SettingsWindow::SettingsWindow(QWidget *parent) :
|
|||||||
ui(new Ui::SettingsWindow)
|
ui(new Ui::SettingsWindow)
|
||||||
{
|
{
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
|
ui->flowcontrolbox->addItem(tr("No control"));
|
||||||
|
ui->flowcontrolbox->addItem(tr("Hardware control"));
|
||||||
|
ui->flowcontrolbox->addItem(tr("Software control"));
|
||||||
|
|
||||||
if(settings.value("core/senderinterval").toInt()) ui->senderbox->setValue(settings.value("core/senderinterval").toInt());
|
//bool firstrun = !settings.value("core/firstrun").toBool(); //firstrun is inverted!
|
||||||
else ui->senderbox->setValue(5);
|
|
||||||
|
|
||||||
if(settings.value("core/statusinterval").toInt()) ui->statusbox->setValue(settings.value("core/statusinterval").toInt());
|
settings.setParent(this);
|
||||||
else ui->senderbox->setValue(3000);
|
ui->flowcontrolbox->setCurrentIndex(settings.value("core/flowcontrol", 0).toInt());
|
||||||
|
ui->senderbox->setValue(settings.value("core/senderinterval", 2).toInt());
|
||||||
|
ui->traybox->setChecked(settings.value("core/trayiconenabled", 1).toBool());
|
||||||
|
ui->statusbox->setValue(settings.value("core/statusinterval", 2000).toInt());
|
||||||
|
ui->bedxbox->setValue(settings.value("printer/bedx", 200).toInt());
|
||||||
|
ui->bedybox->setValue(settings.value("printer/bedy", 200).toInt());
|
||||||
|
ui->feedrateBox->setValue(settings.value("printer/feedrate", 1500).toInt());
|
||||||
|
ui->extruderFeedrateBox->setValue(settings.value("printer/extruderfeedrate", 200).toInt());
|
||||||
|
ui->lockbox->setChecked(settings.value("core/lockcontrols", 0).toBool());
|
||||||
|
ui->checksumbox->setChecked(settings.value("core/checksums", 0).toBool());
|
||||||
|
ui->sdbox->setChecked(settings.value("core/checksdstatus", 1).toBool());
|
||||||
|
ui->dtrbox->setChecked(settings.value("core/dtr", 1).toBool());
|
||||||
|
ui->supresswaitbox->setChecked(settings.value("user/supresswait").toBool());
|
||||||
|
ui->bufferbox->setValue(settings.value("core/logbuffersize", 1000).toInt());
|
||||||
|
|
||||||
if(settings.value("printer/bedx").toInt()) ui->bedxbox->setValue(settings.value("printer/bedx").toInt());
|
ui->firmwarecombo->addItem("Marlin"); //0
|
||||||
else ui->bedxbox->setValue(200);
|
ui->firmwarecombo->addItem("Repetier"); //1
|
||||||
|
ui->firmwarecombo->addItem("Other"); //2
|
||||||
|
|
||||||
if(settings.value("printer/bedy").toInt()) ui->bedybox->setValue(settings.value("printer/bedy").toInt());
|
ui->firmwarecombo->setCurrentIndex(settings.value("printer/firmware", OtherFirmware).toInt());
|
||||||
else ui->bedybox->setValue(200);
|
|
||||||
|
#ifdef QT_DEBUG
|
||||||
|
ui->checksumbox->setEnabled(true);
|
||||||
|
#else
|
||||||
|
ui->checksumbox->setDisabled(true);
|
||||||
|
#endif
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -28,8 +49,21 @@ SettingsWindow::~SettingsWindow()
|
|||||||
|
|
||||||
void SettingsWindow::on_buttonBox_accepted()
|
void SettingsWindow::on_buttonBox_accepted()
|
||||||
{
|
{
|
||||||
|
settings.setValue("core/flowcontrol", ui->flowcontrolbox->currentIndex());
|
||||||
|
settings.setValue("core/trayiconenabled", ui->traybox->isChecked());
|
||||||
settings.setValue("core/senderinterval", ui->senderbox->value());
|
settings.setValue("core/senderinterval", ui->senderbox->value());
|
||||||
settings.setValue("core/statusinterval", ui->statusbox->value());
|
settings.setValue("core/statusinterval", ui->statusbox->value());
|
||||||
settings.setValue("printer/bedy", ui->bedybox->value());
|
settings.setValue("printer/bedy", ui->bedybox->value());
|
||||||
settings.setValue("printer/bedx", ui->bedxbox->value());
|
settings.setValue("printer/bedx", ui->bedxbox->value());
|
||||||
|
settings.setValue("printer/feedrate", ui->feedrateBox->value());
|
||||||
|
settings.setValue("printer/extruderfeedrate", ui->extruderFeedrateBox->value());
|
||||||
|
settings.setValue("core/lockcontrols", ui->lockbox->isChecked());
|
||||||
|
settings.setValue("core/checksums", ui->checksumbox->isChecked());
|
||||||
|
settings.setValue("core/checksdstatus", ui->sdbox->isChecked());
|
||||||
|
settings.setValue("core/dtr", ui->dtrbox->isChecked());
|
||||||
|
settings.setValue("printer/firmware", ui->firmwarecombo->currentIndex());
|
||||||
|
settings.setValue("user/supresswait", ui->supresswaitbox->isChecked());
|
||||||
|
settings.setValue("core/logbuffersize", ui->bufferbox->value());
|
||||||
|
|
||||||
|
emit updatesettings();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3,6 +3,9 @@
|
|||||||
|
|
||||||
#include <QDialog>
|
#include <QDialog>
|
||||||
#include <QSettings>
|
#include <QSettings>
|
||||||
|
#include "repraptor.h"
|
||||||
|
|
||||||
|
using namespace RepRaptor;
|
||||||
|
|
||||||
namespace Ui {
|
namespace Ui {
|
||||||
class SettingsWindow;
|
class SettingsWindow;
|
||||||
@ -24,6 +27,10 @@ private slots:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
Ui::SettingsWindow *ui;
|
Ui::SettingsWindow *ui;
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void updatesettings();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // SETTINGSWINDOW_H
|
#endif // SETTINGSWINDOW_H
|
||||||
|
|||||||
@ -6,155 +6,351 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>400</width>
|
<width>603</width>
|
||||||
<height>300</height>
|
<height>491</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>Settings</string>
|
<string>Settings</string>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QDialogButtonBox" name="buttonBox">
|
<property name="windowIcon">
|
||||||
<property name="geometry">
|
<iconset resource="graphics.qrc">
|
||||||
<rect>
|
<normaloff>:/icons/settings.png</normaloff>:/icons/settings.png</iconset>
|
||||||
<x>30</x>
|
</property>
|
||||||
<y>260</y>
|
<layout class="QGridLayout" name="gridLayout_3">
|
||||||
<width>341</width>
|
<item row="0" column="0">
|
||||||
<height>32</height>
|
<widget class="QTabWidget" name="tabWidget">
|
||||||
</rect>
|
<property name="minimumSize">
|
||||||
</property>
|
<size>
|
||||||
<property name="orientation">
|
<width>200</width>
|
||||||
<enum>Qt::Horizontal</enum>
|
<height>400</height>
|
||||||
</property>
|
</size>
|
||||||
<property name="standardButtons">
|
</property>
|
||||||
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
|
<property name="currentIndex">
|
||||||
</property>
|
<number>0</number>
|
||||||
</widget>
|
</property>
|
||||||
<widget class="QGroupBox" name="intervalsGroup">
|
<widget class="QWidget" name="tab_general">
|
||||||
<property name="geometry">
|
<attribute name="title">
|
||||||
<rect>
|
<string>General</string>
|
||||||
<x>10</x>
|
</attribute>
|
||||||
<y>10</y>
|
<layout class="QFormLayout" name="formLayout">
|
||||||
<width>201</width>
|
<item row="0" column="0">
|
||||||
<height>96</height>
|
<widget class="QGroupBox" name="internalGroup">
|
||||||
</rect>
|
<property name="title">
|
||||||
</property>
|
<string>Internal</string>
|
||||||
<property name="title">
|
</property>
|
||||||
<string>Intervals</string>
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
</property>
|
<item row="1" column="1">
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<widget class="QDoubleSpinBox" name="senderbox">
|
||||||
<item row="0" column="0">
|
<property name="toolTip">
|
||||||
<widget class="QLabel" name="label">
|
<string>A good default is 2, lower = fater, higher = less CPU load. 0 would execute as soon as possible.</string>
|
||||||
<property name="text">
|
</property>
|
||||||
<string>Sender</string>
|
<property name="toolTipDuration">
|
||||||
</property>
|
<number>-1</number>
|
||||||
|
</property>
|
||||||
|
<property name="locale">
|
||||||
|
<locale language="English" country="UnitedStates"/>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<double>0.000000000000000</double>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<double>999.990000000000009</double>
|
||||||
|
</property>
|
||||||
|
<property name="singleStep">
|
||||||
|
<double>1.000000000000000</double>
|
||||||
|
</property>
|
||||||
|
<property name="value">
|
||||||
|
<double>2.000000000000000</double>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="1">
|
||||||
|
<widget class="QSpinBox" name="statusbox">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>A good default is 5000. More = less interruptions, less = better temperature monitoring</string>
|
||||||
|
</property>
|
||||||
|
<property name="toolTipDuration">
|
||||||
|
<number>-1</number>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>1500</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>99999</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="0">
|
||||||
|
<widget class="QLabel" name="label_2">
|
||||||
|
<property name="text">
|
||||||
|
<string>Status</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="10" column="0">
|
||||||
|
<widget class="QCheckBox" name="checksumbox">
|
||||||
|
<property name="enabled">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Checksums</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="9" column="0" colspan="3">
|
||||||
|
<widget class="QCheckBox" name="sdbox">
|
||||||
|
<property name="text">
|
||||||
|
<string>Check SD printing status</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0" colspan="3">
|
||||||
|
<widget class="QLabel" name="label_7">
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>0</width>
|
||||||
|
<height>28</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>This settings are applied after restart</string>
|
||||||
|
</property>
|
||||||
|
<property name="textFormat">
|
||||||
|
<enum>Qt::AutoText</enum>
|
||||||
|
</property>
|
||||||
|
<property name="wordWrap">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<property name="margin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="4" column="0">
|
||||||
|
<widget class="QLabel" name="label_11">
|
||||||
|
<property name="text">
|
||||||
|
<string>Flow control</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="6" column="0">
|
||||||
|
<widget class="QCheckBox" name="dtrbox">
|
||||||
|
<property name="text">
|
||||||
|
<string>DTR</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="2">
|
||||||
|
<widget class="QLabel" name="label_4">
|
||||||
|
<property name="text">
|
||||||
|
<string>ms</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="2">
|
||||||
|
<widget class="QLabel" name="label_3">
|
||||||
|
<property name="text">
|
||||||
|
<string>ms</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QLabel" name="label">
|
||||||
|
<property name="text">
|
||||||
|
<string>Sender</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="4" column="1" colspan="2">
|
||||||
|
<widget class="QComboBox" name="flowcontrolbox">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="8" column="0" colspan="3">
|
||||||
|
<widget class="QCheckBox" name="lockbox">
|
||||||
|
<property name="text">
|
||||||
|
<string>Lock controls when printing</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="7" column="0">
|
||||||
|
<widget class="QCheckBox" name="traybox">
|
||||||
|
<property name="enabled">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>Show tray icon</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Tray icon</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="11" column="0" colspan="2">
|
||||||
|
<widget class="QCheckBox" name="supresswaitbox">
|
||||||
|
<property name="text">
|
||||||
|
<string>Supress "wait" responce</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="3" column="0">
|
||||||
|
<widget class="QLabel" name="label_12">
|
||||||
|
<property name="text">
|
||||||
|
<string>Log buffer</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="3" column="1">
|
||||||
|
<widget class="QSpinBox" name="bufferbox">
|
||||||
|
<property name="maximum">
|
||||||
|
<number>100000</number>
|
||||||
|
</property>
|
||||||
|
<property name="value">
|
||||||
|
<number>1000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
<widget class="QWidget" name="tab_network">
|
||||||
<item row="0" column="1">
|
<attribute name="title">
|
||||||
<widget class="QSpinBox" name="senderbox">
|
<string>Network</string>
|
||||||
<property name="toolTip">
|
</attribute>
|
||||||
<string>A good default is 5, lower = fater, higher = less CPU load</string>
|
|
||||||
</property>
|
|
||||||
<property name="toolTipDuration">
|
|
||||||
<number>-1</number>
|
|
||||||
</property>
|
|
||||||
<property name="minimum">
|
|
||||||
<number>1</number>
|
|
||||||
</property>
|
|
||||||
<property name="maximum">
|
|
||||||
<number>999</number>
|
|
||||||
</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
<widget class="QWidget" name="tab_hardware">
|
||||||
<item row="0" column="2">
|
<attribute name="title">
|
||||||
<widget class="QLabel" name="label_3">
|
<string>Hardware</string>
|
||||||
<property name="text">
|
</attribute>
|
||||||
<string>ms</string>
|
<widget class="QGroupBox" name="groupBox">
|
||||||
</property>
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>10</x>
|
||||||
|
<y>20</y>
|
||||||
|
<width>249</width>
|
||||||
|
<height>171</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Preferred" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="title">
|
||||||
|
<string>Printer</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QGridLayout" name="gridLayout_2">
|
||||||
|
<item row="1" column="1">
|
||||||
|
<widget class="QSpinBox" name="bedxbox">
|
||||||
|
<property name="minimum">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>9999</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="2">
|
||||||
|
<widget class="QLabel" name="label_6">
|
||||||
|
<property name="text">
|
||||||
|
<string>X</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="3">
|
||||||
|
<widget class="QSpinBox" name="bedybox">
|
||||||
|
<property name="minimum">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>9999</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QLabel" name="label_5">
|
||||||
|
<property name="text">
|
||||||
|
<string>Bed size</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLabel" name="label_8">
|
||||||
|
<property name="text">
|
||||||
|
<string>Firmware</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="1" colspan="3">
|
||||||
|
<widget class="QComboBox" name="firmwarecombo"/>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="0">
|
||||||
|
<widget class="QLabel" name="label_9">
|
||||||
|
<property name="text">
|
||||||
|
<string>Feedrate</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="1" colspan="2">
|
||||||
|
<widget class="QSpinBox" name="feedrateBox">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>Speed of axis movements (only affect buttons)</string>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>99999</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="3" column="0">
|
||||||
|
<widget class="QLabel" name="label_10">
|
||||||
|
<property name="text">
|
||||||
|
<string>Extruder
|
||||||
|
feedrate</string>
|
||||||
|
</property>
|
||||||
|
<property name="margin">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="3" column="1" colspan="2">
|
||||||
|
<widget class="QSpinBox" name="extruderFeedrateBox">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>Extruder speed (only affect buttons)</string>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>99999</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</widget>
|
||||||
<item row="1" column="0">
|
</item>
|
||||||
<widget class="QLabel" name="label_2">
|
<item row="1" column="0">
|
||||||
<property name="text">
|
<widget class="QDialogButtonBox" name="buttonBox">
|
||||||
<string>Status</string>
|
<property name="orientation">
|
||||||
</property>
|
<enum>Qt::Horizontal</enum>
|
||||||
</widget>
|
</property>
|
||||||
</item>
|
<property name="standardButtons">
|
||||||
<item row="1" column="1">
|
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
|
||||||
<widget class="QSpinBox" name="statusbox">
|
</property>
|
||||||
<property name="toolTip">
|
<property name="centerButtons">
|
||||||
<string>A good default is 5000. More = less interruptions, less = better temperature monitoring</string>
|
<bool>true</bool>
|
||||||
</property>
|
</property>
|
||||||
<property name="toolTipDuration">
|
</widget>
|
||||||
<number>-1</number>
|
</item>
|
||||||
</property>
|
</layout>
|
||||||
<property name="minimum">
|
|
||||||
<number>500</number>
|
|
||||||
</property>
|
|
||||||
<property name="maximum">
|
|
||||||
<number>99999</number>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="2">
|
|
||||||
<widget class="QLabel" name="label_4">
|
|
||||||
<property name="text">
|
|
||||||
<string>ms</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
<widget class="QGroupBox" name="groupBox">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>10</x>
|
|
||||||
<y>110</y>
|
|
||||||
<width>201</width>
|
|
||||||
<height>66</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="title">
|
|
||||||
<string>Printer</string>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout_2">
|
|
||||||
<item row="0" column="2">
|
|
||||||
<widget class="QLabel" name="label_6">
|
|
||||||
<property name="text">
|
|
||||||
<string>X</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="1">
|
|
||||||
<widget class="QSpinBox" name="bedxbox">
|
|
||||||
<property name="minimum">
|
|
||||||
<number>1</number>
|
|
||||||
</property>
|
|
||||||
<property name="maximum">
|
|
||||||
<number>9999</number>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="0">
|
|
||||||
<widget class="QLabel" name="label_5">
|
|
||||||
<property name="text">
|
|
||||||
<string>Bed size</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="3">
|
|
||||||
<widget class="QSpinBox" name="bedybox">
|
|
||||||
<property name="minimum">
|
|
||||||
<number>1</number>
|
|
||||||
</property>
|
|
||||||
<property name="maximum">
|
|
||||||
<number>9999</number>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
</widget>
|
||||||
<resources/>
|
<resources>
|
||||||
|
<include location="graphics.qrc"/>
|
||||||
|
</resources>
|
||||||
<connections>
|
<connections>
|
||||||
<connection>
|
<connection>
|
||||||
<sender>buttonBox</sender>
|
<sender>buttonBox</sender>
|
||||||
@ -163,8 +359,8 @@
|
|||||||
<slot>accept()</slot>
|
<slot>accept()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>248</x>
|
<x>243</x>
|
||||||
<y>254</y>
|
<y>376</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>157</x>
|
<x>157</x>
|
||||||
@ -179,11 +375,11 @@
|
|||||||
<slot>reject()</slot>
|
<slot>reject()</slot>
|
||||||
<hints>
|
<hints>
|
||||||
<hint type="sourcelabel">
|
<hint type="sourcelabel">
|
||||||
<x>316</x>
|
<x>243</x>
|
||||||
<y>260</y>
|
<y>376</y>
|
||||||
</hint>
|
</hint>
|
||||||
<hint type="destinationlabel">
|
<hint type="destinationlabel">
|
||||||
<x>286</x>
|
<x>252</x>
|
||||||
<y>274</y>
|
<y>274</y>
|
||||||
</hint>
|
</hint>
|
||||||
</hints>
|
</hints>
|
||||||
|
|||||||