debug module almost done

This commit is contained in:
Pavol Rusnak 2011-04-17 23:39:10 +02:00
parent 75704ff29f
commit ac9283af0e
5 changed files with 682 additions and 259 deletions

View file

@ -9,13 +9,13 @@ void GetInReport (uint8_t src[], uint32_t length)
uint32_t volatile reg = LPC_USB->CmdCode; uint32_t volatile reg = LPC_USB->CmdCode;
if (reg & (5<<8)) return; if (reg & (5<<8)) return;
for (i=0; i<4; ++i) { for (i=0; i<6; ++i) {
uint32_t v = ADCRead(i); uint32_t v = ADCRead(i);
src[i*2 ] = v & 0xff; src[i*2 ] = v & 0xff;
src[i*2+1] = (v>>8) & 0xff; src[i*2+1] = (v>>8) & 0xff;
} }
// TODO: fix the following - replace IP[i] with real value if input pin (I) // TODO: fix the following - replace IP[i] with real value of input pin (I)
// src[8] = IP[0] + (IP[1]<<1) + (IP[2]<<2) + (IP[3]<<3) + (IP[4]<<4) + (IP[5]<<5) + (IP[6]<<6) + (IP[7]<<7); // src[12] = IP[0] + (IP[1]<<1) + (IP[2]<<2);
} }
void SetOutReport (uint8_t dst[], uint32_t length) void SetOutReport (uint8_t dst[], uint32_t length)
@ -32,33 +32,30 @@ void SetOutReport (uint8_t dst[], uint32_t length)
break; break;
case 'd': case 'd':
wavetype = dst[1]; wavetype = dst[1];
freq = dst[2] + (dst[3]<<8) + (dst[4]<<16) + (dst[5]<<24); // TODO: set DDS to (wavetype)
// TODO: set DDS to (wavetype) of (freq) Hz break;
case 'D':
freq = dst[1] + (dst[2]<<8) + (dst[3]<<16) + (dst[4]<<24);
// TODO: set DDS to (freq) Hz
break; break;
case 'm': case 'm':
which = dst[1]; which = dst[1];
mult = dst[2] + (dst[3]<<8); chan = dst[2];
// TODO: set opamp (which) on channel (chan) with multiplicator (mult) gain = dst[3];
// TODO: set opamp (which) on channel (chan) with gain (gain)
break; break;
case 's': case 's':
which = dst[1];
if (dst[2]) {
// TODO: set switch (which) to on
} else {
// TODO: set switch (which) to off
}
break;
case 'S':
states = dst[1]; states = dst[1];
// TODO: set switches to states // TODO: set switches to states
break; break;
case 'o': case 'P':
which = dst[1]; states = dst[1];
// TODO: set output pins to 0 where indicated by (which) // TODO: set pins to states
break; break;
case 'O': case 'o':
which = dst[1]; which = dst[1] >> 1;
// TODO: set output pins to 1 where indicated by (which) state = dst[1] & 0x01;
// TODO: set output pins (which) to state (state)
break; break;
} }
} }

View file

