diff --git a/TigerStopSDKExample/TigerStopSDKTest/Program.cs b/TigerStopSDKExample/TigerStopSDKTest/Program.cs index a9a4819..de925db 100644 --- a/TigerStopSDKExample/TigerStopSDKTest/Program.cs +++ b/TigerStopSDKExample/TigerStopSDKTest/Program.cs @@ -1,12 +1,13 @@ using System; using System.Collections.Generic; using System.Threading; +using TigerStopAPI; namespace TigerStopSDKExample { class Program { - static TigerStop_IO io; + static TigerStopAPI.TigerStop_IO io; static void Main(string[] args) { @@ -33,7 +34,7 @@ static void Main(string[] args) Console.WriteLine("Connecting to " + comport + "...."); - io = new TigerStop_IO(baud, comport); + io = new TigerStopAPI.TigerStop_IO(comport, baud); if (io.IsOpen) { @@ -50,7 +51,7 @@ static void Main(string[] args) Console.WriteLine("Searching...."); List> con = new List>(); - con = TigerStop_IO.Connections(); + con = TigerStopAPI.TigerStop_IO.Connections(); if (con.Count > 0) { @@ -170,6 +171,9 @@ public static bool InputHandler() "Home : Homes the machine, returning to the home position.\n" + " - Home | home | HOME | hm | HM \n" + "\n" + + "Min-max : Finds end sensors to determine working length.\n" + + " - FEL | fel | MIN-MAX | min-max | MINMAX | minmax | mm | MM \n" + + "\n" + "Sleep : Sets the drive to sleep.\n" + " - Sleep | sleep | SLEEP | sl | SL \n" + "\n" + @@ -333,6 +337,25 @@ public static bool InputHandler() exit = false; + break; + case "FEL": + case "fel": + case "Fel": + case "Minmax": + case "Min-Max": + case "Min-max": + case "minmax": + case "min-max": + case "MINMAX": + case "MIN-MAX": + case "mm": + case "MM": + io.FindEndLimits(); + + Console.WriteLine("Min-max complete"); + + exit = false; + break; case "Sleep": case "SLEEP": diff --git a/TigerStopSDKExample/TigerStopSDKTest/TigerStopSDKExample.csproj b/TigerStopSDKExample/TigerStopSDKTest/TigerStopSDKExample.csproj index c1234b0..8ae92e2 100644 --- a/TigerStopSDKExample/TigerStopSDKTest/TigerStopSDKExample.csproj +++ b/TigerStopSDKExample/TigerStopSDKTest/TigerStopSDKExample.csproj @@ -45,15 +45,13 @@ False - ..\..\..\..\TigerStopAPI\TigerStopAPI\bin\Release\TigerStopAPI.dll + ..\..\..\TigerStopSDK\TigerStopAPI\TigerStopAPI\bin\Release\TigerStopAPI.dll - - diff --git a/TigerStopSDKExample/TigerStopSDKTest/TigerStop_Com.cs b/TigerStopSDKExample/TigerStopSDKTest/TigerStop_Com.cs deleted file mode 100644 index f5c292b..0000000 --- a/TigerStopSDKExample/TigerStopSDKTest/TigerStop_Com.cs +++ /dev/null @@ -1,1184 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.IO.Ports; -using System.Linq; -using System.Threading; - -namespace TigerStopSDKExample -{ - public class TigerStop_Com - { - // = = = AUTORESET EVENTS = = = - AutoResetEvent serialAck = new AutoResetEvent(false); - AutoResetEvent updateAck = new AutoResetEvent(false); - - // = = = BACKGROUND WORKERS = = = - BackgroundWorker bkgndCycle = new BackgroundWorker(); - - // = = = BUFFERS = = = - private List readBuffer = new List(); - private List writeBuffer = new List(); - - // = = = CONSTANTS = = = - const double HALTED = 0; - const double ACCEL = 1; - const double CONST_VEL = 2; - const double DECEL = 3; - const double DRIVE_DISABLED = 4; - const double LASH = 5; - const double WAIT_TO_MOVE = 6; - const double EMERGENCY_STOP = 7; - const double SLEEP = 8; - const double MANUAL = 9; - - // = = = EVENT HANDLERS = = = - public event EventHandler SendData; - private event EventHandler AddSetting; - public event PropertyChangedEventHandler PropertyChanged; - private event EventHandler UpdateSetting; - public event EventHandler StopOperation; - - // = = = FIELDS = = = - private int settingIndex; - public string serialNumber; - public bool isRS232 = true; - public bool isLastConnected = false; - - // = = = FLAGS = = = - // - // - SETUP - private bool isConnected = false; - private bool isSetup = true; - private bool isGettingSettings; - private bool isDetectingTS = false; - private bool isUpdatingSetting = false; - // - MOVING - private bool isMoving = false; - private bool isMoveStart = false; - private bool isHoming = false; - // - CYCLING - private bool isCyclingTool = false; - private bool isCycleStart = false; - private bool isDmOff = false; - private bool isDmOn = false; - // - SCAN - private bool isScanning = false; - - // = = = LISTS = = = - private List ackTimes = new List(); - private List mtAckTimes = new List(); - private List settings = new List(); - private List scanMarks = new List(); - - // = = = READONLY COMMANDS = = = - private static readonly byte[] moveToolCommand = { 0x6d, 0x74, 0x0d, 0x0a }; - private static readonly byte[] moveHomeCommand = { 0x6d, 0x68, 0x0d, 0x0a }; - private static readonly byte[] moveStopCommand = { 0x6d, 0x73, 0x0d, 0x0a }; - private static readonly byte[] moveEStopCommand = { 0x6d, 0x65, 0x0d, 0x0a }; - private static readonly byte[] positionQueryCommand = { 0x70, 0x0d, 0x0a }; - private static readonly byte[] scanCommand = { 0x02, 0x52, 0x00, 0x01, 0x80, 0x00, 0x00, 0x00, 0x0d, 0x0a }; - private static readonly byte[] statusQueryCommand = { 0x73, 0x0d, 0x0a }; - private static readonly byte[] serialQueryCommand = { 0x04, 0x31, 0x0d, 0x0a }; - - // - SERIAL - private SerialPort port = new SerialPort(); - public string comPortName; - public int baudrate; - - // = = = STATIC COMMANDS = = = - private static byte[] loadSignalOn = { 0x77, 0x77, 0x20, 0x30, 0x78, 0x38, 0x30, 0x30, 0x20, 0x30, 0x78, 0x38, 0x30, 0x30, 0x0a, 0x0d }; - private static byte[] loadSignalOff = { 0x77, 0x77, 0x20, 0x30, 0x20, 0x30, 0x78, 0x38, 0x30, 0x30, 0x0a, 0x0d }; - - // = = = STRUCTS = = = - - private struct LastCommand - { - private byte[] command; - private DateTime timesent; - - public LastCommand(byte[] comm, DateTime time) - { - command = comm; - timesent = time; - } - - public byte[] Command - { - get - { - return command; - } - set - { - command = value; - } - } - - public DateTime TimeSent - { - get - { - return timesent; - } - set - { - timesent = value; - } - } - } - - private struct LastAck - { - private string acknowledgement; - private DateTime timerecieved; - - public LastAck(string ack, DateTime time) - { - acknowledgement = ack; - timerecieved = time; - } - - public string Acknowledgement - { - get - { - return acknowledgement; - } - set - { - acknowledgement = value; - } - } - - public DateTime TimeRecieved - { - get - { - return timerecieved; - } - set - { - timerecieved = value; - } - } - } - - // = = = TRACKING VARIABLES = = = - private static LastCommand lastCommand = new LastCommand(null, DateTime.Now); - private static LastAck lastAck = new LastAck(null, DateTime.Now); - private static double position; - private static double targetPosition; - - // = = = TIMEOUTS = = = - private TimeSpan timeout; - private TimeSpan mtTimeout = TimeSpan.FromSeconds(10); //We'll change it on initialization, but start with 10 seconds. - private TimeSpan scanTimeout = TimeSpan.FromSeconds(15); //We'll change it on initialization, but start with 15 seconds. - private TimeSpan homeTimeout = TimeSpan.FromSeconds(60); //We'll change it on initialization, but start with 60 seconds. - - // = = = GETTERS/SETTERS = = = - - public bool IsOpen - { - get - { - return port.IsOpen; - } - } - - - public bool IsConnected - { - get - { - return isConnected; - } - } - - - public DateTime LastAckTime - { - get - { - return lastAck.TimeRecieved; - } - } - - public SerialPort Port - { - get - { - return port; - } - private set - { - this.port = value; - } - } - - public double Position - { - get - { - return position; - } - private set - { - position = value; - NotifyPropertyChanged("Position"); - } - } - - - public List Settings - { - get - { - return settings; - } - } - - - public TimeSpan TimeOut - { - get - { - return this.timeout; - } - private set - { - this.timeout = value; - } - } - - // = = = CONSTRUCTORS = = = - - // - SERIAL CONSTRUCTOR - public TigerStop_Com(int baud, string comPort) - { - this.baudrate = baud; - this.comPortName = comPort; - - port.DataReceived += SerialPort_DataReceived; - AddSetting += SerialPort_AddSetting; - UpdateSetting += SerialPort_UpdateSetting; - - bkgndCycle.WorkerReportsProgress = false; - bkgndCycle.WorkerSupportsCancellation = true; - bkgndCycle.DoWork += new DoWorkEventHandler(bkgndCycle_DoWork); - bkgndCycle.RunWorkerCompleted += new RunWorkerCompletedEventHandler(bkgndCycle_Completed); - } - - // = = = BACKGROUND WORKERS = = = - // - // --- private void bkgndCycle_DoWork(object sender, DoWorkEventArgs e) --- - /// - /// This background worker is only fired once we've seen a 'MTS' from the machine, informing us that we've starting a move tool cycle. - /// While we trust that the machine is actually cycling, its best to double check that its actually doing that by looking first for the 'DMS' ack, - /// signaling that the dead man switch is off. Then looking for the 'DMF' ack, signaling that the dead man switch is back on. - /// - /// - /// - private void bkgndCycle_DoWork(object sender, DoWorkEventArgs e) - { - if (lastAck.Acknowledgement.Contains("DMS")) - { - isDmOff = true; - } - - if (lastAck.Acknowledgement.Contains("DMF") && isDmOff) - { - isDmOn = true; - } - } - - // --- private void bkgndCycle_Completed(object sender, RunWorkerCompletedEventArgs e) --- - /// - /// This RunWorkerCompleted event handler just checks to see if the machine has signaled to us that the dead man switch has gone off and come back on, - /// signaling the completion of an entire tool cycle. If we have not seen both signals, then we have to assume that we're still in the middle of a cycle. - /// - /// - /// - private void bkgndCycle_Completed(object sender, RunWorkerCompletedEventArgs e) - { - if (!(isDmOff && isDmOn)) - { - bkgndCycle.RunWorkerAsync(); - } - } - - // = = = EVENT HANDLERS = = = - // - // --- private void SerialPort_AddSetting(object sender, EventArgs e) --- - /// - /// This event handler is used specifically with the SerialPort_DataRecieved() event handler when the system is still in setup and obtaining all of the settings. - /// - /// - /// - private void SerialPort_AddSetting(object sender, EventArgs e) - { - var setting = e as MessageEvent; - double value; - - // If we see 'BAD' or 'INDEX' at all, we're beyond the index range and have found all of the settings. - if (setting.Message.Contains("BAD") || setting.Message.Contains("INDEX")) - { - isGettingSettings = false; - - ClearPort(); - } - else - { - if (double.TryParse(setting.Message, out value)) - { - settings.Add(value); - } - } - } - - // --- private void SerialPort_UpdateSetting(object sender, EventArgs e) --- - /// - /// This event handler is used specifically with the SerialPort_DataReceived() event handler when the system is updating a specific setting. - /// Upon retrieving the specific setting at 'settingIndex', if the returned value can be deciphered, its the new setting value, otherwise just keep the old value. - /// - /// - /// - private void SerialPort_UpdateSetting(object sender, EventArgs e) - { - var setting = e as MessageEvent; - double value; - - // If 'settings' is keeping track of a setting at the current 'settingIndex', then try to change it. - if (settings.Count >= settingIndex - 1 && settings.Count > 0) - { - settings[settingIndex - 1] = double.TryParse(setting.Message, out value) ? value : settings[settingIndex - 1]; - } - - updateAck.Set(); - } - - // --- private void SerialPort_DataReceived(object sender, SerialDataReceivedEventArgs e) --- - /// - /// This is the main event handler, everything from the machine will be funneled through this event handler. Anytime the serial port buffer receives data, this - /// the SerialPort.DataReceived event will fire and this event handler will be called to take in the data. This event handler is given its own thread to handle the - /// data. - /// - /// - /// - private void SerialPort_DataReceived(object sender, SerialDataReceivedEventArgs e) - { - SerialPort sp = (SerialPort)sender; - - try - { - string data = sp.ReadLine(); - - //If we've taken care of all of the preliminary tasks, handle the data as necessary. - if (!isSetup) - { - HandleData(data); - } - //Otherwise, we're still in setup. - else - { - if (isDetectingTS) - { - int serialNum = 0; - - try - { - if (int.TryParse(new string(data.Where(char.IsDigit).ToArray()), out serialNum)) - { - isDetectingTS = false; - - serialNumber = serialNum.ToString(); - - serialAck.Set(); - } - } - catch - { - // We're just going to let the program sit out the timeout since we couldn't nail down a serial number. - } - } - else if (isGettingSettings) - { - AddSetting(this, new MessageEvent(data)); - } - else if (isUpdatingSetting) - { - UpdateSetting(this, new MessageEvent(data)); - } - } - } - catch - { - - } - } - - // --- private void NotifyPropertyChanged(string property) --- - /// - /// Basic property changed event handler. - /// - /// The 'string' name of the property that was changed, to be sent out for others to identify and decide what to do with it. - private void NotifyPropertyChanged(string property) - { - PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(property)); - } - - // = = = METHODS = = = - // - - // --- private void HandleData(string data) --- - /// - /// Takes in a string of data from SerialPort_DataReceived() and parses it with any data in 'readBuffer' to determine if the machine has sent back an - /// ack for us to decipher at any point. - /// - /// A 'string' containing data from the serial port to send off to HandleAck() depending the systems current status. - private void HandleData(string data) - { - readBuffer.Add(data); - - if (!isScanning) - { - HandleAck(); - } - else - { - long value = 0; - - // If we found the end of scan sequence, this is our ack for scan and need to stop. - if (long.TryParse(string.Join("", readBuffer.ToArray()).Substring(4, string.Join("", readBuffer.ToArray()).Length - 5), out value)) - { - scanMarks.Add(Convert.ToDouble(value) / 1000); - - readBuffer.Clear(); - } - // The scan command is a altered move command, which means an 'MGS' will be seen and need to be cleared before the marks come in. - else if (string.Join("", readBuffer.ToArray()).Contains("MGS")) - { - readBuffer.Clear(); - } - // Otherwise, we found a mark and need to add it to our marks list. - else - { - // If we found the end of the scan, Then we can handle the ack. - if (string.Join("", readBuffer.ToArray()).Contains("\0\0\0")) - { - HandleAck(); - } - - if (data.Contains("Err") || data.Contains("Scan")) - { - scanMarks.Clear(); - readBuffer.Clear(); - SendData(this, new MessageEvent("There was an error during the scan.")); - } - } - } - } - - // --- private void HandleAck() --- - /// - /// Once HandleData() collates the data taken in from SerialPort_DataReceived() and checks it for appropriate acks based on what the system is doing - /// at the moment. - /// - private void HandleAck() - { - // If there isn't any kind of 'NACK' in the message, we have to treat it as a legitimate message. - if (!string.Join("", readBuffer.ToArray()).Contains("NACK")) - { - if (!isScanning) - { - // Started a move or too cycle. - if ((isMoveStart && string.Join("", readBuffer.ToArray()).Contains("MGS")) ^ (isCycleStart && string.Join("", readBuffer.ToArray()).Contains("MTS"))) - { - if (isMoveStart) - { - isMoveStart = false; - isMoving = true; - - double.TryParse(string.Join("", readBuffer.ToArray()).TrimStart(new char[] { 'M', 'G', 'S', ' ' }).TrimEnd(new char[] { '\r', '\n' }), out targetPosition); - } - else - { - isCycleStart = false; - isCyclingTool = true; - } - - lastAck.Acknowledgement = string.Join("", readBuffer.ToArray()); - lastAck.TimeRecieved = DateTime.Now; - - readBuffer.Clear(); - } - // Finished a move or tool cycle. - else if (isMoving ^ isCyclingTool) - { - if (string.Join("", readBuffer.ToArray()).Contains("MGF")) - { - double finalPosition; - - lastAck.Acknowledgement = "MGF"; - lastAck.TimeRecieved = DateTime.Now; - - if (double.TryParse(string.Join("", readBuffer.ToArray()).TrimStart(new char[] { '\n', 'M', 'G', 'F', ' ' }).TrimEnd(new char[] { '\r', '\n' }), out finalPosition)) - { - Position = finalPosition; - } - - SendData(this, new MessageEvent("MGF")); - - isMoving = false; - } - else if (string.Join("", readBuffer.ToArray()).Contains("MTF")) - { - isDmOff = false; - isDmOn = false; - - lastAck.Acknowledgement = "MTF"; - lastAck.TimeRecieved = DateTime.Now; - - SendData(this, new MessageEvent("MTF")); - - isCyclingTool = false; - } - // If neither 'MGF' or 'MTF' is seen, a move or tool cycle is in progress. - else - { - lastAck.Acknowledgement = string.Join("", readBuffer.ToArray()); - lastAck.TimeRecieved = DateTime.Now; - - CheckSamePosition(); - } - - readBuffer.Clear(); - - ClearCommand(false); - - SendCommand(); - } - // Is homing the device. - else if (isHoming) - { - if (string.Join("", readBuffer.ToArray()).Trim() == "0") - { - lastAck.Acknowledgement = "MHF"; - lastAck.TimeRecieved = DateTime.Now; - - SendData(this, new MessageEvent("MHF")); - - isHoming = false; - - ClearCommand(false); - - SendCommand(); - } - - readBuffer.Clear(); - } - else if (!isMoving && !isCyclingTool) - { - lastAck.Acknowledgement = string.Join("", readBuffer.ToArray()); - lastAck.TimeRecieved = DateTime.Now; - - if (!lastCommand.Command.SequenceEqual(scanCommand)) - { - SendData(this, new MessageEvent(string.Join("", readBuffer.ToArray()))); - - if (lastCommand.Command.SequenceEqual(positionQueryCommand)) - { - CheckSamePosition(); - } - - ClearCommand(false); - } - else - { - CheckSamePosition(); - - ClearCommand(false); - } - - readBuffer.Clear(); - - SendCommand(); - } - } - else - { - lastAck.Acknowledgement = string.Join("", readBuffer.ToArray()); - lastAck.TimeRecieved = DateTime.Now; - - SendData(this, new MessageEvent(string.Join(",", scanMarks.ToArray()))); - - scanMarks.Clear(); - - isScanning = false; - - readBuffer.Clear(); - - ClearCommand(false); - - SendCommand(); - } - } - else - { - // Clear the NACK from the buffer. - readBuffer.Clear(); - - RetryCommand(); - } - } - - // --- protected void QueueCommand(string command) --- - /// - /// This function is the main interface between the rest of the system and the machine. Any commands that need to be sent to the machine runs through this command. - /// It takes a 'string' command to send to the machine. If the system already has commands queued up, it will add the command to the queue, otherwise it will call - /// SendCommand() to get the command processed immediately. - /// - /// A 'string' that will be converted to a 'byte[]' command that will be sent to the machine. - protected void QueueCommand(string command) - { - byte[] cmd = CommandConverter(command); - - if (cmd.SequenceEqual(moveStopCommand)) - { - WriteToSerial(moveStopCommand); - ClearCommand(true); - - ChangeFlags(false); - - ClearPort(); - } - else if (cmd.SequenceEqual(moveEStopCommand)) - { - WriteToSerial(moveEStopCommand); - ClearCommand(true); - - ChangeFlags(false); - - ClearPort(); - } - else if (writeBuffer.Count != 0) - { - writeBuffer.Add(cmd); - } - else - { - writeBuffer.Add(cmd); - SendCommand(); - } - } - - // --- private byte[] CommandConverter --- - /// - /// Used specifically to convert 'string's into hex byte commands to send to the machine. - /// - /// A 'string' that will be translated. - /// Returns a 'byte[]' to be used as a hex byte command by the machine. - private byte[] CommandConverter(string input) - { - List command = new List(); - - foreach (char c in input) - { - command.Add(Convert.ToByte(c)); - } - - // Add the \r\n delimiter for the amp. - command.Add(0x0d); - command.Add(0x0a); - - return command.ToArray(); - } - - // --- private void SendCommand() --- - /// - /// This function takes the first command from 'writeBuffer' and, depending on the command, sends it to the machine through the proper functions. - /// - private void SendCommand() - { - if (writeBuffer.Count != 0) - { - byte[] send = writeBuffer[0]; - - if (send[0] == 0x06d) - { - MoveCommand(send); - } - else if (send.SequenceEqual(scanCommand)) - { - TimeOut = Timeout.InfiniteTimeSpan; - isScanning = true; - - WriteToSerial(scanCommand); - } - else - { - WriteToSerial(send); - } - } - } - - // --- private void MoveCommand(byte[] command) --- - /// - /// Called if the first command seen by SendCommand() is a move command, determine what kind of move command is being sent and set the appropriate flags - /// and timeouts before sending the command to the machine. - /// - /// A 'byte[]' command that will be used to determine which move command is being sent. - private void MoveCommand(byte[] moveCommand) - { - switch (moveCommand[1]) - { - //Move go - case 0x67: - TimeOut = Timeout.InfiniteTimeSpan; - isMoveStart = true; - WriteToSerial(moveCommand); - break; - //Move home - case 0x68: - TimeOut = homeTimeout; - isHoming = true; - WriteToSerial(moveHomeCommand); - break; - //Move tool - case 0x74: - TimeOut = mtTimeout; - isCycleStart = true; - WriteToSerial(moveToolCommand); - break; - } - } - - // --- private void ClearCommand(bool allCommands) --- - /// - /// This function is used to clear out commands from the 'writeBuffer'. If 'allCommands' is 'true', it will clear all commands from the 'writeBuffer'. - /// Otherwise, it will only clear the first command from 'writeBuffer'. - /// - /// A 'bool' that determines whether to clear the first command in the list or to clear all of the commands from the list. - private void ClearCommand(bool allCommands) - { - if (allCommands) - { - SendData(this, new MessageEvent("There was an error.")); - writeBuffer.Clear(); - } - else - { - if (writeBuffer.Count != 0) - { - writeBuffer.Remove(writeBuffer[0]); - } - } - } - - // --- private void WriteSerial(byte[] command) --- - /// - /// This function writes the byte[] command to the machine over the serial port. Also tracks the last command that was sent, in case we need send it again. - /// - /// - private void WriteToSerial(byte[] command) - { - port.Write(command, 0, command.Length); - - lastCommand.Command = command; - lastCommand.TimeSent = DateTime.Now; - } - - // --- private void WriteToSerialClean(byte[] command) --- - /// - /// This function writes the byte[] command to the machine over the serial port. It does not track the last command. - /// - /// - private void WriteToSerialClean(byte[] command) - { - port.Write(command, 0, command.Length); - } - - // --- private void RetryCommand() --- - /// - /// This function sends the last command to the machine in the case the machine did not register or complete the last command. Caution is required - /// when using this function as ‘lastCommand.Command’ may cause the machine to act unexpectedly, such as cycling the tool or moving when the user is unprepared. - /// - private void RetryCommand() - { - Thread.Sleep(100); - - ClearPort(); - - // Make sure the proper flags are set. - if (lastCommand.Command[0].Equals(0x6d) && lastCommand.Command[1].Equals(0x67)) - { - isMoving = true; - } - else if (lastCommand.Command[0].Equals(0x6d) && lastCommand.Command[1].Equals(0x74)) - { - isCyclingTool = true; - } - - WriteToSerial(lastCommand.Command); - } - - // --- private void GetSettings() --- - /// - /// This function is used to ask the machine for all of its settings and puts them into a list for future use. - /// - protected void GetSettings() - { - settings.Clear(); - - isSetup = true; - isGettingSettings = true; - - for (int i = 1; isGettingSettings; i++) - { - WriteToSerialClean(CommandConverter("d" + i)); - - Thread.Sleep(50); - } - - isSetup = false; - - ClearPort(); - } - - // --- private bool SamePosition() --- - /// - /// This function is used to determine if the position that the machine is at is the same as the last position that was queried. If the position - /// is the same, the function returns 'true' if the position in the last acknowledgment is the same as the current position we know of. Otherwise, - /// the function returns false. - /// - /// Returns a bool denoting whether the machine is in the same place as the last time position was queried. - private bool CheckSamePosition() - { - double newPosition = 0; - bool samePosition = false; - - if (double.TryParse(lastAck.Acknowledgement.TrimStart(new char[] { 'M', 'G', 'F', 'S' }).TrimEnd(new char[] { '\r', '\n' }), out newPosition)) - { - if (Position == newPosition) - { - samePosition = false; ; - } - else - { - samePosition = true; - } - - Position = newPosition; - } - else - { - samePosition = true; - } - - return samePosition; - } - - // --- private void CheckMovement() --- - /// - /// This function is used while the machine is moving to double check that the machine is, in fact, moving like it was told to. - /// - private void CheckMovement() - { - if (isMoving) - { - double status = 2; - - WriteToSerial(statusQueryCommand); - - Thread.Sleep(100); - - if (!double.TryParse(lastAck.Acknowledgement.TrimEnd(new char[] { '\r', '\n' }), out status)) - { - status = 2; - } - - // If we're stopped, check if the machine is near the target position. - if (status == DRIVE_DISABLED || status == HALTED) - { - if (targetPosition - 0.004 <= Position && Position <= targetPosition + 0.004) - { - Position = targetPosition; - SendData(this, new MessageEvent("MGF")); - } - else - { - SendData(this, new MessageEvent("The system did not detect a proper move completion")); - } - } - } - else - { - ClearPort(); - } - } - - // --- private void ClearPort() --- - /// - /// This function is used to clear out the serial port, reading anything currently in the serial port. - /// - protected void ClearPort() - { - port.ReadExisting(); - } - - // --- public void ClosePort() --- - /// - /// Used to close the port when it is no longer in use. - /// - protected void ClosePort() - { - port.Close(); - } - - // --- private void OpenPort() --- - /// - /// This function takes the stored com port name and baud rate and attempts to open a serial connection to the desired com port. - /// - protected void OpenPort() - { - try - { - port.PortName = comPortName; - port.BaudRate = baudrate; - port.StopBits = StopBits.One; - port.DataBits = 8; - port.Handshake = Handshake.None; - port.DtrEnable = true; - port.RtsEnable = true; - - port.Open(); - } - catch - { - - } - } - - // --- public bool DetectTigerStop() --- - /// - /// This function sends the serial command query to the machine to get a hold of its serial number. If the serial number is - /// valid, then SerialPort_DataReceived() will signal the 'serialAck' to allow the function through and to return true. - /// - /// Returns a 'bool' that signals whether or not the system detected a TigerStop machine on the other end of the connection. - protected bool DetectTigerStop() - { - bool detected = false; - - isDetectingTS = true; - - WriteToSerialClean(serialQueryCommand); - - if (serialAck.WaitOne(1000)) - { - detected = true; - } - else - { - detected = false; - } - - return detected; - } - - // --- public bool CheckConnection() --- - /// - /// This function goes through all of the necessary checks that ensures the system is connected to a machine. If all of the checks pass - /// a 'bool' is returned 'true' denoting that the system has successfully connected to the machine. - /// - /// Returns a bool denoting whether we were able to connect to a machine with a valid enable code. - protected bool CheckConnection() - { - bool isConnected = false; - - try - { - if (IsOpen) - { - if (DetectTigerStop()) - { - this.isLastConnected = true; - isConnected = true; - isSetup = false; - } - else - { - ClosePort(); - this.isLastConnected = false; - isConnected = false; - } - } - } - catch - { - isConnected = false; - } - - return isConnected; - } - - // --- public void ChangeSetting(string command, int index) --- - /// - /// Takes a setting command and setting index to update the desired setting in 'settings' at 'index'. - /// - /// A 'string' that will be sent to the machine to change the setting in the command to the desired value. - /// An 'int' that denotes where in 'settings' the new setting value will be saved. - protected void ChangeSetting(string command, int index) - { - isSetup = true; - isUpdatingSetting = true; - - settingIndex = index; - - WriteToSerialClean(CommandConverter(command)); - - updateAck.Reset(); - - updateAck.WaitOne(1000); - - isSetup = false; - isUpdatingSetting = false; - } - - // --- public void ChangeSetting(string command) --- - /// - /// Sends a setting change command to the machine. - /// - /// A 'string' that will be sent to the machine to change the setting in the command to the desired value. - protected void ChangeSetting(string command) - { - isSetup = true; - isUpdatingSetting = true; - - WriteToSerial(CommandConverter(command)); - - updateAck.Reset(); - - if (updateAck.WaitOne(2000)) - { - SendData(this, new MessageEvent("SetUp")); - } - - isSetup = false; - isUpdatingSetting = false; - } - - // --- public void InitializeTimeouts() --- - /// - /// Takes the currently saved timeout settings and initializes the timeouts to more expected timeouts. - /// - protected void InitializeTimeouts() - { - // Use the DmOff, TaON, TaOff, and DnOn settings to get an idea of how long the machine will wait for a cycle. - mtTimeout = TimeSpan.FromSeconds(settings[55] + settings[56] + settings[57] + settings[58]); - - // Use the max length of the machine divided by home speed of five inches per second multiplied by two, for acceleration and deceleration times, to wait for home. - homeTimeout = TimeSpan.FromSeconds((settings[9] / 5) * 2); - } - - // --- public LoadLight(bool on) --- - /// - /// This function is used to write to the serial port to have the machine turn on the load signal light according to the 'bool' input. - /// - /// A 'bool' that denotes whether to turn on or turn off the load signal light on the machine. - protected void LoadLight(bool on) - { - switch (on) - { - case true: - WriteToSerialClean(loadSignalOn); - break; - case false: - WriteToSerialClean(loadSignalOff); - break; - } - } - - // --- public void ClearWriteBuffer(bool all) --- - /// - /// Some acks from the machine don't always make it back to the system, so 'writeBuffer' needs to be cleared so that other commands can be sent down. - /// - /// A 'bool' that denotes whether to clear out all of the commands in 'writeBuffer', or just the first. - protected void ClearWriteBuffer(bool all) - { - ClearCommand(all); - } - - // --- protected static List> FindConnections() --- - /// - /// Opens each of the available comports at a number of baudrates and checks each for a potential connection to a TigerStop amp. - /// - /// A 'List' of 'KeyValuePair's with comport names as 'string' keys and baudrate 'int' values of potential connections. - protected static List> FindConnections() - { - List> connections = new List>(); - int serial = 0; - int[] baudrates = new int[5] { 9600, 19200, 38400, 57600, 115200 }; - SerialPort searchPort = new SerialPort(); - - searchPort.StopBits = StopBits.One; - searchPort.DataBits = 8; - searchPort.Handshake = Handshake.None; - searchPort.DtrEnable = true; - searchPort.RtsEnable = true; - searchPort.ReadTimeout = 1000; - - foreach (string p in SerialPort.GetPortNames()) - { - searchPort.PortName = p; - - for (int i = 0; i < baudrates.Length; i++) - { - searchPort.BaudRate = baudrates[i]; - - try - { - searchPort.Open(); - - searchPort.Write(serialQueryCommand, 0, serialQueryCommand.Length); - - Thread.Sleep(100); - - // A response as a readable integer is enough to believe a TigerStop amp is on the other end of the connection. - if (int.TryParse(new string(searchPort.ReadLine().Where(char.IsDigit).ToArray()), out serial)) - { - connections.Add(new KeyValuePair(p, baudrates[i])); - searchPort.Close(); - } - else - { - searchPort.Close(); - } - } - // Expect to catch a lot of timeout exceptions. - catch - { - searchPort.Close(); - } - } - } - - return connections; - } - - // --- private void ChangeFlags(bool change) --- - /// - /// Changes all of the 'bool' flags to the value of 'change'. - /// - /// A 'bool' representing the value to change all of the flags to. - private void ChangeFlags(bool change) - { - isMoving = change; - isCyclingTool = change; - isScanning = change; - isMoveStart = change; - isCycleStart = change; - isDmOff = change; - isDmOn = change; - } - } -} \ No newline at end of file diff --git a/TigerStopSDKExample/TigerStopSDKTest/TigerStop_IO.cs b/TigerStopSDKExample/TigerStopSDKTest/TigerStop_IO.cs deleted file mode 100644 index 1a137f3..0000000 --- a/TigerStopSDKExample/TigerStopSDKTest/TigerStop_IO.cs +++ /dev/null @@ -1,1518 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Threading; - -namespace TigerStopSDKExample -{ - public class TigerStop_IO : TigerStop_Com - { - // = = = AUTORESET EVENTS = = = - private AutoResetEvent ackEvent = new AutoResetEvent(false); - private AutoResetEvent movingEvent = new AutoResetEvent(false); - private AutoResetEvent cyclingEvent = new AutoResetEvent(false); - private AutoResetEvent deadmanOffEvent = new AutoResetEvent(false); - private AutoResetEvent deadmanOnEvent = new AutoResetEvent(false); - private AutoResetEvent homingEvent = new AutoResetEvent(false); - - // = = = EVENTS = = = - public EventHandler IO_Error; - - // = = = FIELDS = = = - private string ackMessage; - private List settingNames = new List - { - "P Gain", "I Gain", "D Gain", "Vel In", "Vel Out", "Acc In", "Acc Out", "Dec In", "Dec Out", "Lim Max", // 1 - 10 - "Lim Min", "IOP Baud", "Scale", "Dither", "Debug", "Clamp 1", "Clamp 2", "Position", "PrtType", "PrtBaud", // 11 - 20 - "CommBaud", "JetOffset", "Kerf", "Head Cut", "Tail Cut", "Outfeed", "Backoff", "Retract", "Ret Offset", "Feed Haz", // 21 - 30 - "Load Off", "Max SPL", "Opti Score", "Opti Time", "Opti Pen", "Move Delay", "Lash", "SM Table", "UnLoad", "Motor Type", // 31 - 40 - "ME Zero", "Language", "Con Sleep", "MMEnable", "Contrast", "Prt Names", "Prt Cuts", "Ret Type", "IOReadMask", "IOWritMask", // 41 - 50 - "PresetType", "Waste First", "ConPW", "ClampOn_D", "SawOn_D", "DMOff_TO", "TAOn_TO", "TAOff_TO", "DMOn_TO", "ClampOff_D", // 51 - 60 - "SawCyc_D", "RSD_Rdy_TO", "Timer10", "ComPanel", "CrossCal", "CrossAlarm", "HandyOpt", "Waste", "DropBox", "Defect", // 61 - 70 - "L Range", "L Count", "Laser ME", "L Limit", "L Ref", "Cld Sty", "S cpi", "L cpi", "Pnt Dly", "TH LV M", // 71 - 80 - "TH LV B", "Can Dly", "Inf", "Pet Clear", "Pet Dim", "Banana1", "Banana2", "SC Rel", "TH HV M", "TH HV B", // 81 - 90 - "StallMEP", "StallMES", "Run MEP", "Run MES", "RateGain", "RateThes", "SetPntSys", "Timer", "FindVel", "FindErr", // 91 - 100 - "DrillMode", "MMRatio", "IR Type", "SI_RES3", "Mtr CPR", "Mtr Poles", "TTenable", "DrvAccLmt", "TM Offset", "TM Enable", // 101 - 110 - "Fast Cal", "Fast Unit", "QFilter", "DFilter", "EFilter", "Brk TYPE", "PF_Up_Pos", "Rev Jog", "VJ Font", "Crayon", // 111 - 120 - "UV_IR_Off", "PF_Offset", "D Margin" // 121 - 123 - }; - - // = = = GETTERS/SETTERS = = = - public string AckMessage - { - get - { - return ackMessage; - } - private set - { - this.ackMessage = value; - } - } - - public List SettingNames - { - get - { - return settingNames; - } - private set - { - this.settingNames = value; - } - } - - // = = = CONSTRUCTORS = = = - public TigerStop_IO(int baud, string comPort) : base(baud, comPort) - { - OpenPort(); - - if (CheckConnection()) - { - SendData += Com_MessageReceived; - } - } - - // = = = EVENTS = = = - - // --- private void Com_MessageReceived(object sender, EventArgs e) --- - /// - /// This event listens for messages from TigerStop_Com that can be used by TigerStop_IO. - /// - /// - /// - private void Com_MessageReceived(object sender, EventArgs e) - { - var ack = e as MessageEvent; - - // Copy the message for the waiting event to look at. - AckMessage = ack.Message; - - // The system needs to look out for various kinds of acks; a moving ack, "MGF", a cycling ack, "MTF", two dead man acks "DMS" and "DMF", or a general ack. - if (ack.Message.Contains("MGF")) - { - movingEvent.Set(); - } - else if (ack.Message.Contains("MTF")) - { - cyclingEvent.Set(); - } - else if (ack.Message.Contains("DMS")) - { - deadmanOffEvent.Set(); - } - else if (ack.Message.Contains("DMF")) - { - deadmanOnEvent.Set(); - } - else if (ack.Message.Contains("MHF")) - { - homingEvent.Set(); - } - // Otherwise, it was a general ack and release the waiting event. - else - { - ackEvent.Set(); - } - } - - // = = = METHODS = = = - - // --- public bool MoveTo(double position) --- - /// - /// Sends a move command to the machine to move to the desired position waiting for the move to finish. - /// - /// A 'double' denoting the desired position to move to. - /// A 'bool' that signals whether the move command was successfully completed. - public bool MoveTo(double position) - { - bool isDone = false; - - base.QueueCommand("mg" + position); - - movingEvent.Reset(); - movingEvent.WaitOne(); - - isDone = true; - - return isDone; - } - - // --- public bool MoveTo(double position, int timeout) --- - /// - /// Sends a move command to the machine to move to the desired position, waiting for the move to finish or for the given timeout duration before returning. - /// - /// A 'double' denoting the desired position to move to. - /// An 'int' denotes the number of milliseconds to timeout on. - /// A 'bool' that signals whether the move command was successfully completed. - public bool MoveTo(double position, int timeout) - { - bool isDone = false; - - base.QueueCommand("mg" + position); - - movingEvent.Reset(); - if (!movingEvent.WaitOne(timeout)) - { - isDone = false; - } - else - { - isDone = true; - } - - return isDone; - } - - // --- public bool MoveTo(double position, ref BackgroundWorker b) --- - /// - /// Sends a move command to the machine to move to the desired position waiting for the move to finish. - /// - /// A 'double' denoting the desired position to move to. - /// A 'BackgroundWorker' that is running MoveTo() that may signal an impending cancellation. - /// A 'bool' that signals whether the move command was successfully completed. - public bool MoveTo(double position, ref BackgroundWorker b) - { - bool isDone = false; - - base.QueueCommand("mg" + position); - - if (b.CancellationPending) - { - return false; - } - - movingEvent.Reset(); - movingEvent.WaitOne(); - - if (b.CancellationPending) - { - return false; - } - - isDone = true; - - return isDone; - } - - // --- public bool MoveTo(double position, int timeout, ref BackgroundWorker b) --- - /// - /// Sends a move command to the machine to move to the desired position, waiting for the move to finish or for the given timeout duration before returning. - /// - /// A 'double' denoting the desired position to move to. - /// An 'int' denotes the number of milliseconds to timeout on. - /// A 'BackgroundWorker' that is running MoveTo() that may signal an impending cancellation. - /// A 'bool' that signals whether the move command was successfully completed. - public bool MoveTo(double position, int timeout, ref BackgroundWorker b) - { - bool isDone = false; - - base.QueueCommand("mg" + position); - - if (b.CancellationPending) - { - return false; - } - - movingEvent.Reset(); - if (!movingEvent.WaitOne(timeout)) - { - isDone = false; - } - else - { - isDone = true; - } - - if (b.CancellationPending) - { - return false; - } - - return isDone; - } - - // --- public bool MoveTo(double position) --- - /// - /// Sends a move command to the machine to move to the desired position waiting for the move to finish. - /// - /// A 'string' denoting the desired position to move to. - /// A 'bool' that signals whether the move command was successfully completed. - public bool MoveTo(string position) - { - bool isDone = false; - - base.QueueCommand("mg" + position); - - movingEvent.Reset(); - movingEvent.WaitOne(); - - isDone = true; - - return isDone; - } - - // --- public bool MoveTo(double position, int timeout) --- - /// - /// Sends a move command to the machine to move to the desired position, waiting for the move to finish or for the given timeout duration before returning. - /// - /// A 'string' denoting the desired position to move to. - /// An 'int' that denotes the number of milliseconds to timeout on. - /// A 'bool' that signals whether the move command was successfully completed. - public bool MoveTo(string position, int timeout) - { - bool isDone = false; - - base.QueueCommand("mg" + position); - - movingEvent.Reset(); - if (!movingEvent.WaitOne(timeout)) - { - isDone = false; - } - else - { - isDone = true; - } - - return isDone; - } - - // --- public bool MoveTo(string position, ref BackgroundWorker b) --- - /// - /// Sends a move command to the machine to move to the desired position waiting for the move to finish. - /// - /// A 'string' denoting the desired position to move to. - /// A 'BackgroundWorker' that is running MoveTo() that may signal an impending cancellation. - /// A 'bool' that signals whether the move command was successfully completed. - public bool MoveTo(string position, ref BackgroundWorker b) - { - bool isDone = false; - - base.QueueCommand("mg" + position); - - if (b.CancellationPending) - { - return false; - } - - movingEvent.Reset(); - movingEvent.WaitOne(); - - if (b.CancellationPending) - { - return false; - } - - isDone = true; - - return isDone; - } - - // --- public bool MoveTo(string position, int timeout, ref BackgroundWorker b) --- - /// - /// Sends a move command to the machine to move to the desired position, waiting for the move to finish or for the given timeout duration before returning. - /// - /// A 'string' denoting the desired position to move to. - /// An 'int' denotes the number of milliseconds to timeout on. - /// A 'BackgroundWorker' that is running MoveTo() that may signal an impending cancellation. - /// A 'bool' that signals whether the move command was successfully completed. - public bool MoveTo(string position, int timeout, ref BackgroundWorker b) - { - bool isDone = false; - - base.QueueCommand("mg" + position); - - if (b.CancellationPending) - { - return false; - } - - movingEvent.Reset(); - if (!movingEvent.WaitOne(timeout)) - { - isDone = false; - } - else - { - isDone = true; - } - - if (b.CancellationPending) - { - return false; - } - - return isDone; - } - - // --- public void HomeDevice() --- - /// - /// Runs the home routine to return the machine to the home position. - /// - public void HomeDevice() - { - homingEvent.Reset(); - - base.QueueCommand("mh"); - - homingEvent.WaitOne(base.TimeOut); - } - - // --- public void CycleTool() --- - /// - /// Sends a cycle tool command to the machine waiting until the tool cycle is finished. - /// - /// A 'bool' that signals whether the cycle command was successfully completed. - public bool CycleTool() - { - bool isDone = false; - - base.QueueCommand("mt"); - - cyclingEvent.Reset(); - cyclingEvent.WaitOne(); - - isDone = true; - - return isDone; - } - - // --- public void CycleTool() --- - /// - /// Sends a cycle tool command to the machine, waiting for the tool cycle to finish or for the given timeout duration before finishing. - /// - /// An 'int' that denotes the number of milliseconds to timeout on. - /// A 'bool' that signals whether the cycle command was successfully completed. - public bool CycleTool(int timeout) - { - bool isDone = false; - - base.QueueCommand("mt"); - - cyclingEvent.Reset(); - if (!cyclingEvent.WaitOne((int)timeout)) - { - isDone = false; - } - else - { - isDone = true; - } - - - return isDone; - } - - // --- public bool CycleTool(ref BackgroundWorker b) --- - /// - /// Sends a cycle tool command to the machine waiting until the tool cycle is finished. - /// - /// A 'BackgroundWorker' that is running CycleTool() that may signal an impending cancellation. - /// A 'bool' that signals whether the cycle command was successfully completed. - public bool CycleTool(ref BackgroundWorker b) - { - bool isDone = false; - - base.QueueCommand("mt"); - - if (b.CancellationPending) - { - return false; - } - - cyclingEvent.Reset(); - cyclingEvent.WaitOne(); - - if (b.CancellationPending) - { - return false; - } - - isDone = true; - - return isDone; - } - - // --- public bool CycleTool(ref BackgroundWorker b) --- - /// - /// Sends a cycle tool command to the machine waiting until the tool cycle is finished. - /// - /// An 'int' that denotes the number of milliseconds to timeout on. - /// A 'BackgroundWorker' that is running CycleTool() that may signal an impending cancellation. - /// A 'bool' that signals whether the cycle command was successfully completed. - public bool CycleTool(int timeout, ref BackgroundWorker b) - { - bool isDone = false; - - base.QueueCommand("mt"); - - if (b.CancellationPending) - { - return false; - } - - cyclingEvent.Reset(); - if (!cyclingEvent.WaitOne((int)timeout)) - { - isDone = false; - } - else - { - isDone = true; - } - - if (b.CancellationPending) - { - return false; - } - - - return isDone; - } - - // --- public string GetSetting(int settingIndex) --- - /// - /// Returns the value of a desired setting at 'settingIndex'. - /// - /// An 'int' that relates to the index of the desired setting to retrieve. - /// A 'string' containing the value of the setting at 'settingIndex' or 'null' if a response wasn't received in an expected time frame. - public string GetSetting(int settingIndex) - { - string settingValue = null; - - base.QueueCommand("d" + settingIndex); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(2000)) - { - settingValue = AckMessage; - } - - return settingValue; - } - - // --- public string GetSetting(string settingName) --- - /// - /// Returns the value of the desired setting whose name matches 'settingName'. - /// - /// A 'string' that matches the name of the desired setting to retrieve. - /// A 'string' containing the value of the setting whose name matches 'settingName' or 'null' if a response wasn't received in an expected time frame. - public string GetSetting(string settingName) - { - string settingValue = null; - - if (settingNames.Contains(settingName)) - { - base.QueueCommand("d" + (settingNames.IndexOf(settingName) + 1)); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(2000)) - { - settingValue = AckMessage; - } - } - - return settingValue; - } - - // --- public string GetSetting(int settingIndex, int timeout) --- - /// - /// Returns the value of the desired setting at 'settingIndex', waiting for 'timeout's duration for a response. - /// - /// An 'int' that relates to the index of the desired setting to retrieve. - /// An 'int' representing the desired timeout value in milliseconds the function will wait for a response. - /// A 'string' containing the value of the setting at 'settingIndex' or 'null' if a response was not received in the expected time frame of 'timeout'. - public string GetSetting(int settingIndex, int timeout) - { - string settingValue = null; - - base.QueueCommand("d" + settingIndex); - - ackEvent.Reset(); - if (ackEvent.WaitOne(timeout)) - { - settingValue = AckMessage; - } - - return settingValue; - } - - // --- public string GetSetting(string settingName, int timeout) --- - /// - /// Returns the value of the setting whose name matches 'settingName', waiting for 'timeout's duration for a response. - /// - /// A 'string' that matches the name of the desired setting to retrieve. - /// An 'int' representing the desired timeout value in milliseconds the function will wait for a response. - /// A 'string' containing the value of the setting whose name matches 'settingName' or 'null' if a response wasn't received in the expected time frame of 'timeout'. - public string GetSetting(string settingName, int timeout) - { - string settingValue = null; - - if (settingNames.Contains(settingName)) - { - base.QueueCommand("d" + settingNames.IndexOf(settingName)); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(timeout)) - { - settingValue = AckMessage; - } - } - - return settingValue; - } - - // --- public void Stop() --- - /// - /// Sends a stop command to the machine, ending any action its currently in the middle of. - /// - public void Stop() - { - base.QueueCommand("ms"); - } - - // --- public void EmergencyStop() --- - /// - /// Sends an emergency stop command to the machine, ending any action its currently in the middle of and disabling the machine's drive. - /// - public void EmergencyStop() - { - base.QueueCommand("me"); - } - - // --- public static Dictionary[] FindConnections() --- - /// - /// Searches through all available com ports and baud rates to find potential connections by asking for serial numbers from machines that - /// might be on the other end of the connection. - /// - /// A 'Dictionary' where a 'string' comport name key has an 'int' baud rate value. - public static List> Connections() - { - return FindConnections(); - } - - // --- public string[] GetAnalog() --- - /// - /// Returns the analog values tracked by the amp. - /// - /// A 'string' array of 5 entries that hold each of the 5 analog values tracked by the amp. - public string[] GetAnalog() - { - string[] values = new string[5]; - - base.QueueCommand("a"); - - for (int i = 0; i < 5; i++) - { - ackEvent.Reset(); - - if (ackEvent.WaitOne(500)) - { - values[i] = AckMessage; - } - } - - return values; - } - - // --- public string GetAnalog(int subCommand) --- - /// - /// Returns the analog value related to the analog subcommand, 1-5, 'subCommand' matches. - /// - /// An 'int' that represents the desired subcommand value to retrieve. - /// A 'string' that represents the returned value of the subcommand at 'subCommand' or 'null' if a response is not received in an expected time frame. - public string GetAnalog(int subCommand) - { - string analogValue = null; - - base.QueueCommand("a" + subCommand); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(2000)) - { - analogValue = AckMessage; - } - - return analogValue; - } - - // --- public string GetAnalog(int subCommand, int timeout) --- - /// - /// Returns the analog value related to the analog subcommand, 1-5, 'subCommand' matches. Waiting for the duration of 'timeout' for a response. - /// - /// An 'int' that represents the desired subcommand value to retrieve. - /// An 'int' representing the desired timeout value in milliseconds the function will wait for a response. - /// A 'string' that represents the returned value of the subcommand at 'subCommand' or 'null' if a response is not received in the expected time frame of 'timeout'. - public string GetAnalog(int subCommand, int timeout) - { - string analogValue = null; - - base.QueueCommand("a" + subCommand); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(timeout)) - { - analogValue = AckMessage; - } - - return analogValue; - } - - // --- public string GetAnalog(string subCommand) --- - /// - /// Returns the analog value related to the analog subcommand, 1-5, 'subCommand' matches. - /// - /// An 'string' that represents the desired subcommand value to retrieve. - /// A 'string' that represents the returned value of the subcommand at 'subCommand' or 'null' if a response is not received in an expected time frame. - public string GetAnalog(string subCommand) - { - string analogValue = null; - - base.QueueCommand("a" + subCommand); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(2000)) - { - analogValue = AckMessage; - } - - return analogValue; - } - - // --- public string GetAnalog(string subCommand, int timeout) --- - /// - /// Returns the analog value related to the analog subcommand, 1-5, 'subCommand' matches. Waiting for the duration of 'timeout' for a response. - /// - /// An 'string' that represents the desired subcommand value to retrieve. - /// An 'int' representing the desired timeout value in milliseconds the function will wait for a response. - /// A 'string' that represents the returned value of the subcommand at 'subCommand' or 'null' if a response is not received in the expected time frame of 'timeout'. - public string GetAnalog(string subCommand, int timeout) - { - string analogValue = null; - - base.QueueCommand("a" + subCommand); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(timeout)) - { - analogValue = AckMessage; - } - - return analogValue; - } - - // --- public string[] GetLog() --- - /// - /// Returns the 20 most recent command and error log entries. - /// - /// A 'string' array of 20 entries that hold each of the 20 command and error log entries. - public string[] GetLog() - { - string[] log = new string[20]; - - base.QueueCommand("b"); - - for (int i = 0; i < 20; i++) - { - ackEvent.Reset(); - - if (ackEvent.WaitOne(500)) - { - log[i] = AckMessage; - } - } - - return log; - } - - // --- public string[] GetLog(int logIndex) --- - /// - /// Returns the 20 most recent command and error log entries starting at 'logIndex' and going back. - /// - /// An 'int' that designates the log index to start from. - /// A 'string' array of 20 entries that hold each of the command and error log entries starting at 'logIndex'. - public string[] GetLog(int logIndex) - { - string[] log = new string[20]; - - base.QueueCommand("b" + logIndex); - - for (int i = 0; i < 20; i++) - { - ackEvent.Reset(); - - if (ackEvent.WaitOne(500)) - { - log[i] = AckMessage; - } - } - - return log; - } - - // --- public string[] GetLog(string logIndex) --- - /// - /// Returns the 20 most recent command and error log entries starting at 'logIndex' and going back. - /// - /// An 'string' that designates the log index to start from. - /// A 'string' array of 20 entries that hold each of the command and error log entries starting at 'logIndex'. - public string[] GetLog(string logIndex) - { - string[] log = new string[20]; - - base.QueueCommand("b" + logIndex); - - for (int i = 0; i < 20; i++) - { - ackEvent.Reset(); - - if (ackEvent.WaitOne(500)) - { - log[i] = AckMessage; - } - } - - return log; - } - - // --- public string[] GetCounters() --- - /// - /// Returns the 25 counter values tracked by the amp. - /// - /// A 'string' array of 25 entries that hold each of the 25 counter values tracked by the amp. - public string[] GetCounter() - { - string[] counters = new string[25]; - - base.QueueCommand("c"); - - for (int i = 0; i < 25; i++) - { - ackEvent.Reset(); - - if (ackEvent.WaitOne(500)) - { - counters[i] = AckMessage; - } - } - - return counters; - } - - // --- public string GetCounter(int subCommand) --- - /// - /// Returns the counter value related to the counter subcommand, 1-25, 'subCommand' matches. - /// - /// An 'int' that represents the desired subcommand value to retrieve. - /// A 'string' that represents the returned value of the subcommand at 'subCommand' or 'null' if a response is not received in an expected time frame. - public string GetCounter(int subCommand) - { - string counterValue = null; - - base.QueueCommand("c" + subCommand); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(2000)) - { - counterValue = AckMessage; - } - - return counterValue; - } - - // --- public string GetCounter(int subCommand, int timeout) --- - /// - /// Returns the counter value related to the counter subcommand, 1-25, 'subCommand' matches. Waiting for the duration of 'timeout' for a response. - /// - /// An 'int' that represents the desired subcommand value to retrieve. - /// An 'int' representing the desired timeout value in milliseconds the function will wait for a response. - /// A 'string' that represents the returned value of the subcommand at 'subCommand' or 'null' if a response is not received in the expected time frame of 'timeout'. - public string GetCounter(int subCommand, int timeout) - { - string counterValue = null; - - base.QueueCommand("c" + subCommand); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(timeout)) - { - counterValue = AckMessage; - } - - return counterValue; - } - - // --- public string GetCounter(string subCommand) --- - /// - /// Returns the counter value related to the counter subcommand, 1-25, 'subCommand' matches. - /// - /// A 'string' that represents the desired subcommand value to retrieve. - /// A 'string' that represents the returned value of the subcommand at 'subCommand' or 'null' if a response is not received in an expected time frame. - public string GetCounter(string subCommand) - { - string counterValue = null; - - base.QueueCommand("c" + subCommand); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(2000)) - { - counterValue = AckMessage; - } - - return counterValue; - } - - // --- public string GetCounter(string subCommand, int timeout) --- - /// - /// Returns the counter value related to the counter subcommand, 1-25, 'subCommand' matches. Waiting for the duration of 'timeout' for a response. - /// - /// A 'string' that represents the desired subcommand value to retrieve. - /// An 'int' representing the desired timeout value in milliseconds the function will wait for a response. - /// A 'string' that represents the returned value of the subcommand at 'subCommand' or 'null' if a response is not received in the expected time frame of 'timeout'. - public string GetCounter(string subCommand, int timeout) - { - string counterValue = null; - - base.QueueCommand("c" + subCommand); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(timeout)) - { - counterValue = AckMessage; - } - - return counterValue; - } - - // --- public string GetPosition() --- - /// - /// Returns the current position of the machine. - /// - /// A 'double' that represents the returned current position from the machine or 'NaN' if no response is received in an expected time frame. - public double GetPosition() - { - double pos = 0.00; - - base.QueueCommand("p"); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(2000)) - { - pos = Convert.ToDouble(AckMessage.TrimEnd('\r')); - } - else - { - pos = double.NaN; - } - - return pos; - } - - // --- public double GetPosition(int timeout) --- - /// - /// Returns the current position of the machine, waiting for the duration of 'timeout' for a response. - /// - /// An 'int' that representing the desired timeout value in milliseconds the function will wait for a response. - /// A 'double' that represents the returned current position from the machine or 'NaN' if no response is received in the expected time frame of 'timeout'. - public double GetPosition(int timeout) - { - double pos = 0.00; - - base.QueueCommand("p"); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(timeout)) - { - pos = Convert.ToDouble(AckMessage.TrimEnd('\r')); - } - else - { - pos = double.NaN; - } - - return pos; - } - - // --- public int GetStatus() --- - /// - /// Returns the current status of the machine. - /// - /// An 'int' that represents the returned status of the machine or '-1' if no response is received in an expected time frame. - public int GetStatus() - { - int state = -1; - - base.QueueCommand("s"); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(2000)) - { - state = Convert.ToInt32(AckMessage); - } - - return state; - } - - // --- public int GetStatus(int timeout) --- - /// - /// Returns the current status of the machine, waiting for the duration of 'timeout' for a response. - /// - /// An 'int' representing the desired timeout value in milliseconds the function will wait for a response. - /// An 'int' that represents the returned status of the machine or '-1' if no response is received in the expected time frame of 'timeout'. - public int GetStatus(int timeout) - { - int state = -1; - - base.QueueCommand("s"); - - ackEvent.Reset(); - - if (ackEvent.WaitOne(timeout)) - { - state = Convert.ToInt32(AckMessage); - } - - return state; - } - - // --- public void DriveSleep() --- - /// - /// Sends the drive sleep command to turn off the amp drive. - /// - public void DriveSleep() - { - base.QueueCommand("f6"); - } - - // --- public void DriveWake() --- - /// - /// Sends the wake up command to turn on the amp drive. - /// - public void DriveWake() - { - base.QueueCommand("f7"); - } - - // --- public void SendCommand(string command) --- - /// - /// Sends 'command' to the machine to execute. - /// - /// A 'string' representing the command being sent to the machine to execute. - public void SendCommand(string command) - { - base.QueueCommand(command); - } - - // --- public bool UpdateSetting(string settingName, int newValue) --- - /// - /// Changes the setting value of 'settingName' to 'newValue'. - /// - /// A 'string' the represents the name of the setting to change. - /// A 'double' that represents the new value 'settingName' is being changed to. - /// A 'bool' that signals whether the setting was successfully changed. - public bool UpdateSetting(string settingName, double newValue) - { - bool isChanged = false; - - base.ChangeSetting("d" + (settingNames.IndexOf(settingName) + 1) + " " + newValue); - - ackEvent.Reset(); - ackEvent.Set(); - - if (AckMessage == "SetUp") - { - isChanged = true; - } - else - { - isChanged = false; - } - - return isChanged; - } - - // --- public bool UpdateSetting(string settingName, string newValue) --- - /// - /// Changes the setting value of 'settingName' to 'newValue'. - /// - /// A 'string' the represents the name of the setting to change. - /// An 'string' that represents the new value 'settingName' is being changed to. - /// A 'bool' that signals whether the setting was successfully changed. - public bool UpdateSetting(string settingName, string newValue) - { - bool isChanged = false; - - base.ChangeSetting("d" + (settingNames.IndexOf(settingName) + 1) + " " + newValue); - - ackEvent.Reset(); - ackEvent.Set(); - - if (AckMessage == "SetUp") - { - isChanged = true; - } - else - { - isChanged = false; - } - - return isChanged; - } - - // --- public bool UpdateSetting(int settingIndex, int newValue) --- - /// - /// Changes the setting value at 'settingIndex' to 'newValue'. - /// - /// An 'int' the represents the index of the setting to change. - /// An 'int' that represents the new value the setting is being changed to. - /// A 'bool' that signals whether the setting was successfully changed. - public bool UpdateSetting(int settingIndex, double newValue) - { - bool isChanged = false; - - base.ChangeSetting("d" + settingIndex + " " + newValue); - - ackEvent.Reset(); - ackEvent.Set(); - - if (AckMessage == "SetUp") - { - isChanged = true; - } - else - { - isChanged = false; - } - - return isChanged; - } - - // --- public bool UpdateSetting(int settingIndex, string newValue) --- - /// - /// Changes the setting value at 'settingIndex' to 'newValue'. - /// - /// An 'int' the represents the index of the setting to change. - /// A 'double' that represents the new value the setting is being changed to. - /// A 'bool' that signals whether the setting was successfully changed. - public bool UpdateSetting(int settingIndex, string newValue) - { - bool isChanged = false; - - base.ChangeSetting("d" + settingIndex + " " + newValue); - - ackEvent.Reset(); - ackEvent.Set(); - - if (AckMessage == "SetUp") - { - isChanged = true; - } - else - { - isChanged = false; - } - - return isChanged; - } - - // --- public bool DetectToolCycle() --- - /// - /// Listens for the expected sequence of acknowledgments from the machine, making sure that the deadman off signal followed by the deadman on signal - /// is received by the system, meaning a full tool cycle occurred. - /// - /// A 'bool' denoting whether a deadman off and on signal was received in sequence, defining a full tool cycle has occurred. - public bool DetectToolCycle() - { - bool cycled = false; - - deadmanOffEvent.Reset(); - deadmanOffEvent.WaitOne(-1); - - deadmanOnEvent.Reset(); - deadmanOnEvent.WaitOne(-1); - - return cycled; - } - - // --- public bool DetectToolCycle(int timeout) --- - /// - /// Listens for the expected sequence of acknowledgments from the machine, make sure that the deadman off signal followed by the deadman on signal - /// us received by the system, meaning a full tool cycle occurred. Each of the waiting events will wait for the duration of 'timeout' for a response. - /// - /// An 'int' representing the desired timeout value in milliseconds the function will wait for a response. - /// A 'bool' denoting whether a deadman off and on signal was received in sequence, defining a full tool cycle has occurred. - public bool DetectToolCycle(int timeout) - { - bool isDmOff = false; - bool isDmOn = false; - bool cycled = false; - - deadmanOffEvent.Reset(); - - if (deadmanOffEvent.WaitOne(timeout)) - { - isDmOff = true; - } - - deadmanOnEvent.Reset(); - - if (deadmanOnEvent.WaitOne(timeout)) - { - isDmOn = true; - } - - if (isDmOff && isDmOn) - { - cycled = true; - } - - return cycled; - } - - // --- public bool DetectToolCycle(int timeout1, int timeout 2) --- - /// - /// Listens for the expected sequence of acknowledgments from the machine, make sure that the deadman off signal followed by the deadman on signal - /// us received by the system, meaning a full tool cycle occurred. The first waiting event will wait for the duration of 'timeout1' for a response, - /// and the second waiting event will wait for the duration of 'timeout2' for a response. - /// - /// An 'int' representing the desired timeout value in milliseconds the first event will wait for a response. - /// An 'int' representing the desired timeout value in milliseconds the second event will wait for a response. - /// A 'bool' denoting whether a deadman off and on signal was received in sequence, defining a full tool cycle has occurred. - public bool DetectToolCycle(int timeout1, int timeout2) - { - bool isDmOff = false; - bool isDmOn = false; - bool cycled = false; - - deadmanOffEvent.Reset(); - - if (deadmanOffEvent.WaitOne(timeout1)) - { - isDmOff = true; - } - - deadmanOnEvent.Reset(); - - if (deadmanOnEvent.WaitOne(timeout2)) - { - isDmOn = true; - } - - if (isDmOff && isDmOn) - { - cycled = true; - } - - return cycled; - } - - // --- public bool DetectToolCycle(ref BacgroundWorker b) --- - /// - /// Listens for the expected sequence of acknowledgments from the machine, make sure that the deadman off signal followed by the deadman on signal - /// us received by the system, meaning a full tool cycle occurred. - /// - /// A 'BackgroundWorker' that is running DetectToolCycle() that may signal an impending cancellation. - /// A 'bool' denoting whether a deadman off and on signal was received in sequence, defining a full tool cycle has occurred. - public bool DetectToolCycle(ref BackgroundWorker b) - { - bool isDmOff = false; - bool isDmOn = false; - bool cycled = false; - - if (b.CancellationPending) - { - return false; - } - - deadmanOffEvent.Reset(); - deadmanOffEvent.WaitOne(-1); - isDmOff = true; - - if (b.CancellationPending) - { - return false; - } - - deadmanOnEvent.Reset(); - deadmanOnEvent.WaitOne(-1); - isDmOn = true; - - if (b.CancellationPending) - { - return false; - } - - if (isDmOff && isDmOn) - { - cycled = true; - } - - return cycled; - } - - // --- public bool DetectToolCycle(int timeout, ref BackgroundWorker b) --- - /// - /// Listens for the expected sequence of acknowledgments from the machine, make sure that the deadman off signal followed by the deadman on signal - /// us received by the system, meaning a full tool cycle occurred. Each of the waiting events will wait for the duration of 'timeout' for a response. - /// - /// An 'int' representing the desired timeout value in milliseconds the function will wait for a response. - /// A 'BackgroundWorker' that is running DetectToolCycle() that may signal an impending cancellation. - /// A 'bool' denoting whether a deadman off and on signal was received in sequence, defining a full tool cycle has occurred. - public bool DetectToolCycle(int timeout, ref BackgroundWorker b) - { - bool isDmOff = false; - bool isDmOn = false; - bool cycled = false; - - if (b.CancellationPending) - { - return false; - } - - deadmanOffEvent.Reset(); - if (deadmanOffEvent.WaitOne(timeout)) - { - isDmOff = true; - } - - if (b.CancellationPending) - { - return false; - } - - deadmanOnEvent.Reset(); - if (deadmanOnEvent.WaitOne(timeout)) - { - isDmOn = true; - } - - if (b.CancellationPending) - { - return false; - } - - if (isDmOff && isDmOn) - { - cycled = true; - } - - return cycled; - } - - // --- public bool DetectToolCycle(int timeout1, int timeout2, ref BackgroundWorker b) --- - /// - /// Listens for the expected sequence of acknowledgments from the machine, make sure that the deadman off signal followed by the deadman on signal - /// us received by the system, meaning a full tool cycle occurred. The first waiting event will wait for the duration of 'timeout1' for a response, - /// and the second waiting event will wait for the duration of 'timeout2' for a response. - /// - /// An 'int' representing the desired timeout value in milliseconds the first event will wait for a response. - /// An 'int' representing the desired timeout value in milliseconds the second event will wait for a response. - /// A 'BackgroundWorker' that is running DetectToolCycle() that may signal an impending cancellation. - /// A 'bool' denoting whether a deadman off and on signal was received in sequence, defining a full tool cycle has occurred. - public bool DetectToolCycle(int timeout1, int timeout2, ref BackgroundWorker b) - { - bool isDmOff = false; - bool isDmOn = false; - bool cycled = false; - - if (b.CancellationPending) - { - return false; - } - - deadmanOffEvent.Reset(); - if (deadmanOffEvent.WaitOne(timeout1)) - { - isDmOff = true; - } - - if (b.CancellationPending) - { - return false; - } - - deadmanOnEvent.Reset(); - if (deadmanOnEvent.WaitOne(timeout2)) - { - isDmOn = true; - } - - if (b.CancellationPending) - { - return false; - } - - if (isDmOff && isDmOn) - { - cycled = true; - } - - return cycled; - } - - // --- public bool IO_Connection(bool onOff) --- - /// - /// Turns the desired IO connection on the IO panel on or off depending on 'onOff'. - /// - /// An 'int' denoting which IO connection, 1 - 12, on the IO panel to change. If 'ioNum' is outside of the range 1 - 12, it is treated as 1. - /// A 'bool' that signals whether to turn the connection on if 'onOff' is 'true' and off if 'onOff' is 'false'. - /// A 'bool' denoting whether an acknowledgment was received for the command. - public bool IO_Connection(int ioNum, bool onOff) - { - bool acknowledged = false; - string mask = string.Empty; - - switch (ioNum) - { - case 1: - mask = "0x001"; - break; - case 2: - mask = "0x002"; - break; - case 3: - mask = "0x004"; - break; - case 4: - mask = "0x008"; - break; - case 5: - mask = "0x010"; - break; - case 6: - mask = "0x020"; - break; - case 7: - mask = "0x040"; - break; - case 8: - mask = "0x080"; - break; - case 9: - mask = "0x100"; - break; - case 10: - mask = "0x200"; - break; - case 11: - mask = "0x400"; - break; - case 12: - mask = "0x800"; - break; - default: - return acknowledged; - } - - if (onOff) - { - base.QueueCommand("ww " + "0xFFF " + mask); - } - else - { - base.QueueCommand("ww " + "0x000 " + mask); - } - - ackEvent.Reset(); - ackEvent.WaitOne(); - - acknowledged = true; - - return acknowledged; - } - - // --- public bool IO_Connection(bool onOff, int timeout) --- - /// - /// Turns the desired IO connection on the IO panel on or off depending on 'onOff', waiting for the duration of 'timeout' for a response. - /// - /// An 'int' denoting which IO connection, 1 - 12, on the IO panel to change. If 'ioNum' is outside of the range 1 - 12, it is treated as 1. - /// A 'bool' that signals whether to turn the connection on if 'onOff' is 'true' and off if 'onOff' is 'false'. - /// An 'int' representing the desired timeout value in milliseconds the event will wait for a response. - /// A 'bool' denoting whether an acknowledgment was received for the command. - public bool IO_Connection(int ioNum, bool onOff, int timeout) - { - bool acknowledged = false; - string mask = string.Empty; - - switch (ioNum) - { - case 1: - mask = "0x001"; - break; - case 2: - mask = "0x002"; - break; - case 3: - mask = "0x004"; - break; - case 4: - mask = "0x008"; - break; - case 5: - mask = "0x010"; - break; - case 6: - mask = "0x020"; - break; - case 7: - mask = "0x040"; - break; - case 8: - mask = "0x080"; - break; - case 9: - mask = "0x100"; - break; - case 10: - mask = "0x200"; - break; - case 11: - mask = "0x400"; - break; - case 12: - mask = "0x800"; - break; - default: - return acknowledged; - } - - if (onOff) - { - base.QueueCommand("ww " + "0xFFF " + mask); - } - else - { - base.QueueCommand("ww " + "0x000 " + mask); - } - - ackEvent.Reset(); - - if (!ackEvent.WaitOne(timeout)) - { - acknowledged = false; - } - else - { - acknowledged = true; - } - - return acknowledged; - } - } -} diff --git a/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopAPI.dll b/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopAPI.dll index 849038a..e98b0a3 100644 Binary files a/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopAPI.dll and b/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopAPI.dll differ diff --git a/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopAPI.pdb b/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopAPI.pdb index a1a3a25..48f06c0 100644 Binary files a/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopAPI.pdb and b/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopAPI.pdb differ diff --git a/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopSDKExample.exe b/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopSDKExample.exe index cafd021..e580995 100644 Binary files a/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopSDKExample.exe and b/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopSDKExample.exe differ diff --git a/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopSDKExample.pdb b/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopSDKExample.pdb index 12ac29d..5fe6a55 100644 Binary files a/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopSDKExample.pdb and b/TigerStopSDKExample/TigerStopSDKTest/bin/Debug/TigerStopSDKExample.pdb differ diff --git a/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache b/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache index d75c9be..adb12bf 100644 Binary files a/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache and b/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache differ diff --git a/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.csproj.FileListAbsolute.txt b/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.csproj.FileListAbsolute.txt index 59f4386..9045c7c 100644 --- a/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.csproj.FileListAbsolute.txt +++ b/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.csproj.FileListAbsolute.txt @@ -16,3 +16,13 @@ C:\Users\jshoup\Documents\OpenSource Gits\SDKExGit\TigerStopSDKExample\TigerStop C:\Users\jshoup\Documents\OpenSource Gits\SDKExGit\TigerStopSDKExample\TigerStopSDKTest\bin\Debug\TigerStopSDKExample.pdb C:\Users\jshoup\Documents\OpenSource Gits\SDKExGit\TigerStopSDKExample\TigerStopSDKTest\bin\Debug\TigerStopAPI.pdb C:\Users\jshoup\Documents\OpenSource Gits\SDKExGit\TigerStopSDKExample\TigerStopSDKTest\obj\Debug\TigerStopSDKExample.csprojResolveAssemblyReference.cache +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\bin\Debug\TigerStopSDKExample.exe.config +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\bin\Debug\TigerStopSDKExample.exe +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\bin\Debug\TigerStopSDKExample.pdb +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\bin\Debug\TigerStopAPI.dll +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\bin\Debug\TigerStopAPI.pdb +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\obj\Debug\TigerStopSDKExample.csprojAssemblyReference.cache +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\obj\Debug\TigerStopSDKExample.csproj.CoreCompileInputs.cache +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\obj\Debug\TigerStopSDKExample.csproj.CopyComplete +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\obj\Debug\TigerStopSDKExample.exe +C:\Users\ckoch\Source\Repos\TigerStopSDK-Example\TigerStopSDKExample\TigerStopSDKTest\obj\Debug\TigerStopSDKExample.pdb diff --git a/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.exe b/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.exe index cafd021..e580995 100644 Binary files a/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.exe and b/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.exe differ diff --git a/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.pdb b/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.pdb index 12ac29d..5fe6a55 100644 Binary files a/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.pdb and b/TigerStopSDKExample/TigerStopSDKTest/obj/Debug/TigerStopSDKExample.pdb differ