aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Stubs Collection
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2020-09-12 22:03:13 +0300
committerShlomo Hecht <shlomo@twine-s.com>2020-09-12 22:03:13 +0300
commit82fbd8fc872285637aaec64e1daa0da938d7d34e (patch)
tree863439aaa5e8f288a92ab6698b11e1c96790bc81 /Software/Stubs Collection
parent67954a38c95eb7e8cb8fde579e6b8583a17920cc (diff)
downloadTango-82fbd8fc872285637aaec64e1daa0da938d7d34e.tar.gz
Tango-82fbd8fc872285637aaec64e1daa0da938d7d34e.zip
add parameters to progress stub
Diffstat (limited to 'Software/Stubs Collection')
-rw-r--r--Software/Stubs Collection/stubs/arm test.cs43
1 files changed, 43 insertions, 0 deletions
diff --git a/Software/Stubs Collection/stubs/arm test.cs b/Software/Stubs Collection/stubs/arm test.cs
new file mode 100644
index 000000000..3c9b1d2ff
--- /dev/null
+++ b/Software/Stubs Collection/stubs/arm test.cs
@@ -0,0 +1,43 @@
+using System;
+using System.Text;
+using System.Linq;
+using System.Drawing;
+using System.Diagnostics;
+using System.Windows.Forms;
+using System.Threading;
+using System.Threading.Tasks;
+using System.Collections.Generic;
+using Tango.PMR.Stubs;
+using Tango.Stubs;
+
+public void OnExecute(StubManager stubManager)
+{
+int i;
+ProgressRequest progressRequest = new ProgressRequest();
+
+ for (i = 1;i<= 10; i++)
+ {
+ progressRequest.Amount = 0xB11;
+ progressRequest.Delay = 0;
+ var response = stubManager.Run<ProgressResponse>(progressRequest);
+ Thread.Sleep(12000);
+ progressRequest.Amount = 0xB12;
+ response = stubManager.Run<ProgressResponse>(progressRequest);
+ Thread.Sleep(1000);
+ stubManager.Write("Arm Test \t"+ i + " direction 0 progress "+ response.Progress +"\n");
+
+ }
+
+ for (i = 1;i<= 10; i++)
+ {
+ progressRequest.Amount = 0xB11;
+ progressRequest.Delay = 1;
+ var response = stubManager.Run<ProgressResponse>(progressRequest);
+ Thread.Sleep(12000);
+ progressRequest.Amount = 0xB12;
+ response = stubManager.Run<ProgressResponse>(progressRequest);
+ stubManager.Write("Arm Test \t"+ i + " direction 1 progress "+ response.Progress +"\n");
+
+ Thread.Sleep(1000);
+ }
+} \ No newline at end of file