You actually the speed sensor is part of the speedo head.

I can't tell what you replaced, but it sounds like you replaced the speedo gear. Did the replacement have the same number of teeth? If not, then that is your problem.

You also need to figure out why the old one disintegrated. They usually don't just do that.

Michael