The invention discloses a method for improving accuracy of a geomagnetic parking stall
detector. The method includes: by collecting sample data of a background
magnetic field, calculating and recording
benchmark data of the background
magnetic field as
reference standards; respectively determining calculated weight values in three axial directions according to stability of the sample data, collected by a triaxial
magnetoresistive sensor, of the background
magnetic field in three axial directions; turning off a
wireless communication module when reading data of the triaxial
magnetoresistive sensor, and storing the data into a buffer
queue; calculating magnetic field changes for the data in the buffer
queue, performing median filtering, and performing parking stall state determination according to changes of the magnetic
field data; calibrating the
benchmark data of the background magnetic field under the condition of free parking stalls; uploading the parking stall information and battery level information through the
wireless communication module prior to entering the
sleep state; waking through an RTC (real-time
clock) in a timed manner, continuing executing from the step 3, and so on. Compared with the prior art, the method has the advantages that influence caused by temperature drift compensation and
time drift of the sensor on parking stall determination accuracy can be restrained effectively, and the method is higher in adaptability, lower in cost and the like.