We study the time-dependent Schrödinger equation with matrix-valued potential presenting a generic crossing of type B, I, J or K in Hagedorn's classification. We use two-scale Wigner measures for describing the Landau–Zener energy transfer which occurs at the crossing. In particular, in the case of multiplicity 2 eigenvalues, we calculate precisely the change of polarization at the crossing. Our method provides a unified framework in which codimension 2, 3 or 5 crossings can be discussed. We recover Hagedorn's result for wave packets, from Wigner measure point of view, and extend them to any data uniformly bounded in L2. The proof is based on a normal form theorem which reduces the problem to an operator-valued Landau–Zener formula.