aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Stubs Collection
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Stubs Collection')
-rw-r--r--Software/Stubs Collection/stubs/newWHS/Rehostat.cs31
1 files changed, 31 insertions, 0 deletions
diff --git a/Software/Stubs Collection/stubs/newWHS/Rehostat.cs b/Software/Stubs Collection/stubs/newWHS/Rehostat.cs
new file mode 100644
index 000000000..142c1597d
--- /dev/null
+++ b/Software/Stubs Collection/stubs/newWHS/Rehostat.cs
@@ -0,0 +1,31 @@
+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)
+{
+// Request ----
+// Int32 : Amount
+// Int32 : Delay
+
+// Response ----
+// Double : Progress
+
+
+stubManager.Run<ProgressResponse>("ProgressRequest" ,0x3EB, 0x300); //set rehostat value=0x300
+stubManager.WriteLine("First response received");
+Thread.Sleep(1000); //Sleep for 1000 milli.
+var response6 = stubManager.Run<ProgressResponse>("ProgressRequest" ,0x3EA, 5); // get GAS_OUT
+stubManager.WriteLine("Second response received");
+
+ stubManager.WriteLineHex(response6.Progress, 4);
+
+} \ No newline at end of file