Which BMW?
The e30 uses a UAF2115 speedometer chip
http://users.tpg.com.au/cobra30/images/R31/uaf2115.pdf
Pin Function Connections
1 Flyback cathodes Connected pin 6, +V supply
2 Step M1 To odometer stepper motor
3 Pulse output To A pins on connectors (only)
4 Galv. curr set Resistor to ground, 75.0 ohm precision
5 Galvanometer out Stabilized w/ cap to +V
6 Positive supply +V supply, through diode+resistor
7 Current source diode clamped to ground, resistor
8 RC pulse width cap to ground, resistor voltage
9 Trigger input Resistor to ground, stabilized volt input
10 Stabilized +Vref To resistor
11 divider configure, connected to ground, div ratio 2^6
12 Step M2 To odometer stepper motor
This supplies the current, 1.15-1.5mA, to the magnetic reed switch at the differential. The switch is operated by the 9 vane magnetic chopper disk on the ring gear.
The speedometer constant is printed on the dial. It's something like "K=7784", which means 7784 pulses per mile (9 vanes * 864 revs per miles for the tires).