@ -27,33 +27,33 @@ class Device:
def pwm(self, which, duty): def pwm(self, which, duty):
self.epo.write('p' + chr(which) + chr(duty & 0xff) + chr(duty >> 8)) self.epo.write('p' + chr(which) + chr(duty & 0xff) + chr(duty >> 8))
# sets dds (wave=square,sine,saw1,saw2), (freq=32bit) # sets ddswave (wave=square,sine,saw1,saw2)
def dds(self, wavetype, freq): def ddswave(self, wavetype):
self.epo.write('d' + chr(wavetype) + chr(freq & 0xff) + chr((freq >> 8) & 0xff) + chr((freq >> 16) & 0xff) + chr(freq >> 24)) self.epo.write('d' + chr(wavetype))
# set opamp (which=1,2), (mult=16bit) # sets ddsfreq (freq=32bit)
def opamp(self, which, mult): def ddsfreq(self, freq):
self.epo.write('m' + chr(which) + chr(mult & 0xff) + chr(mult >> 8)) self.epo.write('D' + chr(freq & 0xff) + chr((freq >> 8) & 0xff) + chr((freq >> 16) & 0xff) + chr(freq >> 24))
# set switch (which=1..8), state=(0,1) # set opamp (which=1,2), (chan=1..6), (gain=1, 2, 4, 5, 8, 10, 16, 32)
def switch(self, which, state): def opamp(self, which, chan, gain):
self.epo.write('s' + chr(which) + (state and '\x01' or '\x00')) self.epo.write('m' + chr(which) + chr(chan) + chr(gain))
# set all switches (which=8bit) # set all switches (states=6bit)
def switches(self, states): def switches(self, states):
self.epo.write('S' + chr(states)) self.epo.write('s' + chr(states))
# clear output (which=8bit) # set pins state (states=3bit) (1 = input, 0 = output)
def clrout(self, which): def setpins(self, states):
self.epo.write('o' + chr(which)) self.epo.write('P' + chr(states))
# set output (which=8bit) # set output (which=1,2,3), (state=0,1)
def setout(self, which): def setout(self, which, state):
self.epo.write('O' + chr(which)) self.epo.write('o' + chr(which<<1 + state))
def state(self): def read(self):
# 4x AD (16 bits) + 8x I # 6x AD (16 bits) + 3 x I
i = self.epi.read(self.INSIZE) i = self.epi.read(self.INSIZE)
return (i[0] + i[1]<<8, i[2] + i[3]<<8, i[4] + i[5]<<8, i[6] + i[7]<<8, return (i[0] + i[1]<<8, i[2] + i[3]<<8, i[4] + i[5]<<8,
i[8] & 0x01, i[8] & 0x02, i[8] & 0x04, i[8] & 0x08, i[6] + i[7]<<8, i[9] + i[9]<<8, i[10] + i[11]<<8,
i[8] & 0x10, i[8] & 0x20, i[8] & 0x40, i[8] & 0x80) i[12] & 0x01, (i[12] & 0x02) >> 1, (i[12] & 0x04) >> 2)

View file

