motor-rpm-measurement-using-hall-effect-sensor
place one small magnet on the hub of the motor or any rotating part. place the hall effect sensor at about 1 to 2 mm distance from the magnet. tune the refsig value(usually =((max_raw value+min_raw value)/2)). ta da!