Magnetic sensors for nanotesla detection using planar Hall effect