Yup but POT 'Should' do the job... As output first to charge/discharge the capacitor, then set as input to evaluate the RC plah plah.

If the POT/Capacitors value match is not good AND the 'way to use them' is not good... of course results will be bad.