[0015]In a further embodiment of the invention, the sensor elements are resistance-changing magnetic sensor elements. Such sensor elements employ resistance changes caused by outer portions of the magnetic field of the permanent magnet. Such resistance changes are simple to detect on the basis of resulting current changes and can readily be further processed. For example, this can be realized by using a Wheatstone bridge. The magnetic sensor elements which change their resistance have a greater sensitivity than Hall-sensors.