diff --git a/sis8300bcmApp/src/sis8300bcm.cpp b/sis8300bcmApp/src/sis8300bcm.cpp
index 7da1cf53170029256d5a9f55d51e772c178978b1..de3bb249b1408eb69620860b6304be1aa782cca4 100644
--- a/sis8300bcmApp/src/sis8300bcm.cpp
+++ b/sis8300bcmApp/src/sis8300bcm.cpp
@@ -1276,11 +1276,8 @@ int sis8300bcm::deviceDone()
             getDoubleParam(addr, BCMAcctAutoFlatTopStart, &autoFlattopStart);
             getDoubleParam(addr, BCMAcctAutoFlatTopEnd, &autoFlattopEnd);
             getDoubleParam(addr, BCMAcctTriggerWidth, &triggerWidth);
-            printf("Channel %d auto flattop start %f\n", addr, autoFlattopStart);
-            printf("Channel %d auto flattop end   %f\n", addr, autoFlattopEnd);
-            printf("Channel %d auto trigger width %f\n", addr, triggerWidth);
-            // calculate the average current over automatic flattop
-            ret = sis8300drvbcm_get_channel_flattop_current(mDeviceHandle, addr, triggerWidth - autoFlattopStart + autoFlattopEnd, flattopCharge, &doubleValue);
+            // calculate the average current over automatic flattop (window in ms)
+            ret = sis8300drvbcm_get_channel_flattop_current(mDeviceHandle, addr, triggerWidth - (autoFlattopStart + autoFlattopEnd)/10e6, flattopCharge, &doubleValue);
             if (ret) {
                 asynPrintError(pasynUserSelf, "sis8300drvbcm_get_channel_flattop_current auto returned %d", ret);
                 return ret;