pulseIn is pure software, so unless pin mapping breaks down for some reason on the Mega, it ought to work on any pin.