EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: RE: areaDetector problem
From: "Mark Rivers" <[email protected]>
To: "John Dobbins" <[email protected]>, "EPICS Techtalk" <[email protected]>
Date: Thu, 15 Jul 2010 17:32:49 -0500
John,
 
I'm willing to bet this problem is because you have not applied the patch to macLib in EPICS 3.14.11? 
 
This is from the areaDetector Release Notes:
 
Known problems. This release of areaDetector exposed two bugs in EPICS 3.14.11. Links to the required patches can be found on the EPICS 3.4.11 Known Problems page <http://www.aps.anl.gov/epics/base/R3-14/11-docs/KnownProblems.html> . 

*	The epicsThreadOnceOsd problem can cause crashes with an "assert" error on IOC initialization on Win32 systems. 
*	The macLib problem can cause crashes or memory corruption when the commonPlugins.cmd script expands lines with macros longer than 256 characters. 

The line that is crashing for you:

 dbLoadRecords("$(AREA_DETECTOR)/ADApp/Db/NDOverlayN.template", ...

generates a very long line when macro expansion is done.  This causes a buffer overflow in macLib, which Windows detects in the call to free().

Here is the note on the 3.14.11 Known Problems page:

2010-05-11: macLib has an off-by-one buffer overflow bug which only appears when using very long input lines. This patch <https://carsmail1.cars.aps.anl.gov/exchange/rivers/Drafts/RE:%20areaDetector%20problem.EML/macCore.patch>  modifies the src/libCom/macLib/macCore.c file to fix this issue. A more extensive patch can be found on the Launchpad bug #551909 page. 

Mark

 


________________________________

From: [email protected] on behalf of John Dobbins
Sent: Thu 7/15/2010 3:44 PM
To: EPICS Techtalk
Subject: areaDetector problem



I am using areaDetector with Flea2 Firewire cameras on WindowsXP.

I can create a camera driver (WinFDC_Config) and pipe the output through a chain of plugins:

   camera_driver -> process-> overlay -> NDStdArray -> stats

and everything works.  I next tried to create an IOC with two cameras and found

   {camera_driver_1, camera_driver_2} -> process

works, where process can receive output from one camera or the other.  However

   {camera_driver_1, camera_driver_2} -> process -> overlay

crashes. In particular the IOC crashes on start up at the last of these lines:

   NDOverlayConfigure("OVER1", $(QSIZE), 0, "PROC1", 0, 8, -1, -1)
   dbLoadRecords("$(AREA_DETECTOR)/ADApp/Db/NDPluginBase.template",...
   dbLoadRecords("$(AREA_DETECTOR)/ADApp/Db/NDOverlay.template"
   dbLoadRecords("$(AREA_DETECTOR)/ADApp/Db/NDOverlayN.template", ...

I get an error message "myIOC.exe has encountered a problem and needs to close". If I omit the last line the IOC will start up. Note that these are the same db files that work in the single camera IOC.


I don't know how to proceed. Hoping someone can suggest a next step. Any wild guesses as to what might be a problem?


Regards,

John Dobbins
Lab for Elementary Particle Physics
Cornell University




Replies:
RE: areaDetector problem John Dobbins
References:
areaDetector problem John Dobbins

Navigate by Date:
Prev: Re: areaDetector problem John Hammonds
Next: devGpib problem Mark Rivers
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: areaDetector problem John Hammonds
Next: RE: areaDetector problem John Dobbins
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  <20102011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 02 Sep 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·