Removed clutch state indicator. Added master_stop and obstacle_stop indicators
This commit is contained in:
parent
caa4b1a8fc
commit
34fd379f26
@ -78,12 +78,12 @@ class QtWrapper:
|
|||||||
return None
|
return None
|
||||||
|
|
||||||
def display_clutch_on(self):
|
def display_clutch_on(self):
|
||||||
self.widget.clutchLabel.setPixmap(self.ok_pixmap.scaled(40,40))
|
# self.widget.clutchLabel.setPixmap(self.ok_pixmap.scaled(40,40))
|
||||||
self.widget.clutchButton.setStyleSheet("QPushButton { color: black; background-color: green; font: bold 20px}")
|
self.widget.clutchButton.setStyleSheet("QPushButton { color: black; background-color: green; font: bold 20px}")
|
||||||
self.widget.clutchButton.setText('Rozlacz sprzeglo')
|
self.widget.clutchButton.setText('Rozlacz sprzeglo')
|
||||||
|
|
||||||
def display_clutch_off(self):
|
def display_clutch_off(self):
|
||||||
self.widget.clutchLabel.setPixmap(self.cancel_pixmap.scaled(40,40))
|
# self.widget.clutchLabel.setPixmap(self.cancel_pixmap.scaled(40,40))
|
||||||
self.widget.clutchButton.setStyleSheet("QPushButton { color: black; background-color: red; font: bold 20px}")
|
self.widget.clutchButton.setStyleSheet("QPushButton { color: black; background-color: red; font: bold 20px}")
|
||||||
self.widget.clutchButton.setText('Polacz sprzeglo')
|
self.widget.clutchButton.setText('Polacz sprzeglo')
|
||||||
|
|
||||||
@ -196,10 +196,17 @@ class QtWrapper:
|
|||||||
else:
|
else:
|
||||||
self.display_state_off()
|
self.display_state_off()
|
||||||
|
|
||||||
|
if robot_info.obstacle_detected == True:
|
||||||
|
self.widget.obstaclestopLabel.setPixmap(self.cancel_pixmap.scaled(40,40))
|
||||||
|
else:
|
||||||
|
self.widget.obstaclestopLabel.setPixmap(self.ok_pixmap.scaled(40,40))
|
||||||
|
|
||||||
def master_stopped(self):
|
def master_stopped(self):
|
||||||
|
self.widget.masterstopLabel.setPixmap(self.cancel_pixmap.scaled(40,40))
|
||||||
self.log_info('Przycisk masterSTOP zostal nacisniety. Zatrzymuje roboty')
|
self.log_info('Przycisk masterSTOP zostal nacisniety. Zatrzymuje roboty')
|
||||||
|
|
||||||
def master_started(self):
|
def master_started(self):
|
||||||
|
self.widget.masterstopLabel.setPixmap(self.ok_pixmap.scaled(40,40))
|
||||||
self.log_info('Przycisk masterSTOP odcisniety. Mozesz uruchomic robota')
|
self.log_info('Przycisk masterSTOP odcisniety. Mozesz uruchomic robota')
|
||||||
|
|
||||||
def user_stopped(self):
|
def user_stopped(self):
|
||||||
@ -288,7 +295,8 @@ class QtWrapper:
|
|||||||
self.widget.linearLabel.setText('-')
|
self.widget.linearLabel.setText('-')
|
||||||
self.widget.angularLabel.setText('-')
|
self.widget.angularLabel.setText('-')
|
||||||
self.widget.stateLabel.setText('-')
|
self.widget.stateLabel.setText('-')
|
||||||
self.widget.clutchLabel.setText('-')
|
self.widget.masterstopLabel.setText('-')
|
||||||
|
self.widget.obstaclestopLabel.setText('-')
|
||||||
|
|
||||||
self.widget.choiceButton.setText('Wybierz')
|
self.widget.choiceButton.setText('Wybierz')
|
||||||
|
|
||||||
|
@ -75,7 +75,7 @@
|
|||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2" stretch="4,2,3">
|
<layout class="QHBoxLayout" name="horizontalLayout_2" stretch="4,2,3">
|
||||||
<item>
|
<item>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout" stretch="1,1,1,1,2,2">
|
<layout class="QVBoxLayout" name="verticalLayout" stretch="1,1,1,1,2,2,2">
|
||||||
<property name="sizeConstraint">
|
<property name="sizeConstraint">
|
||||||
<enum>QLayout::SetDefaultConstraint</enum>
|
<enum>QLayout::SetDefaultConstraint</enum>
|
||||||
</property>
|
</property>
|
||||||
@ -110,21 +110,28 @@
|
|||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="label_9">
|
<widget class="QLabel" name="label_9">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string><html><head/><body><p align="center"><span style=" font-weight:600;">Stan sprzegla</span></p></body></html></string>
|
<string><html><head/><body><p align="center"><span style=" font-weight:600;">Stan robota</span></p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="label_10">
|
<widget class="QLabel" name="label_10">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string><html><head/><body><p align="center"><span style=" font-weight:600;">Stan stopu</span></p></body></html></string>
|
<string><html><head/><body><p align="center"><span style=" font-weight:600;">Stop mastera</span></p></body></html></string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_2">
|
||||||
|
<property name="text">
|
||||||
|
<string><html><head/><body><p align="center"><span style=" font-weight:600;">Stop przeszkody</span></p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2" stretch="1,1,1,1,2,2">
|
<layout class="QVBoxLayout" name="verticalLayout_2" stretch="1,1,1,1,2,2,0">
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="idLabel">
|
<widget class="QLabel" name="idLabel">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
@ -166,7 +173,7 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="clutchLabel">
|
<widget class="QLabel" name="stateLabel">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string><html><head/><body><p align="center">-</p></body></html></string>
|
<string><html><head/><body><p align="center">-</p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
@ -176,7 +183,17 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="stateLabel">
|
<widget class="QLabel" name="masterstopLabel">
|
||||||
|
<property name="text">
|
||||||
|
<string><html><head/><body><p align="center">-</p></body></html></string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="obstaclestopLabel">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string><html><head/><body><p align="center">-</p></body></html></string>
|
<string><html><head/><body><p align="center">-</p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
|
Loading…
Reference in New Issue
Block a user