@ -1,5 +1,7 @@
from PyQt4.QtGui import QWidget from PyQt4.QtGui import QWidget
from PyQt4.QtCore import pyqtSlot from PyQt4.QtCore import pyqtSlot
from PyQt4.QtCore import SIGNAL
from PyQt4.QtCore import QObject
from ModuleDebugUi import Ui_ModuleDebug from ModuleDebugUi import Ui_ModuleDebug
#from device import Device #from device import Device
@ -9,6 +11,20 @@ class ModuleDebugWidget(QWidget):
QWidget.__init__(self) QWidget.__init__(self)
self.ui = Ui_ModuleDebug() self.ui = Ui_ModuleDebug()
self.ui.setupUi(self) self.ui.setupUi(self)
QObject.connect(self.ui.comboAMP1c, SIGNAL("currentIndexChanged(int)"), self.on_comboAMP1_changed)
QObject.connect(self.ui.comboAMP1g, SIGNAL("currentIndexChanged(int)"), self.on_comboAMP1_changed)
QObject.connect(self.ui.comboAMP2c, SIGNAL("currentIndexChanged(int)"), self.on_comboAMP2_changed)
QObject.connect(self.ui.comboAMP2g, SIGNAL("currentIndexChanged(int)"), self.on_comboAMP2_changed)
QObject.connect(self.ui.pushSwitch1, SIGNAL("clicked(bool)"), self.on_switches_changed)
QObject.connect(self.ui.pushSwitch2, SIGNAL("clicked(bool)"), self.on_switches_changed)
QObject.connect(self.ui.pushSwitch3, SIGNAL("clicked(bool)"), self.on_switches_changed)
QObject.connect(self.ui.pushSwitch4, SIGNAL("clicked(bool)"), self.on_switches_changed)
QObject.connect(self.ui.pushSwitch5, SIGNAL("clicked(bool)"), self.on_switches_changed)
QObject.connect(self.ui.pushSwitch6, SIGNAL("clicked(bool)"), self.on_switches_changed)
QObject.connect(self.ui.pushPin1, SIGNAL("clicked(bool)"), self.on_pins_changed)
QObject.connect(self.ui.pushPin2, SIGNAL("clicked(bool)"), self.on_pins_changed)
QObject.connect(self.ui.pushPin3, SIGNAL("clicked(bool)"), self.on_pins_changed)
# self.dev = Device() # self.dev = Device()
@pyqtSlot(int) @pyqtSlot(int)
@ -71,6 +87,84 @@ class ModuleDebugWidget(QWidget):
# state and self.dev.setout(1<<7) or self.dev.clrout(1<<7) # state and self.dev.setout(1<<7) or self.dev.clrout(1<<7)
print 'out7:', state and '1' or '0' print 'out7:', state and '1' or '0'
@pyqtSlot(bool)
def on_radioSine_clicked(self, checked):
# self.dev.ddswave(0)
print 'dds: sine'
@pyqtSlot(bool)
def on_radioSquare_clicked(self, checked):
# self.dev.ddswave(1)
print 'dds: square'
@pyqtSlot(bool)
def on_radioSaw_clicked(self, checked):
# self.dev.ddswave(2)
print 'dds: saw'
@pyqtSlot(bool)
def on_radioInvSaw_clicked(self, checked):
# self.dev.ddswave(3)
print 'dds: invsaw'
@pyqtSlot(int)
def on_dialDDS_valueChanged(self, val):
# self.dev.ddsfreq(val)
print 'dds:', val
@pyqtSlot()
def on_comboAMP1_changed(self):
c = self.ui.comboAMP1c.currentIndex() + 1
g = (1,2,4,5,8,10,16,32)[self.ui.comboAMP1g.currentIndex()]
# self.dev.opamp(1, c, g)
print 'amp1:', c, g
@pyqtSlot()
def on_comboAMP2_changed(self):
c = self.ui.comboAMP2c.currentIndex() + 1
g = (1,2,4,5,8,10,16,32)[self.ui.comboAMP2g.currentIndex()]
# self.dev.opamp(2, c, g)
print 'amp2:', c, g
@pyqtSlot()
def on_switches_changed(self):
s = (self.ui.pushSwitch1.isChecked() and 1 or 0,
self.ui.pushSwitch2.isChecked() and 1 or 0,
self.ui.pushSwitch3.isChecked() and 1 or 0,
self.ui.pushSwitch4.isChecked() and 1 or 0,
self.ui.pushSwitch5.isChecked() and 1 or 0,
self.ui.pushSwitch6.isChecked() and 1 or 0)
# self.dev.switches(s[0] + s[1]<<1 + s[2]<<2 + s[3]<<3 + s[4]<<4 + s[5]<<5)
print 'switches:', s
@pyqtSlot()
def on_pins_changed(self):
s = (self.ui.pushPin1.isChecked() and 1 or 0,
self.ui.pushPin2.isChecked() and 1 or 0,
self.ui.pushPin3.isChecked() and 1 or 0)
self.ui.pushOut1.setEnabled(not s[0])
self.ui.pushOut2.setEnabled(not s[1])
self.ui.pushOut3.setEnabled(not s[2])
# self.dev.setpins(s[0] + s[1]<<1 + s[2]<<2)
print 'pins:', s
@pyqtSlot(bool)
def on_pushOut1_clicked(self, checked):
# self.dev.setout(1, checked and 1 or 0)
print 'out1:', checked and 1 or 0
@pyqtSlot(bool)
def on_pushOut2_clicked(self, checked):
# self.dev.setout(2, checked and 1 or 0)
print 'out2:', checked and 1 or 0
@pyqtSlot(bool)
def on_pushOut3_clicked(self, checked):
# self.dev.setout(3, checked and 1 or 0)
print 'out3:', checked and 1 or 0
class ModuleDebug(): class ModuleDebug():
def __init__(self): def __init__(self):

View file

