added naive hard-iron effect compensation