kopia lustrzana https://gitlab.com/Teuniz/DSRemote
Work in progress.
rodzic
caee207a7d
commit
a1f19eb472
|
@ -25,7 +25,7 @@ HEADERS += tmc_dev.h
|
||||||
HEADERS += tled.h
|
HEADERS += tled.h
|
||||||
HEADERS += edflib.h
|
HEADERS += edflib.h
|
||||||
HEADERS += signalcurve.h
|
HEADERS += signalcurve.h
|
||||||
HEADERS += select_device_dialog.h
|
HEADERS += settings_dialog.h
|
||||||
|
|
||||||
SOURCES += main.cpp
|
SOURCES += main.cpp
|
||||||
SOURCES += mainwindow.cpp
|
SOURCES += mainwindow.cpp
|
||||||
|
@ -38,7 +38,7 @@ SOURCES += tmc_dev.c
|
||||||
SOURCES += tled.cpp
|
SOURCES += tled.cpp
|
||||||
SOURCES += edflib.c
|
SOURCES += edflib.c
|
||||||
SOURCES += signalcurve.cpp
|
SOURCES += signalcurve.cpp
|
||||||
SOURCES += select_device_dialog.cpp
|
SOURCES += settings_dialog.cpp
|
||||||
|
|
||||||
RESOURCES = images.qrc
|
RESOURCES = images.qrc
|
||||||
|
|
||||||
|
|
|
@ -26,13 +26,12 @@ Compiling:
|
||||||
|
|
||||||
Install: kernel-desktop-devel kernel-source
|
Install: kernel-desktop-devel kernel-source
|
||||||
|
|
||||||
In the following commands, replace the part "linux-3.16.7-21" with your actual kernel version.
|
In the following commands, replace the part "3.16.7-21-desktop" with your actual kernel version.
|
||||||
The easiest way to get this version is to use the command uname -r.
|
The easiest way to get this version is to use the command uname -r.
|
||||||
|
|
||||||
cp /usr/src/linux-3.16.7-21/include/uapi/linux/usb/tmc.h .
|
cp /lib/modules/3.16.7-21-desktop/source/include/uapi/linux/usb/tmc.h .
|
||||||
|
|
||||||
cp /usr/src/linux-3.16.7-21/drivers/usb/class/usbtmc.c .
|
|
||||||
|
|
||||||
|
cp /lib/modules/3.16.7-21-desktop/source/drivers/usb/class/usbtmc.c .
|
||||||
|
|
||||||
|
|
||||||
Somewhere around line 110 of the file usbtmc.c you will find the following code:
|
Somewhere around line 110 of the file usbtmc.c you will find the following code:
|
||||||
|
|
|
@ -74,13 +74,14 @@ UI_Mainwindow::UI_Mainwindow()
|
||||||
devicemenu->setTitle("Device");
|
devicemenu->setTitle("Device");
|
||||||
devicemenu->addAction("Connect", this, SLOT(open_connection()));
|
devicemenu->addAction("Connect", this, SLOT(open_connection()));
|
||||||
devicemenu->addAction("Disconnect", this, SLOT(close_connection()));
|
devicemenu->addAction("Disconnect", this, SLOT(close_connection()));
|
||||||
devicemenu->addAction("Select", this, SLOT(select_device()));
|
|
||||||
devicemenu->addAction("Exit", this, SLOT(close()), QKeySequence::Quit);
|
devicemenu->addAction("Exit", this, SLOT(close()), QKeySequence::Quit);
|
||||||
menubar->addMenu(devicemenu);
|
menubar->addMenu(devicemenu);
|
||||||
|
|
||||||
|
menubar->addAction("Settings", this, SLOT(open_settings_dialog()));
|
||||||
|
|
||||||
helpmenu = new QMenu;
|
helpmenu = new QMenu;
|
||||||
helpmenu->setTitle("Help");
|
helpmenu->setTitle("Help");
|
||||||
helpmenu->addAction("About", this, SLOT(show_about_dialog()));
|
helpmenu->addAction("About", this, SLOT(show_about_dialog()));
|
||||||
menubar->addMenu(helpmenu);
|
menubar->addMenu(helpmenu);
|
||||||
|
|
||||||
statusLabel = new QLabel;
|
statusLabel = new QLabel;
|
||||||
|
@ -399,7 +400,7 @@ UI_Mainwindow::~UI_Mainwindow()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void UI_Mainwindow::select_device()
|
void UI_Mainwindow::open_settings_dialog()
|
||||||
{
|
{
|
||||||
UI_select_device_window sel_device;
|
UI_select_device_window sel_device;
|
||||||
}
|
}
|
||||||
|
|
|
@ -60,6 +60,7 @@
|
||||||
#include <QPoint>
|
#include <QPoint>
|
||||||
#include <QDial>
|
#include <QDial>
|
||||||
#include <QSettings>
|
#include <QSettings>
|
||||||
|
#include <QProcess>
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
@ -76,7 +77,7 @@
|
||||||
#include "tled.h"
|
#include "tled.h"
|
||||||
#include "edflib.h"
|
#include "edflib.h"
|
||||||
#include "signalcurve.h"
|
#include "signalcurve.h"
|
||||||
#include "select_device_dialog.h"
|
#include "settings_dialog.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -204,7 +205,7 @@ private slots:
|
||||||
void show_about_dialog();
|
void show_about_dialog();
|
||||||
void open_connection();
|
void open_connection();
|
||||||
void close_connection();
|
void close_connection();
|
||||||
void select_device();
|
void open_settings_dialog();
|
||||||
int get_device_settings();
|
int get_device_settings();
|
||||||
void save_waveform();
|
void save_waveform();
|
||||||
void save_screenshot();
|
void save_screenshot();
|
||||||
|
|
|
@ -7,6 +7,12 @@ It does not lock the device, so it's still possible to change settings on the de
|
||||||
This will cause a mismatch between the programs settings and the device settings.
|
This will cause a mismatch between the programs settings and the device settings.
|
||||||
This can be solved by letting the program re-read the settings of the device.
|
This can be solved by letting the program re-read the settings of the device.
|
||||||
At this moment, the only way to do that is to disconnect and connect again.
|
At this moment, the only way to do that is to disconnect and connect again.
|
||||||
|
Some settings are checked regularly and will always be synchronized:
|
||||||
|
- trigger status
|
||||||
|
- trigger sweep
|
||||||
|
- samplerate
|
||||||
|
- memory depth
|
||||||
|
|
||||||
|
|
||||||
Number of screen updates is approx. 20 waveforms per second.
|
Number of screen updates is approx. 20 waveforms per second.
|
||||||
|
|
||||||
|
@ -17,7 +23,6 @@ In addition of using the dials to change the scale and offset of the traces and
|
||||||
you can use the mouse to drag the yellow and orange arrows aside of the plot.
|
you can use the mouse to drag the yellow and orange arrows aside of the plot.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
What's implemented so far:
|
What's implemented so far:
|
||||||
--------------------------
|
--------------------------
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#include "select_device_dialog.h"
|
#include "settings_dialog.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -42,7 +42,7 @@ UI_select_device_window::UI_select_device_window(QDialog *parnt)
|
||||||
|
|
||||||
setMinimumSize(QSize(400, 200));
|
setMinimumSize(QSize(400, 200));
|
||||||
setMaximumSize(QSize(400, 200));
|
setMaximumSize(QSize(400, 200));
|
||||||
setWindowTitle("Device settings");
|
setWindowTitle("Settings");
|
||||||
setModal(true);
|
setModal(true);
|
||||||
|
|
||||||
comboBox1 = new QComboBox(this);
|
comboBox1 = new QComboBox(this);
|
Ładowanie…
Reference in New Issue