@ -116,7 +116,7 @@
<rect> <rect>
<x>190</x> <x>190</x>
<y>10</y> <y>10</y>
<width>201</width> <width>211</width>
<height>131</height> <height>131</height>
</rect> </rect>
</property> </property>
@ -126,7 +126,7 @@
<widget class="QSpinBox" name="lineDDS"> <widget class="QSpinBox" name="lineDDS">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>90</x> <x>100</x>
<y>90</y> <y>90</y>
<width>101</width> <width>101</width>
<height>31</height> <height>31</height>
@ -136,13 +136,16 @@
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property> </property>
<property name="text" stdset="0"> <property name="text" stdset="0">
<string>0</string> <string>1</string>
</property>
<property name="minimum">
<number>1</number>
</property> </property>
<property name="maximum"> <property name="maximum">
<number>16777216</number> <number>50000000</number>
</property> </property>
<property name="value"> <property name="value">
<number>0</number> <number>1</number>
</property> </property>
<property name="maxLength" stdset="0"> <property name="maxLength" stdset="0">
<number>8</number> <number>8</number>
@ -151,14 +154,17 @@
<widget class="QDial" name="dialDDS"> <widget class="QDial" name="dialDDS">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>90</x> <x>100</x>
<y>10</y> <y>10</y>
<width>101</width> <width>101</width>
<height>81</height> <height>81</height>
</rect> </rect>
</property> </property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum"> <property name="maximum">
<number>16777216</number> <number>50000000</number>
</property> </property>
<property name="pageStep"> <property name="pageStep">
<number>100</number> <number>100</number>
@ -169,7 +175,7 @@
<rect> <rect>
<x>10</x> <x>10</x>
<y>30</y> <y>30</y>
<width>71</width> <width>81</width>
<height>26</height> <height>26</height>
</rect> </rect>
</property> </property>
@ -185,7 +191,7 @@
<rect> <rect>
<x>10</x> <x>10</x>
<y>50</y> <y>50</y>
<width>71</width> <width>81</width>
<height>26</height> <height>26</height>
</rect> </rect>
</property> </property>
@ -198,7 +204,7 @@
<rect> <rect>
<x>10</x> <x>10</x>
<y>70</y> <y>70</y>
<width>71</width> <width>81</width>
<height>26</height> <height>26</height>
</rect> </rect>
</property> </property>
@ -211,7 +217,7 @@
<rect> <rect>
<x>10</x> <x>10</x>
<y>90</y> <y>90</y>
<width>71</width> <width>81</width>
<height>26</height> <height>26</height>
</rect> </rect>
</property> </property>
@ -225,8 +231,8 @@
<rect> <rect>
<x>10</x> <x>10</x>
<y>150</y> <y>150</y>
<width>171</width> <width>151</width>
<height>131</height> <height>111</height>
</rect> </rect>
</property> </property>
<property name="title"> <property name="title">
@ -235,218 +241,581 @@
<property name="alignment"> <property name="alignment">
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set> <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
</property> </property>
<widget class="QSpinBox" name="lineAMP1"> <widget class="QComboBox" name="comboAMP1c">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>10</x>
<y>90</y> <y>30</y>
<width>71</width> <width>61</width>
<height>31</height> <height>31</height>
</rect> </rect>
</property> </property>
<property name="alignment"> <item>
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> <property name="text">
</property> <string>ch 1</string>
<property name="text" stdset="0"> </property>
<string>0</string> </item>
</property> <item>
<property name="maximum"> <property name="text">
<number>65535</number> <string>ch 2</string>
</property> </property>
<property name="value"> </item>
<number>0</number> <item>
</property> <property name="text">
<property name="maxLength" stdset="0"> <string>ch 3</string>
<number>5</number> </property>
</property> </item>
<item>
<property name="text">
<string>ch 4</string>
</property>
</item>
<item>
<property name="text">
<string>ch 5</string>
</property>
</item>
<item>
<property name="text">
<string>ch 6</string>
</property>
</item>
</widget> </widget>
<widget class="QSpinBox" name="lineAMP2"> <widget class="QComboBox" name="comboAMP2c">
<property name="geometry">
<rect>
<x>90</x>
<y>90</y>
<width>71</width>
<height>31</height>
</rect>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="text" stdset="0">
<string>0</string>
</property>
<property name="maximum">
<number>65535</number>
</property>
<property name="value">
<number>0</number>
</property>
<property name="maxLength" stdset="0">
<number>5</number>
</property>
</widget>
<widget class="QDial" name="dialAMP2">
<property name="geometry">
<rect>
<x>90</x>
<y>20</y>
<width>71</width>
<height>71</height>
</rect>
</property>
<property name="maximum">
<number>65535</number>
</property>
<property name="pageStep">
<number>256</number>
</property>
</widget>
<widget class="QDial" name="dialAMP1">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>10</x>
<y>20</y> <y>70</y>
<width>71</width> <width>61</width>
<height>71</height> <height>31</height>
</rect> </rect>
</property> </property>
<property name="maximum"> <item>
<number>65535</number> <property name="text">
<string>ch 1</string>
</property>
</item>
<item>
<property name="text">
<string>ch 2</string>
</property>
</item>
<item>
<property name="text">
<string>ch 3</string>
</property>
</item>
<item>
<property name="text">
<string>ch 4</string>
</property>
</item>
<item>
<property name="text">
<string>ch 5</string>
</property>
</item>
<item>
<property name="text">
<string>ch 6</string>
</property>
</item>
</widget>
<widget class="QComboBox" name="comboAMP1g">
<property name="geometry">
<rect>
<x>80</x>
<y>30</y>
<width>61</width>
<height>31</height>
</rect>
</property> </property>
<property name="pageStep"> <item>
<number>256</number> <property name="text">
<string>* 1</string>
</property>
</item>
<item>
<property name="text">
<string>* 2</string>
</property>
</item>
<item>
<property name="text">
<string>* 4</string>
</property>
</item>
<item>
<property name="text">
<string>* 5</string>
</property>
</item>
<item>
<property name="text">
<string>* 8</string>
</property>
</item>
<item>
<property name="text">
<string>* 10</string>
</property>
</item>
<item>
<property name="text">
<string>* 16</string>
</property>
</item>
<item>
<property name="text">
<string>* 32</string>
</property>
</item>
</widget>
<widget class="QComboBox" name="comboAMP2g">
<property name="geometry">
<rect>
<x>80</x>
<y>70</y>
<width>61</width>
<height>31</height>
</rect>
</property> </property>
<item>
<property name="text">
<string>* 1</string>
</property>
</item>
<item>
<property name="text">
<string>* 2</string>
</property>
</item>
<item>
<property name="text">
<string>* 4</string>
</property>
</item>
<item>
<property name="text">
<string>* 5</string>
</property>
</item>
<item>
<property name="text">
<string>* 8</string>
</property>
</item>
<item>
<property name="text">
<string>* 10</string>
</property>
</item>
<item>
<property name="text">
<string>* 16</string>
</property>
</item>
<item>
<property name="text">
<string>* 32</string>
</property>
</item>
</widget> </widget>
</widget> </widget>
<widget class="QGroupBox" name="groupOut"> <widget class="QGroupBox" name="groupOut">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>190</x> <x>170</x>
<y>150</y> <y>150</y>
<width>201</width> <width>151</width>
<height>61</height> <height>111</height>
</rect> </rect>
</property> </property>
<property name="title"> <property name="title">
<string>Outputs</string> <string>IO Pins (up=O, dn=I)</string>
</property> </property>
<widget class="QCheckBox" name="checkOut7"> <widget class="QPushButton" name="pushPin1">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>10</x> <x>10</x>
<y>30</y> <y>30</y>
<width>21</width> <width>31</width>
<height>26</height> <height>31</height>
</rect> </rect>
</property> </property>
<property name="text"> <property name="text">
<string/> <string>1</string>
</property>
<property name="checkable">
<bool>true</bool>
</property> </property>
</widget> </widget>
<widget class="QCheckBox" name="checkOut6"> <widget class="QPushButton" name="pushPin2">
<property name="geometry">
<rect>
<x>30</x>
<y>30</y>
<width>21</width>
<height>26</height>
</rect>
</property>
<property name="text">
<string/>
</property>
</widget>
<widget class="QCheckBox" name="checkOut5">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>50</x> <x>50</x>
<y>30</y> <y>30</y>
<width>21</width> <width>31</width>
<height>26</height> <height>31</height>
</rect> </rect>
</property> </property>
<property name="text"> <property name="text">
<string/> <string>2</string>
</property>
<property name="checkable">
<bool>true</bool>
</property> </property>
</widget> </widget>
<widget class="QCheckBox" name="checkOut4"> <widget class="QPushButton" name="pushPin3">
<property name="geometry">
<rect>
<x>70</x>
<y>30</y>
<width>21</width>
<height>26</height>
</rect>
</property>
<property name="text">
<string/>
</property>
</widget>
<widget class="QCheckBox" name="checkOut3">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>90</x> <x>90</x>
<y>30</y> <y>30</y>
<width>21</width> <width>31</width>
<height>26</height> <height>31</height>
</rect> </rect>
</property> </property>
<property name="text"> <property name="text">
<string/> <string>3</string>
</property>
<property name="checkable">
<bool>true</bool>
</property> </property>
</widget> </widget>
<widget class="QCheckBox" name="checkOut2"> <widget class="QPushButton" name="pushOut1">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>110</x> <x>10</x>
<y>30</y> <y>70</y>
<width>21</width> <width>31</width>
<height>26</height> <height>31</height>
</rect> </rect>
</property> </property>
<property name="text"> <property name="text">
<string/> <string>O</string>
</property>
<property name="checkable">
<bool>true</bool>
</property> </property>
</widget> </widget>
<widget class="QCheckBox" name="checkOut1"> <widget class="QPushButton" name="pushOut2">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>130</x> <x>50</x>
<y>30</y> <y>70</y>
<width>21</width> <width>31</width>
<height>26</height> <height>31</height>
</rect> </rect>
</property> </property>
<property name="text"> <property name="text">
<string/> <string>O</string>
</property>
<property name="checkable">
<bool>true</bool>
</property> </property>
</widget> </widget>
<widget class="QCheckBox" name="checkOut0"> <widget class="QPushButton" name="pushOut3">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>150</x> <x>90</x>
<y>30</y> <y>70</y>
<width>21</width> <width>31</width>
<height>26</height> <height>31</height>
</rect> </rect>
</property> </property>
<property name="text"> <property name="text">
<string/> <string>O</string>
</property>
<property name="checkable">
<bool>true</bool>
</property> </property>
</widget> </widget>
</widget> </widget>
<widget class="QLabel" name="label"> <widget class="QGroupBox" name="groupSwitches">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>200</x> <x>330</x>
<y>200</y> <y>150</y>
<width>161</width> <width>141</width>
<height>21</height> <height>111</height>
</rect> </rect>
</property> </property>
<property name="text"> <property name="title">
<string> 7 6 5 4 3 2 1 0</string> <string>Switches</string>
</property> </property>
<widget class="QPushButton" name="pushSwitch1">
<property name="geometry">
<rect>
<x>10</x>
<y>30</y>
<width>31</width>
<height>31</height>
</rect>
</property>
<property name="text">
<string>1</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
</widget>
<widget class="QPushButton" name="pushSwitch2">
<property name="geometry">
<rect>
<x>50</x>
<y>30</y>
<width>31</width>
<height>31</height>
</rect>
</property>
<property name="text">
<string>2</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
</widget>
<widget class="QPushButton" name="pushSwitch3">
<property name="geometry">
<rect>
<x>90</x>
<y>30</y>
<width>31</width>
<height>31</height>
</rect>
</property>
<property name="text">
<string>3</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
</widget>
<widget class="QPushButton" name="pushSwitch6">
<property name="geometry">
<rect>
<x>90</x>
<y>70</y>
<width>31</width>
<height>31</height>
</rect>
</property>
<property name="text">
<string>6</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
</widget>
<widget class="QPushButton" name="pushSwitch5">
<property name="geometry">
<rect>
<x>50</x>
<y>70</y>
<width>31</width>
<height>31</height>
</rect>
</property>
<property name="text">
<string>5</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
</widget>
<widget class="QPushButton" name="pushSwitch4">
<property name="geometry">
<rect>
<x>10</x>
<y>70</y>
<width>31</width>
<height>31</height>
</rect>
</property>
<property name="text">
<string>4</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
</widget>
</widget>
<widget class="QGroupBox" name="groupInput">
<property name="geometry">
<rect>
<x>10</x>
<y>270</y>
<width>461</width>
<height>151</height>
</rect>
</property>
<property name="title">
<string>Input</string>
</property>
<widget class="QDial" name="dialInputFreq">
<property name="geometry">
<rect>
<x>10</x>
<y>30</y>
<width>81</width>
<height>81</height>
</rect>
</property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>999</number>
</property>
<property name="pageStep">
<number>10</number>
</property>
</widget>
<widget class="QSpinBox" name="lineInputFreq">
<property name="geometry">
<rect>
<x>10</x>
<y>110</y>
<width>81</width>
<height>31</height>
</rect>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
<property name="text" stdset="0">
<string>1</string>
</property>
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>999</number>
</property>
<property name="value">
<number>1</number>
</property>
<property name="maxLength" stdset="0">
<number>3</number>
</property>
</widget>
<widget class="QLabel" name="labelAD1">
<property name="geometry">
<rect>
<x>110</x>
<y>20</y>
<width>91</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>AD1: 0</string>
</property>
</widget>
<widget class="QLabel" name="labelAD2">
<property name="geometry">
<rect>
<x>110</x>
<y>40</y>
<width>91</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>AD2: 0</string>
</property>
</widget>
<widget class="QLabel" name="labelAD3">
<property name="geometry">
<rect>
<x>110</x>
<y>60</y>
<width>91</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>AD3: 0</string>
</property>
</widget>
<widget class="QLabel" name="labelAD4">
<property name="geometry">
<rect>
<x>110</x>
<y>80</y>
<width>91</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>AD4: 0</string>
</property>
</widget>
<widget class="QLabel" name="labelAD5">
<property name="geometry">
<rect>
<x>110</x>
<y>100</y>
<width>91</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>AD5: 0</string>
</property>
</widget>
<widget class="QLabel" name="labelAD6">
<property name="geometry">
<rect>
<x>110</x>
<y>120</y>
<width>91</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>AD6: 0</string>
</property>
</widget>
<widget class="QLabel" name="labelIO2">
<property name="geometry">
<rect>
<x>210</x>
<y>40</y>
<width>91</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>IO2: 0</string>
</property>
</widget>
<widget class="QLabel" name="labelIO3">
<property name="geometry">
<rect>
<x>210</x>
<y>60</y>
<width>91</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>IO3: 0</string>
</property>
</widget>
<widget class="QLabel" name="labelIO1">
<property name="geometry">
<rect>
<x>210</x>
<y>20</y>
<width>91</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string>IO1: 0</string>
</property>
</widget>
</widget> </widget>
</widget> </widget>
<resources/> <resources/>
@ -515,70 +884,6 @@
</hint> </hint>
</hints> </hints>
</connection> </connection>
<connection>
<sender>dialAMP1</sender>
<signal>valueChanged(int)</signal>
<receiver>lineAMP1</receiver>
<slot>setValue(int)</slot>
<hints>
<hint type="sourcelabel">
<x>55</x>
<y>205</y>
</hint>
<hint type="destinationlabel">
<x>55</x>
<y>255</y>
</hint>
</hints>
</connection>
<connection>
<sender>dialAMP2</sender>
<signal>valueChanged(int)</signal>
<receiver>lineAMP2</receiver>
<slot>setValue(int)</slot>
<hints>
<hint type="sourcelabel">
<x>135</x>
<y>205</y>
</hint>
<hint type="destinationlabel">
<x>135</x>
<y>255</y>
</hint>
</hints>
</connection>
<connection>
<sender>lineAMP1</sender>
<signal>valueChanged(int)</signal>
<receiver>dialAMP1</receiver>
<slot>setValue(int)</slot>
<hints>
<hint type="sourcelabel">
<x>55</x>
<y>255</y>
</hint>
<hint type="destinationlabel">
<x>55</x>
<y>205</y>
</hint>
</hints>
</connection>
<connection>
<sender>lineAMP2</sender>
<signal>valueChanged(int)</signal>
<receiver>dialAMP2</receiver>
<slot>setValue(int)</slot>
<hints>
<hint type="sourcelabel">
<x>135</x>
<y>255</y>
</hint>
<hint type="destinationlabel">
<x>135</x>
<y>205</y>
</hint>
</hints>
</connection>
<connection> <connection>
<sender>dialDDS</sender> <sender>dialDDS</sender>
<signal>valueChanged(int)</signal> <signal>valueChanged(int)</signal>
@ -611,5 +916,37 @@
</hint> </hint>
</hints> </hints>
</connection> </connection>
<connection>
<sender>dialInputFreq</sender>
<signal>valueChanged(int)</signal>
<receiver>lineInputFreq</receiver>
<slot>setValue(int)</slot>
<hints>
<hint type="sourcelabel">
<x>70</x>
<y>340</y>
</hint>
<hint type="destinationlabel">
<x>70</x>
<y>395</y>
</hint>
</hints>
</connection>
<connection>
<sender>lineInputFreq</sender>
<signal>valueChanged(int)</signal>
<receiver>dialInputFreq</receiver>
<slot>setValue(int)</slot>
<hints>
<hint type="sourcelabel">
<x>70</x>
<y>395</y>
</hint>
<hint type="destinationlabel">
<x>70</x>
<y>340</y>
</hint>
</hints>
</connection>
</connections> </connections>
</ui> </ui>

View file

@ -1,5 +0,0 @@
#!/usr/bin/python
from device import Device
d = Device()