Charge-exchange collisions and radio-frequency excitation combine to give peaks in the ion energy distribution measured at the ground electrode of an argon plasma in a capacitive reactor. These peaks are used as a diagnostic to reconstruct the profile of the time-averaged potential in the sheath. Particle-In-Cell simulations show that the method is accurate. The method is applied to investigate the sheath thickness as a function of excitation frequency at constant plasma power. The time-averaged potential is found to be parabolic in both experimental measurements and numerical simulation. (author) 6 figs., 1 tab., 15 refs.