High-frequency characterization of high-speed modulators and photodetectors in a link with low-speed photonic sampling