diff --git a/Results/Properties/AssemblyInfo.cs b/Results/Properties/AssemblyInfo.cs index ae3654583..727955f1f 100644 --- a/Results/Properties/AssemblyInfo.cs +++ b/Results/Properties/AssemblyInfo.cs @@ -32,5 +32,5 @@ using System.Runtime.InteropServices; // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("2.17.760.0")] -[assembly: AssemblyFileVersion("2.17.760.0")] +[assembly: AssemblyVersion("2.17.762.0")] +[assembly: AssemblyFileVersion("2.17.762.0")] diff --git a/TestBenchFramework/BenchControl/Elde/StartMeasurementOp.cs b/TestBenchFramework/BenchControl/Elde/StartMeasurementOp.cs index 5e28975b5..b346103ef 100644 --- a/TestBenchFramework/BenchControl/Elde/StartMeasurementOp.cs +++ b/TestBenchFramework/BenchControl/Elde/StartMeasurementOp.cs @@ -112,6 +112,8 @@ namespace TBF.BenchControl.Elde #else int flowMeterIdxAndDiv = flowMeterNr; #endif + log.InfoFormat("Start() : SendCommand(Cmd.Start, {0}, route, {1}, {1}, {2}, {3}, {4}, 0, Stop.None)", + flowMeterIdxAndDiv, refPulses, testMethod, filterConstant, (int)pidCoef); controlBoard.SendCommand(Command.Start, flowMeterIdxAndDiv, controlBoard.Route, refPulses, refPulses, testMethod, diff --git a/TestBenchFramework/BenchControl/Network/Camera/CLP1611/Camera.cs b/TestBenchFramework/BenchControl/Network/Camera/CLP1611/Camera.cs index 80a969e6c..e3a12407d 100644 --- a/TestBenchFramework/BenchControl/Network/Camera/CLP1611/Camera.cs +++ b/TestBenchFramework/BenchControl/Network/Camera/CLP1611/Camera.cs @@ -154,12 +154,9 @@ namespace TBF.BenchControl.Network.Camera.CLP1611 roisAndResults = new RoisAndResults(); /// object for measurement results, writes/reads to/from this object are locked running = false; - - log.Debug(this.ToString()); } - public void Initialize() { cameraIdx = GetCameraIdx(); @@ -211,7 +208,7 @@ namespace TBF.BenchControl.Network.Camera.CLP1611 Telnet.Enqueue(new Telnet.Command(Network.Telnet.CmdAction.CLEAR_RESPONSE)); Telnet.Enqueue(new Telnet.Command(Network.Telnet.CmdAction.SEND_COMMAND, "sha1sum clp/*")); - log.FatalFormat("'{0}' with address {1} detected, IP address = {2}", Name, CameraCfg.HardwareAddress, ipAddress); + log.FatalFormat("'{0}' with address {1} detected, IP = {2}, SD = {3}", Name, CameraCfg.HardwareAddress, ipAddress, sdCardVer); } else { @@ -461,7 +458,15 @@ namespace TBF.BenchControl.Network.Camera.CLP1611 if (!sha1sumResponse.Contains(fi.Name)) { /// Change file properties if it was a new file - sshClient.CreateCommand(string.Format("chmod 755 clp/{0}", fi.Name)).Execute(); + string command = string.Format("chmod 755 clp/{0}", fi.Name); + log.InfoFormat("{0}, IP={1}, Executing command '{2}'", Name, IPAddress, command); + sshClient.CreateCommand(command).Execute(); + + //if (fi.Name.Equals("runmeonce")) + //{ + // log.InfoFormat("{0}, IP={1}, Executing command 'sudo clp/runmeonce'", Name, IPAddress); + // sshClient.CreateCommand("sudo clp/runmeonce").Execute(); + //} } } } @@ -472,32 +477,32 @@ namespace TBF.BenchControl.Network.Camera.CLP1611 /// /// Run SCP command loop /// - if (scpConnected) + while (scpConnected && !stopScpThreadFlag) { - while (!stopScpThreadFlag) + switch (scpCommand) { - switch (scpCommand) - { - case ScpCommand.Get: - scpCommand = ScpCommand.None; - scpClient.Download(scpRemoteFileName, new System.IO.FileInfo(scpLocalFileName)); - break; + case ScpCommand.Get: + scpCommand = ScpCommand.None; + scpClient.Download(scpRemoteFileName, new System.IO.FileInfo(scpLocalFileName)); + break; - case ScpCommand.Put: - scpCommand = ScpCommand.None; - scpClient.Upload(new System.IO.FileInfo(scpLocalFileName), scpRemoteFileName); - break; + case ScpCommand.Put: + scpCommand = ScpCommand.None; + scpClient.Upload(new System.IO.FileInfo(scpLocalFileName), scpRemoteFileName); + break; - default: - Thread.Sleep(250); - break; - } + default: + Thread.Sleep(250); + break; } + + scpConnected = scpClient.IsConnected; } - scpClient.Disconnect(); + running = false; + scpClient.Disconnect(); scpConnected = false; - } + } } catch (Exception exc) { diff --git a/TestBenchFramework/CameraBinaryFiles/rc.local b/TestBenchFramework/CameraBinaryFiles/rc.local new file mode 100644 index 000000000..cd4ffcd74 --- /dev/null +++ b/TestBenchFramework/CameraBinaryFiles/rc.local @@ -0,0 +1,23 @@ +#!/bin/sh -e +# +# rc.local +# +# This script is executed at the end of each multiuser runlevel. +# Make sure that the script will "exit 0" on success or any other +# value on error. +# +# In order to enable or disable this script just change the execution +# bits. +# +# By default this script does nothing. + +# Print the IP address +_IP=$(hostname -I) || true +if [ "$_IP" ]; then + printf "My IP address is %s\n" "$_IP" +fi + +# Start camera discovery daemon +/usr/bin/DiscoveryDaemon 1.3 & + +exit 0 diff --git a/TestBenchFramework/CameraBinaryFiles/runmeonce b/TestBenchFramework/CameraBinaryFiles/runmeonce new file mode 100644 index 000000000..86dff593d --- /dev/null +++ b/TestBenchFramework/CameraBinaryFiles/runmeonce @@ -0,0 +1,4 @@ +pkill DiscoveryDaemon +cp clp/DiscoveryDaemon /usr/bin +cp clp/rc.local /etc +shutdown -r now diff --git a/TestBenchFramework/Properties/AssemblyInfo.cs b/TestBenchFramework/Properties/AssemblyInfo.cs index 20f423573..4d3fba87a 100644 --- a/TestBenchFramework/Properties/AssemblyInfo.cs +++ b/TestBenchFramework/Properties/AssemblyInfo.cs @@ -29,5 +29,5 @@ using System.Runtime.InteropServices; // Build Number // Revision // -[assembly: AssemblyVersion("2.17.761.0")] -[assembly: AssemblyFileVersion("2.17.761.0")] +[assembly: AssemblyVersion("2.17.762.0")] +[assembly: AssemblyFileVersion("2.17.762.0")] diff --git a/TestBenchFramework/TBF.csproj b/TestBenchFramework/TBF.csproj index 7512d693a..9f7456e3f 100644 --- a/TestBenchFramework/TBF.csproj +++ b/TestBenchFramework/TBF.csproj @@ -2640,6 +2640,15 @@ Always + + Always + + + Always + + + Always + Designer