Skip to content
Snippets Groups Projects
Commit 6ac8b343 authored by Christian Koernig's avatar Christian Koernig
Browse files

Changed Preset Real Time resolution

Now supports 10ms resolution instead of 100ms when using Real time
instead of acc time
parent bde955b7
No related branches found
No related tags found
No related merge requests found
...@@ -181,7 +181,7 @@ bool AmptekHardwareInterface::ClearSpectrum(){ ...@@ -181,7 +181,7 @@ bool AmptekHardwareInterface::ClearSpectrum(){
* or any other mode that temporarily blockes the MCA. Therefore, accumulation time is larger than the real measurement duration * or any other mode that temporarily blockes the MCA. Therefore, accumulation time is larger than the real measurement duration
* *
* @see SetPresetAccumulationTime, SetPresetRealTime, SetPresetCounts * @see SetPresetAccumulationTime, SetPresetRealTime, SetPresetCounts
* @param t accumulation time in seconds. Minimum is 0.1. If below zero, the accumulation time is not part of the stop condition during acquisition * @param t accumulation time in seconds. Minimum is 0.1s. If below or equal zero, the accumulation time is not part of the stop condition during acquisition
* @return true on success * @return true on success
* @return false on failure * @return false on failure
*/ */
...@@ -202,7 +202,7 @@ bool AmptekHardwareInterface::SetPresetAccumulationTime(double t){ ...@@ -202,7 +202,7 @@ bool AmptekHardwareInterface::SetPresetAccumulationTime(double t){
* @brief Set the real time for a measurement. The detector will stop automatically when the duration is reached * @brief Set the real time for a measurement. The detector will stop automatically when the duration is reached
* *
* @see SetPresetAccumulationTime, SetPresetRealTime, SetPresetCounts * @see SetPresetAccumulationTime, SetPresetRealTime, SetPresetCounts
* @param t real time in seconds. If below zero, the real time is not part of the stop condition during acquisition * @param t real time in seconds. Minimum is 10ms. If below or equal zero, the real time is not part of the stop condition during acquisition
* @return true on success * @return true on success
* @return false on failure * @return false on failure
*/ */
...@@ -210,7 +210,7 @@ bool AmptekHardwareInterface::SetPresetRealTime(double t){ ...@@ -210,7 +210,7 @@ bool AmptekHardwareInterface::SetPresetRealTime(double t){
std::stringstream cmd_stream; std::stringstream cmd_stream;
cmd_stream << "PRER="; cmd_stream << "PRER=";
if (t>0){ if (t>0){
cmd_stream << std::fixed << std::setprecision(1) << t; cmd_stream << std::fixed << std::setprecision(2) << t;
} }
else{ else{
cmd_stream << "OFF"; cmd_stream << "OFF";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment