We report a novel photonic scheme to generate background-free phase-coded microwave pulses with elimination of power fading by cascading a dual-polarization dual-parallel Mach–Zehnder modulator (DP-DPMZM) and a polarization modulator (PolM). The DP-DPMZM is driven by a radio frequency (RF) signal to generate two first-order optical sidebands with an orthogonal polarization state, while the PolM is driven by a three-level electrical coding signal. By properly adjusting the polarization state, a series of background-free frequency-doubled phase-coded microwave pulses can be generated after optical-to-electrical conversion. Benefiting from the carrier-suppressed single-sideband (CS-SSB) modulation, the proposed signal generator can suppress the chromatic-dispersion-induced power-fading effect, which has excellent potential for long-distance fiber transmission. In addition, the system can directly generate phase-coded microwave signals in pulse mode by truncating continuous wave (CW) microwave signals. Moreover, the microwave signal generator has wideband tunability since no optical filter is involved in our scheme. The proposed method was theoretically analyzed and experimentally verified. Phase-coded microwave pulses centered at 14 GHz and 19.2 GHz with a bit rate of 0.5 Gb/s were successfully generated.