Sensor in air gap of drive, detect directly speed or position