were is the speed sensor for the speedometer located? how do you replace it? on 1991 Volvo 940

The speedometer work's sometimes and lately has not been working at all.

Asked by for the 1991 Volvo 940
it's in the rear differential housing.
Sorry bretb but I think U meant to say the unit sits on the outside of the differential housing and not in it although the sensor part of the unit enters the diff. Dont mean to be picky but I am sure U wouldn't want Hutchinson to give up on having a go to fix it himself
I was a bit hasty with my answer, thanks for the clarification.