Collisional excitation of H2 by grains in C-type shocks