EPICS Home

Experimental Physics and Industrial Control System


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

Subject: RE: Question for areaDetector overlay and file plugin
From: "Blomley, Edmund \(IBPT\) via Tech-talk" <tech-talk at aps.anl.gov>
To: Jörn Dreyer <j.dreyer at hzdr.de>, "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>
Date: Wed, 18 Jun 2025 10:55:11 +0000
Hey Jörn,

	> Looking at the implementation reveals that you have to give the filename pattern exactly as shown on the GUI. Otherwise the code will crash.

I was wondering if there are actually other options as the one shown in the GUI and if not: why even try to provide a setting. I assume it was foreseen to be more flexible at some point?

	> If you want to have the date and time included in your filename, the simplest way would be to create your own plugin that overwrites NDPluginFile::openFileBase. This function will be called for each file to be opened. It will call the openFile function of the file plugin (e.g. HDF5File).

Thanks for this hint! I looked at that part of the code trying to understand where and how the file name is exactly constructed and I think maybe the best approach would be to patch  NDPluginFile::attrFileNameSet()?
Here just before this line https://github.com/areaDetector/ADCore/blob/84da95763e24ac2a76b37b99f2276b58afc71e59/ADApp/pluginSrc/NDPluginFile.cpp#L603 
There I could check the content of the prefix looking for the "usual" time syntax ("%x") and replace that?


	> Just adding another button is not fail save! What if you forget to press the button before starting to write? What if you write files in auto increment mode?

Yeah I am aware that this would obviously be bad design and fail in multiple scenarios. Just need to balance this against my basically non-existing c programming experience to come up with a solution 😉
But now of course I hope I will figure out a solution with a local patch to the FilePlugin.

Cheers
eddy


Attachment: smime.p7s
Description: S/MIME cryptographic signature


Replies:
Re: Question for areaDetector overlay and file plugin Mark Rivers via Tech-talk
References:
Question for areaDetector overlay and file plugin Blomley, Edmund (IBPT) via Tech-talk
Re: Question for areaDetector overlay and file plugin Jörn Dreyer via Tech-talk

Navigate by Date:
Prev: Re: Question for areaDetector overlay and file plugin Jörn Dreyer via Tech-talk
Next: Re: Question for areaDetector overlay and file plugin Mark Rivers via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  <2025
Navigate by Thread:
Prev: Re: Question for areaDetector overlay and file plugin Jörn Dreyer via Tech-talk
Next: Re: Question for areaDetector overlay and file plugin Mark Rivers via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  <2025