Skip to content
Snippets Groups Projects
Commit 6c43100b authored by ft-Demo's avatar ft-Demo
Browse files

commit by robo pro coding

parent cf8b73bc
No related branches found
No related tags found
No related merge requests found
......@@ -67,6 +67,26 @@
</block>
</statement>
</block>
<block type="display_on_button_clicked" id="%H:dts)4aQ!}OuUWw5PR" x="741" y="482">
<field name="instance_name">txt_button_grip</field>
<statement name="statement">
<block type="import_function_noreturn" id="-3a)Bzrad{RAJ|)1Dr~)">
<mutation parentId="T-3m]M%pD$G?7-nv5K0U"/>
<field name="name">grip</field>
<data>T-3m]M%pD$G?7-nv5K0U</data>
</block>
</statement>
</block>
<block type="display_on_button_clicked" id="J9N}D$=hmb#8GfM7/wU)" x="743" y="587">
<field name="instance_name">txt_button_release</field>
<statement name="statement">
<block type="import_function_noreturn" id="UM$DnJP7Mld;|n?IL/u{">
<mutation parentId="%qNAO.=,W#vTG#NYT}L["/>
<field name="name">release</field>
<data>%qNAO.=,W#vTG#NYT}L[</data>
</block>
</statement>
</block>
<block type="display_on_button_clicked" id="2cN^BkF(w5C-Hjb0]5$G" x="0" y="723">
<field name="instance_name">txt_button_acknowledge</field>
<statement name="statement">
......@@ -85,6 +105,36 @@
</block>
</statement>
</block>
<block type="display_on_button_clicked" id="jChC7aeYTYEg]VI=X:?a" x="743" y="689">
<field name="instance_name">txt_button_pos0</field>
<statement name="statement">
<block type="import_function_noreturn" id="9kW/-O:6$fRB3/+-/D~X">
<mutation parentId="{S~eYro!kXU:h4Q]vq*V"/>
<field name="name">moveAbs_VGR_P123_name</field>
<data>{S~eYro!kXU:h4Q]vq*V</data>
<value name="name">
<block type="text" id="u:h[++z)e1=b~JC.D@j)">
<field name="TEXT">SLD blue</field>
</block>
</value>
</block>
</statement>
</block>
<block type="display_on_button_clicked" id="lco7KxOqm3S*fY$-Q.ED" x="754" y="833">
<field name="instance_name">txt_button_pos1</field>
<statement name="statement">
<block type="import_function_noreturn" id="juA7q*{Z$9XW+@dCPzb=">
<mutation parentId="{S~eYro!kXU:h4Q]vq*V"/>
<field name="name">moveAbs_VGR_P123_name</field>
<data>{S~eYro!kXU:h4Q]vq*V</data>
<value name="name">
<block type="text" id="Z08c2S|d@Mx~6?U4LMe7">
<field name="TEXT">SLD red</field>
</block>
</value>
</block>
</statement>
</block>
<block type="display_on_button_clicked" id="Ac@+7yXb5`XaApz(VKsr" x="0" y="879">
<field name="instance_name">txt_button_park</field>
<statement name="statement">
......@@ -120,4 +170,19 @@
</block>
</statement>
</block>
<block type="display_on_button_clicked" id="O$I/AzQOuev[STU6[kMv" x="753" y="992">
<field name="instance_name">txt_button_pos2</field>
<statement name="statement">
<block type="import_function_noreturn" id="wW?tDo^n(@==@Fx;533Z">
<mutation parentId="{S~eYro!kXU:h4Q]vq*V"/>
<field name="name">moveAbs_VGR_P123_name</field>
<data>{S~eYro!kXU:h4Q]vq*V</data>
<value name="name">
<block type="text" id="]n+KkXl17iaxIJT?L;4H">
<field name="TEXT">SLD white</field>
</block>
</value>
</block>
</statement>
</block>
</xml>
\ No newline at end of file
......@@ -5,6 +5,8 @@ from lib.display import *
from lib.Factory import *
from lib.Factory_Variables import *
from lib.Test import *
from lib.VGR import *
from lib.VGR_Axes1Ref import *
_tr0 = None
......@@ -27,6 +29,26 @@ def on_txt_button_acknowledge_clicked(event):
set_factory_error_state(None)
def on_txt_button_grip_clicked(event):
global _tr0, _tr, _dg
grip()
def on_txt_button_release_clicked(event):
global _tr0, _tr, _dg
release()
def on_txt_button_pos0_clicked(event):
global _tr0, _tr, _dg
moveAbs_VGR_P123_name('SLD blue')
def on_txt_button_pos1_clicked(event):
global _tr0, _tr, _dg
moveAbs_VGR_P123_name('SLD red')
def on_txt_button_park_clicked(event):
global _tr0, _tr, _dg
logging.log(logging.TRACE_GUI, '-')
......@@ -41,9 +63,19 @@ def on_txt_button_test_clicked(event):
os._exit(os.EX_OK)
def on_txt_button_pos2_clicked(event):
global _tr0, _tr, _dg
moveAbs_VGR_P123_name('SLD white')
display.button_clicked("txt_button_acknowledge", on_txt_button_acknowledge_clicked)
display.button_clicked("txt_button_grip", on_txt_button_grip_clicked)
display.button_clicked("txt_button_release", on_txt_button_release_clicked)
display.button_clicked("txt_button_acknowledge", on_txt_button_acknowledge_clicked)
display.button_clicked("txt_button_pos0", on_txt_button_pos0_clicked)
display.button_clicked("txt_button_pos1", on_txt_button_pos1_clicked)
display.button_clicked("txt_button_park", on_txt_button_park_clicked)
display.button_clicked("txt_button_test", on_txt_button_test_clicked)
display.button_clicked("txt_button_pos2", on_txt_button_pos2_clicked)
......@@ -122,86 +122,7 @@
<field name="name">moveRef_VGR_P123</field>
<data>t}1X])Dx5:s!B8*l{B:@</data>
<next>
<block type="loop_endless" id="]aa!1yT}2w_^Au.[jQO^">
<statement name="DO">
<block type="import_function_noreturn" id="w/;@g^s8.^OBfmKxuoSs">
<mutation parentId="{S~eYro!kXU:h4Q]vq*V"/>
<field name="name">moveAbs_VGR_P123_name</field>
<data>{S~eYro!kXU:h4Q]vq*V</data>
<value name="name">
<block type="text" id="$YgwT5#?^Ex{h]3|Q#oR">
<field name="TEXT">SLD blue</field>
</block>
</value>
<next>
<block type="procedures_callnoreturn" id="l+$5piqc]|zCQ.zOblld">
<mutation name="grip"/>
<next>
<block type="import_function_noreturn" id="Osw@}Wp4hE{9|Nk:TE?6">
<mutation parentId=":S|)`z-6^RbjC]U;XL7["/>
<field name="name">moveRel_VGR_P123</field>
<data>:S|)`z-6^RbjC]U;XL7[</data>
<value name="rv1">
<block type="math_number" id="UuUdLl4c!Aa`DP}Czi`-">
<field name="NUM">0</field>
</block>
</value>
<value name="rv2">
<block type="math_number" id="7rYztYg=v-}-RD=544p;">
<field name="NUM">-400</field>
</block>
</value>
<value name="rv3">
<block type="math_number" id="8au6lii1[+cpQUC4m2Lv">
<field name="NUM">0</field>
</block>
</value>
<next>
<block type="import_function_noreturn" id="c-E$I4t|~na*t$^09pSf">
<mutation parentId="{S~eYro!kXU:h4Q]vq*V"/>
<field name="name">moveAbs_VGR_P123_name</field>
<data>{S~eYro!kXU:h4Q]vq*V</data>
<value name="name">
<block type="text" id="{/Rzhy@}A*MCork/U|@{">
<field name="TEXT">SLD red</field>
</block>
</value>
<next>
<block type="procedures_callnoreturn" id="h`!)+d.SC4tIiBb*f1Qc">
<mutation name="release"/>
<next>
<block type="import_function_noreturn" id="g6xR(LAyTb%I#R-LvH:/">
<mutation parentId=":S|)`z-6^RbjC]U;XL7["/>
<field name="name">moveRel_VGR_P123</field>
<data>:S|)`z-6^RbjC]U;XL7[</data>
<value name="rv1">
<block type="math_number" id="6GA0;0_sQI[e+_`t@(hT">
<field name="NUM">0</field>
</block>
</value>
<value name="rv2">
<block type="math_number" id="a_tNlln`~s9H?);)6%4:">
<field name="NUM">-400</field>
</block>
</value>
<value name="rv3">
<block type="math_number" id="p!mUWtv}(bL)G~vfts$8">
<field name="NUM">0</field>
</block>
</value>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</statement>
</block>
<block type="loop_endless" id="]aa!1yT}2w_^Au.[jQO^"/>
</next>
</block>
</next>
......@@ -216,7 +137,83 @@
</block>
</statement>
</block>
<block type="procedures_defnoreturn" id="6D3*:I/YYTZ=4mF*p.sU" x="0" y="1368">
<block type="import_function_noreturn" id="w/;@g^s8.^OBfmKxuoSs" disabled="true" x="0" y="982">
<mutation parentId="{S~eYro!kXU:h4Q]vq*V"/>
<field name="name">moveAbs_VGR_P123_name</field>
<data>{S~eYro!kXU:h4Q]vq*V</data>
<value name="name">
<block type="text" id="$YgwT5#?^Ex{h]3|Q#oR">
<field name="TEXT">SLD blue</field>
</block>
</value>
<next>
<block type="procedures_callnoreturn" id="l+$5piqc]|zCQ.zOblld" disabled="true">
<mutation name="grip"/>
<next>
<block type="import_function_noreturn" id="Osw@}Wp4hE{9|Nk:TE?6" disabled="true">
<mutation parentId=":S|)`z-6^RbjC]U;XL7["/>
<field name="name">moveRel_VGR_P123</field>
<data>:S|)`z-6^RbjC]U;XL7[</data>
<value name="rv1">
<block type="math_number" id="UuUdLl4c!Aa`DP}Czi`-">
<field name="NUM">0</field>
</block>
</value>
<value name="rv2">
<block type="math_number" id="7rYztYg=v-}-RD=544p;">
<field name="NUM">-400</field>
</block>
</value>
<value name="rv3">
<block type="math_number" id="8au6lii1[+cpQUC4m2Lv">
<field name="NUM">0</field>
</block>
</value>
<next>
<block type="import_function_noreturn" id="c-E$I4t|~na*t$^09pSf" disabled="true">
<mutation parentId="{S~eYro!kXU:h4Q]vq*V"/>
<field name="name">moveAbs_VGR_P123_name</field>
<data>{S~eYro!kXU:h4Q]vq*V</data>
<value name="name">
<block type="text" id="{/Rzhy@}A*MCork/U|@{">
<field name="TEXT">SLD red</field>
</block>
</value>
<next>
<block type="procedures_callnoreturn" id="h`!)+d.SC4tIiBb*f1Qc" disabled="true">
<mutation name="release"/>
<next>
<block type="import_function_noreturn" id="g6xR(LAyTb%I#R-LvH:/" disabled="true">
<mutation parentId=":S|)`z-6^RbjC]U;XL7["/>
<field name="name">moveRel_VGR_P123</field>
<data>:S|)`z-6^RbjC]U;XL7[</data>
<value name="rv1">
<block type="math_number" id="6GA0;0_sQI[e+_`t@(hT">
<field name="NUM">0</field>
</block>
</value>
<value name="rv2">
<block type="math_number" id="a_tNlln`~s9H?);)6%4:">
<field name="NUM">-400</field>
</block>
</value>
<value name="rv3">
<block type="math_number" id="p!mUWtv}(bL)G~vfts$8">
<field name="NUM">0</field>
</block>
</value>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
</next>
</block>
<block type="procedures_defnoreturn" id="6D3*:I/YYTZ=4mF*p.sU" x="0" y="1416">
<field name="NAME">thread_update_VGR</field>
<statement name="STACK">
<block type="util_python" id="OZgZtJ3=E}$78YYjHg@q" inline="true">
......@@ -306,7 +303,7 @@
</block>
</statement>
</block>
<block type="procedures_defnoreturn" id="$r**9YgeEpO#*aimSbPF" x="0" y="1756">
<block type="procedures_defnoreturn" id="$r**9YgeEpO#*aimSbPF" x="0" y="1794">
<mutation>
<arg name="_code" varid="x?rbx}Z!7+Jx9E.L=:pX" argid=",ZCb|vi(m3g0A4u*(!{`"/>
<arg name="_active" varid="Hq*BSR/(QEo9c0kQRW{y" argid="mqa@Al(.5xeP*B]Jl`8%"/>
......@@ -421,7 +418,7 @@
</block>
</statement>
</block>
<block type="procedures_defnoreturn" id="T-3m]M%pD$G?7-nv5K0U" x="0" y="2207">
<block type="procedures_defnoreturn" id="T-3m]M%pD$G?7-nv5K0U" x="0" y="2245">
<field name="NAME">grip</field>
<statement name="STACK">
<block type="util_python" id="/5w~kLU:)=8k[rZCZ$cH" inline="true">
......@@ -461,7 +458,7 @@
</block>
</statement>
</block>
<block type="procedures_defnoreturn" id="%qNAO.=,W#vTG#NYT}L[" x="0" y="2440">
<block type="procedures_defnoreturn" id="%qNAO.=,W#vTG#NYT}L[" x="0" y="2478">
<field name="NAME">release</field>
<statement name="STACK">
<block type="util_python" id="6bj3+4Uqf@_Ty5Br]z2C" inline="true">
......@@ -491,7 +488,7 @@
</block>
</statement>
</block>
<block type="procedures_defreturn" id="~+8+LAt/3[6jrT@?Fotg" x="0" y="2644">
<block type="procedures_defreturn" id="~+8+LAt/3[6jrT@?Fotg" x="0" y="2682">
<field name="NAME">get_state_code_VGR</field>
<statement name="STACK">
<block type="util_python" id="]10sGwTfi{[JA]2p:d|o" inline="true">
......@@ -504,7 +501,7 @@
</block>
</value>
</block>
<block type="procedures_defreturn" id="wfa$H.o;uZ$nYC*Fc=u8" x="0" y="2780">
<block type="procedures_defreturn" id="wfa$H.o;uZ$nYC*Fc=u8" x="0" y="2818">
<field name="NAME">get_state_active_VGR</field>
<statement name="STACK">
<block type="util_python" id=":G{(,-LQXg$o9lR6zPG3" inline="true">
......
......@@ -45,12 +45,7 @@ def thread_VGR():
threading.Thread(target=thread_update_VGR, daemon=True).start()
moveRef_VGR_P123()
while True:
moveAbs_VGR_P123_name('SLD blue')
grip()
moveRel_VGR_P123(0, -400, 0)
moveAbs_VGR_P123_name('SLD red')
release()
moveRel_VGR_P123(0, -400, 0)
pass
def thread_update_VGR():
......
......@@ -91,4 +91,44 @@ TXTWindow {
width: 100
height: 40
}
TXTButton {
id: txt_button_pos0
text: "pos0"
font.pixelSize: 16
enabled: true
x: 6
y: 34
width: 50
height: 50
}
TXTButton {
id: txt_button_pos1
text: "pos1"
font.pixelSize: 16
enabled: true
x: 63
y: 34
width: 50
height: 50
}
TXTButton {
id: txt_button_pos2
text: "pos2"
font.pixelSize: 16
enabled: true
x: 123
y: 34
width: 50
height: 50
}
TXTButton {
id: txt_button_pos3
text: "pos3"
font.pixelSize: 16
enabled: true
x: 182
y: 34
width: 50
height: 50
}
}
<xml type="display" version="2"><item id="4" class="TXTLabel"><name>txt_label_message</name><text/><geometry><x>5</x><y>207</y><width>230</width><height>20</height></geometry></item><item id="27" class="TXTButton"><name>txt_button_acknowledge</name><enabled>true</enabled><text>&lt;b&gt;ACK&lt;/b&gt;</text><geometry><x>5</x><y>174</y><width>60</width><height>30</height></geometry></item><item id="30" class="TXTButton"><name>txt_button_park</name><enabled>true</enabled><text>&lt;b&gt;PARK&lt;/b&gt;</text><geometry><x>87</x><y>174</y><width>60</width><height>30</height></geometry></item><item id="42" class="TXTLabel"><name>txt_label_version</name><text/><geometry><x>5</x><y>15</y><width>228</width><height>15</height></geometry></item><item id="47" class="TXTLabel"><name>txt_label_model</name><text>Training Factory Industry 4.0 9V V.2</text><geometry><x>5</x><y>0</y><width>228</width><height>15</height></geometry></item><item id="52" class="TXTButton"><name>txt_button_test</name><enabled>true</enabled><text>&lt;b&gt;TEST&lt;/b&gt;</text><geometry><x>173</x><y>174</y><width>60</width><height>31</height></geometry></item><item id="56" class="TXTButton"><name>txt_button_grip</name><enabled>true</enabled><text>grip</text><geometry><x>6</x><y>129</y><width>100</width><height>40</height></geometry></item><item id="57" class="TXTButton"><name>txt_button_release</name><enabled>true</enabled><text>release</text><geometry><x>133</x><y>129</y><width>100</width><height>40</height></geometry></item></xml>
\ No newline at end of file
<xml type="display" version="2"><item id="4" class="TXTLabel"><name>txt_label_message</name><text/><geometry><x>5</x><y>207</y><width>230</width><height>20</height></geometry></item><item id="27" class="TXTButton"><name>txt_button_acknowledge</name><enabled>true</enabled><text>&lt;b&gt;ACK&lt;/b&gt;</text><geometry><x>5</x><y>174</y><width>60</width><height>30</height></geometry></item><item id="30" class="TXTButton"><name>txt_button_park</name><enabled>true</enabled><text>&lt;b&gt;PARK&lt;/b&gt;</text><geometry><x>87</x><y>174</y><width>60</width><height>30</height></geometry></item><item id="42" class="TXTLabel"><name>txt_label_version</name><text/><geometry><x>5</x><y>15</y><width>228</width><height>15</height></geometry></item><item id="47" class="TXTLabel"><name>txt_label_model</name><text>Training Factory Industry 4.0 9V V.2</text><geometry><x>5</x><y>0</y><width>228</width><height>15</height></geometry></item><item id="52" class="TXTButton"><name>txt_button_test</name><enabled>true</enabled><text>&lt;b&gt;TEST&lt;/b&gt;</text><geometry><x>173</x><y>174</y><width>60</width><height>31</height></geometry></item><item id="56" class="TXTButton"><name>txt_button_grip</name><enabled>true</enabled><text>grip</text><geometry><x>6</x><y>129</y><width>100</width><height>40</height></geometry></item><item id="57" class="TXTButton"><name>txt_button_release</name><enabled>true</enabled><text>release</text><geometry><x>133</x><y>129</y><width>100</width><height>40</height></geometry></item><item id="58" class="TXTButton"><name>txt_button_pos0</name><enabled>true</enabled><text>pos0</text><geometry><x>6</x><y>34</y><width>50</width><height>50</height></geometry></item><item id="59" class="TXTButton"><name>txt_button_pos1</name><enabled>true</enabled><text>pos1</text><geometry><x>63</x><y>34</y><width>50</width><height>50</height></geometry></item><item id="60" class="TXTButton"><name>txt_button_pos2</name><enabled>true</enabled><text>pos2</text><geometry><x>123</x><y>34</y><width>50</width><height>50</height></geometry></item><item id="61" class="TXTButton"><name>txt_button_pos3</name><enabled>true</enabled><text>pos3</text><geometry><x>182</x><y>34</y><width>50</width><height>50</height></geometry></item></xml>
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment