Traditionally diphosphorus can be generated by heating white phosphorus at 1100 kelvins. The compound attracted attention in 2006 when a new method for its synthesis at milder temperatures emerged [1].
This method is a variation on nitrogen expulsion in azides with formation of a nitrene. The synthesis of the diphosphorus precursor consists of reacting a terminal niobiumphosphide with a chloroiminophosphane:
The same imido compound also forms when the thermolysis is performed in toluene but then the fate of diphosphorus is unknown.
References
^Triple-Bond Reactivity of Diphosphorus Molecules Nicholas A. Piro, Joshua S. Figueroa, Jessica T. McKellar, Christopher C. Cummins Science 1 September 2006:Vol. 313. no. 5791, pp. 1276 - 1279 10.1126/science.1129630