Crashes when cameras fail to start

Post Reply
dc37
Posts: 25
Joined: Thu Jan 14, 2016 6:37 pm

Crashes when cameras fail to start

Post by dc37 »

When running jobs, the cameras appear to have trouble starting all the time (I get the "problem starting up camera" and "problem starting down camera" errors a lot). However, the cameras still somehow manage to start most of the time, and the machine job continues to run after that.

If they fail to actually start, then the program runs into an "unhandled exception" and then tends to crash, even if I hit continue. The error seems to note something about how a device attached to the machine has malfunctioned. I suspect that the USB cameras aren't being enumerated well. Juha, do you know what might be causing this? (and more importantly, some sort of fix for it?)

I should note that I am running this from the most recent program release, but not the most recent GitHub code, due to the frequency of crashes I experienced whilst setting up a 370-part job.
JuKu
Site Admin
Posts: 1114
Joined: Thu Feb 14, 2013 3:06 pm
Location: Tampere, Finland
Contact:

Re: Crashes when cameras fail to start

Post by JuKu »

To get you running: Does the "keep active" mode work for you?

To find the issue: What the log window shows?
dc37
Posts: 25
Joined: Thu Jan 14, 2016 6:37 pm

Re: Crashes when cameras fail to start

Post by dc37 »

It does not appear that "keep active" works very well for me. I've been using the robust mode, which takes more time, but as the dialog box says, it is more "robust".
Many times, I will have to plug & unplug the cameras for the switching to work again.


Code: Select all

See the end of this message for details on invoking 
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.ArgumentOutOfRangeException: InvalidArgument=Value of '1' is not valid for 'SelectedIndex'.
Parameter name: SelectedIndex
   at System.Windows.Forms.ComboBox.set_SelectedIndex(Int32 value)
   at LitePlacer.FormMain.getUpCamList()
   at LitePlacer.FormMain.tabPageSetupCameras_Begin()
   at LitePlacer.FormMain.tabControlPages_SelectedIndexChanged(Object sender, EventArgs e)
   at System.Windows.Forms.TabControl.OnSelectedIndexChanged(EventArgs e)
   at System.Windows.Forms.TabControl.WmSelChange()
   at System.Windows.Forms.TabControl.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


************** Loaded Assemblies **************
mscorlib
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34209 built by: FX452RTMGDR
    CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
----------------------------------------
LitePlacer
    Assembly Version: 1.0.5856.22847
    Win32 Version: 1.0.0.0
    CodeBase: file:///C:/LitePlacer/LitePlacer.exe
----------------------------------------
System.Windows.Forms
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34251 built by: FX452RTMGDR
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System.Drawing
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34270 built by: FX452RTMGDR
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
System
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34238 built by: FX452RTMGDR
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Configuration
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34209 built by: FX452RTMGDR
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Core
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34209 built by: FX452RTMGDR
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
System.Xml
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34234 built by: FX452RTMGDR
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
AForge.Video.DirectShow
    Assembly Version: 2.2.5.0
    Win32 Version: 2.2.5.0
    CodeBase: file:///C:/LitePlacer/AForge.Video.DirectShow.DLL
----------------------------------------
AForge.Video
    Assembly Version: 2.2.5.0
    Win32 Version: 2.2.5.0
    CodeBase: file:///C:/LitePlacer/AForge.Video.DLL
----------------------------------------
System.Web.Extensions
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34280
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Web.Extensions/v4.0_4.0.0.0__31bf3856ad364e35/System.Web.Extensions.dll
----------------------------------------
System.Web
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34280 built by: FX452RTMGDR
    CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_32/System.Web/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Web.dll
----------------------------------------

************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.

For example:

<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>

When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.
JuKu
Site Admin
Posts: 1114
Joined: Thu Feb 14, 2013 3:06 pm
Location: Tampere, Finland
Contact:

Re: Crashes when cameras fail to start

Post by JuKu »

When looking for this, I found at least one issue in the software that might or might be related. IF the USB enumeration does not work as expected but has worked before (so the system has a memory of the camera), it is possible to end up to a setup, where both cameras point to the same physical unit. All kinds of weird things start to happen then. I'll fix this.
Mart
Posts: 13
Joined: Wed Jan 20, 2016 10:43 am

Re: Crashes when cameras fail to start

Post by Mart »

Seems the same problem I have.

Suspects selection combination "robust and keep active" setting which lets the software crash very often after a while.
Still can not lay a finger on the problem.

This adjustment is in the latest version software 26.02.2016? This version is used on another PC, but still have the same problem!
David
Posts: 5
Joined: Tue Nov 03, 2015 11:38 am

Re: Crashes when cameras fail to start

Post by David »

Yesterday I had my up camera fail.

I replaced it with another C270 and now the software crashes when I go to the camera setup screen.

I noticed the software now tries to bring up the cameras first and I get the warning message about my camera failed to start.

The problem is now I cannot select the camera.
Taking a look in the config file and I have tried a few ways to make the software forget the cameras in hope I can at least get to the software and choose the cameras again.

Really need to do a few boards today so any help will be great.

David.
David
Posts: 5
Joined: Tue Nov 03, 2015 11:38 am

Re: Crashes when cameras fail to start

Post by David »

Got it working,

Not sure what it was as I edited the config file keep camera active settings and changed USB ports on the up camera which I replaced.

It appears it was looking for the old camera, but Its not stored in the config file wherever it grabs this information from.

Ran the boards I needed to so that's great.
Mart
Posts: 13
Joined: Wed Jan 20, 2016 10:43 am

Re: Crashes when cameras fail to start

Post by Mart »

Replacing the USB camera drivers with those from windows (year 2006) and the last version software. Seems to work on some systems. If you connect the camera to a different USB port, check which driver it uses. Probably those from the manufacturer.
Post Reply