RobotStudio event

How "WZDOSet" work?

<font face="Arial, Verdana"><span style="font-size: 10pt; line-height: normal;">I have read the help document about world zones and I think that I have done it well but it don't work as expected...Here is the code :</span></font><div style="font-family: Arial, Verdana; font-size: 10pt; font-style: normal; font-variant: normal; font-weight: normal; line-height: normal;"><br></div><div><div><font face="Arial, Verdana" style="background-color: rgb(255, 255, 255); color: rgb(255, 0, 0);"><span style="font-size: 13.3333330154419px; line-height: normal;">MODULE Module1</span><br></font></div><div><font face="Arial, Verdana"><span style="line-height: normal; font-size: 13.3333330154419px; background-color: rgb(255, 255, 255); color: rgb(255, 0, 0);">VAR wztemporary Inside_DCM;</span></font></div><div><font face="Arial, Verdana"><span style="line-height: normal; font-size: 13.3333330154419px; background-color: rgb(255, 255, 255); color: rgb(255, 0, 0);">VAR shapedata DCM;</span></font></div><div><font face="Arial, Verdana"><span style="line-height: normal; font-size: 13.3333330154419px; background-color: rgb(255, 255, 255); color: rgb(255, 0, 0);"><span class="Apple-tab-span" style="white-space:pre"> </span>CONST pos corner1:=[-533.4,-190.5,1159.76];</span></font></div><div><font face="Arial, Verdana"><span style="line-height: normal; font-size: 13.3333330154419px; background-color: rgb(255, 255, 255); color: rgb(255, 0, 0);"><span class="Apple-tab-span" style="white-space: pre;"> </span>CONST pos corner2:=[533.4,-758.09,1947.16];</span></font></div></div><div><span style="color: rgb(255, 0, 0); font-family: Arial, Verdana; font-size: 13.3333330154419px; line-height: normal; background-color: rgb(255, 255, 0);"><br></span></div><div><span style="color: rgb(255, 0, 0); font-family: Arial, Verdana; font-size: 13.3333330154419px; line-height: normal; background-color: rgb(255, 255, 255);">PROC MAIN()</span><br></div><div><span style="line-height: normal; font-size: 13.3333330154419px; font-family: Arial, Verdana; background-color: rgb(255, 255, 0); color: rgb(255, 0, 0);"><div><span class="Apple-tab-span" style="white-space:pre"> </span>WZ_DEF;</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>[...]</div><div>ENDPROC</div><div><span class="Apple-tab-span" style="white-space:pre"> </span></div><div>PROC WZ_DEF()</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>WZBoxDef \Inside, DCM, corner1, corner2;</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>WZDOSet \Temp, Inside_DCM \Inside, DCM, Extract_in_process, 1;</div><div>ENDPROC</div></span></div><div><font face="Arial, Verdana"><span style="font-size: 13.3333330154419px; line-height: normal;"><br></span></font></div><div><font face="Arial, Verdana"><span style="font-size: 13.3333330154419px; line-height: normal;">The problem is that the signal is not set, but only pulse when entering the zone...why? It is not supposed to be set when entering the zone and reset when exiting the zone??</span></font></div>

Comments

  • Sorry for the last post, I don't know how to write something here other than writing directly source text without any treatment...So, I have read the help document about world zones and I think that I have done it well but it don't work as expected...Here is the code : MODULE Module1 VAR wztemporary Inside_DCM; VAR shapedata DCM; CONST pos corner1:=[-533.4,-190.5,1159.76]; CONST pos corner2:=[533.4,-758.09,1947.16]; PROC MAIN() WZ_DEF; [...] ENDPROC PROC WZ_DEF() WZBoxDef \Inside, DCM, corner1, corner2; WZDOSet \Temp, Inside_DCM \Inside, DCM, Extract_in_process, 1; ENDPROC. The problem is that the signal is not set, but only pulse when entering the zone...why? It is not supposed to be set when entering the zone and reset when exiting the zone??