Smart Parking Solutions - IoT sensors space race

By Yury Birchenko, CTO Nwave

A $200 billion problem

Parking is a universal pain for drivers. The search for a vacant parking spot is a daily cause of stress and frustration for many, with city drivers spending 30% of their time looking for spaces. A recent report by INRIX quantified this pain by studying drivers’ parking behaviour and experience across 30 cities in the UK, US, and Germany.

A combined cost in wasted time, fuel, and carbon emissions to the economies of these three countries alone was estimated close to staggering $200 billion/year.

Smart parking IoT and AI based solutions hold the key to solving these and many other modern cities’ problems but getting all pieces of the puzzle together is not easy!

Smart Parking Systems Overview

So what exactly is smart parking system? At the foundation of any smart parking system lies the technical solution that provides real-time parking space availability data. In today’s smart city projects there quite a few technological approaches used to collect this data, alleviate the urban traffic crunch and make on-street parking more efficient and better managed.

However, the most widely adopted types of smart parking IoT systems include:

  1. cameras
  2. overhead radars/lidars
  3. ground sensors

As always, each technology has its advantages and disadvantages and the optimal choice may depend on a particular project requirements.

Cameras powered by recent progress in computer vision and AI these days seem like the most straightforward approach. One of the main advantages of a smart car parking system cameras is the possibility to monitor many parking spaces at once. This is very compelling and indeed works quite well in test and demo environments where computer vision models are trained, optimized (explicitly or implicitly) for a particular setting and vehicle types. The real world deployments with a much greater variety of viewing angles, lighting conditions, vehicle types and weather conditions bring a necessity of further customisations. And this is where additional challenges are coming into play.

Camera-based smart parking systems can be further classified into two types:

  1. Cloud-based/server processing: streaming the video or series of snapshots to the cloud or on-premise server.
  2. On-board processing: capable of executing vehicle recognition locally on only sending the parking events and limited number of images when required

First approach with a much higher operating cost is initially required to train the model for a particular setting but in order to switch to lower operating cost more compute power is required at the edge. So, for a successful project take off, the solution needs to start with high operating costs (Internet bills, data labelling) and high capital expenditure (hardware, installation, planning permits).

As a result of these limitations, camera-based solutions can only be realistically considered as a viable approach in relatively large open surface lots (supermarket or airport parking).

Overhead radars/lidars - measure radio signal or laser light reflections to detect the presence of a vehicle. This method has a great accuracy in the near range (up to ~7m) but the accuracy greatly decreases with the distance increase and angle of arrival of reflected signal. As a result, mains powered sensor installed on a lamp post can only reliably cover 4-5 parking spots.

Ground sensors - battery-powered wireless sensors are placed on each parking space is arguably the most direct and universal approach to monitor the occupancy. The detection method is not affected by line of sight interference and does not depend on street furniture availability. Single-aim engineering design, close proximity to detected object, 1-1 detection approach allows achieving high enough accuracy and up to 10 years battery life makes the total cost of ownership quite reasonable.

Note: there were multiple attempts to harness mobile phones’ IMU sensors to estimate parking occupancy on a particular street but they all failed due to unacceptably low accuracy.

Smart parking systems costs and accuracy benchmarking

Fig.1: Smart parking systems costs and accuracy benchmarking

The smart parking market is still in the nascent state mainly due to the remaining gap between required costs/precision system requirements and what current IoT solutions have to offer. The ground mounted vehicle detection sensors hold the highest promise to close that gap by combining the latest sensing, wireless connectivity and cloud computing technologies.

In-Ground Vehicle Detection Sensor Mix

These sensors can be based on a variety of sensing technologies, the most commonly used are magnetometer, infrared, ultrasonic, and radar.

Let’s consider the advantages and disadvantages of a car parking system using in-ground sensing method.


Our planet Earth provides a very uniform magnetic field over its surface. A magnetometer is simply a digital compass helping to measure this field direction and magnitude and understand object-orientation. The exponential growth of mobile phones, tablets, wearables, AR and VR sets gave a huge boost to the magnetometer sensor market with annual production volumes measured in hundreds of millions.

The good news for IoT and smart parking systems engineers is that a ferrous (containing iron) object, like a vehicle, creates a short-range distortion of this field which can be measured. The magnitude of this distortion depends on the type of the ferrous alloy, the size of the object and the distance to the sensor.

As illustrated in the picture below, the deviations are much stronger around the engine and the wheels of a car.

Principles of magnetic sensor vehicle detection

Fig 2: Principles of magnetic sensor vehicle detection

With a wide variety of sensors providing 3-axis magnetic field vector measurements detecting a vehicle seems to be quite a straightforward task: make some experimentation with detection thresholds, adjust, do more tests, fine-tune your algorithms and the smart parking sensor is ready.

Unfortunately, there are a number of disadvantages of such parking occupancy sensors that add considerable complexity to this initially simple approach. First and foremost, after some experimentation with your “friends and family and colleagues fleet” you may realize that different vehicles distort Earth’s magnetic field in different ways. Although cars may look visually similar, some of them may create strong magnetic field deviation detectable more than 1m away from the car. However, as can be seen in the illustration above, there are spots within the vehicle projection on the road surface where the distortion is minimal.

If you add to your experiments a wider variety of vehicles: SUVs, vans, buses, trucks, Smarts, Minies, sports cars, retro cars you will see that simple algorithms often do not work and your school programming project adds more lines of code and moving fast towards a PhD level in statistics rather than Masters thesis with some logistics regression and classification trees.

It might be great to develop more computationally complex detection algorithms when you are not power constrained and data is virtually free. But in the case of battery operated smart parking sensor, more advanced statistical models and more data mean more power consumption, higher sensor sampling rates and much more compute time on the microprocessor. So much shorter battery life is going to be one of the major disadvantages of a smart car parking sensors based solely on magnetometer.

If this does not stop you and you are betting on Moore’s law and improvements in magnetic sensor efficiencies - there is actually a small baby elephant in the room that may fill most of the room in 3-5 years. The name of the elephant is EV.

The new electric vehicles that are going to make our cities cleaner and quieter are also so light and efficiently made that they hardly move the needle of the magnetometer. With targeted smart parking sensor lifespan of 7-8 years, this is not looking too smart!

Let’s summarize the advantages and disadvantages of a smart car parking system using magnetic detection before we move on to the next type of the sensor.

Magnetometer pros:

  • Low current drain, varies depending on the model but generally within 15uA per 1Hz sampling rate.
  • High sensitivity and high dynamic range, some sensors have 16 bit ADCs.
  • Extremely small PCB board footprint, some can be as tiny as 1mm2.
  • Low BOM cost, generally in the range of $1 in volume.
  • Massive and competitive market, a wide selection of sensors with similar characteristics, low risk of receiving a heartbreaking end of life notice.

Magnetometer cons:

  • Difficulties in detecting SUVs, trucks, vans and other types of vehicles with high clearance.
  • Even a standard sedan car can have “blind spots” in terms of magnetic field distortion.
  • Prone to interference from electric power lines, underground trains and other EMI sources.
  • EVs made of non-ferrous metals and carbon fiber may be much harder to detect, especially in the presence of EMI noise.

Infra-red ranging sensor

Again quite popular sensors in modern electronic appliances: most commonly used in cameras (auto-focus), drones, gaming controllers, tablets, laptops and other applications where distance to an object, particular gestures or movement patterns need to be detected.

There are two general classes of infra-red (IR) ranging sensors:

  1. Reflected Intensity - simpler and more conventional modules consisting of LED emitter and photocell measuring a proportion of reflected light by the object. The closer the object the stronger the reflected signal and vice versa.
  2. Time-of-Flight (ToF) - builds on the above principle but uses a much more coherently operated pair of a laser and reflected light sensor capable of measuring the time of reflected light travel (see picture below).
Principles of ToF infra-red ranging sensor operation

Fig 3: Principles of ToF infra-red ranging sensor operation

It can easily be seen that both sensors can add a lot to the magnetometer accuracy equation - they couldn't care less whether it is going to be a non-iron EV or 8 cylinder last century classics. Both reflect light equally well.

The ToF sensor has a substantial advantage of course: as it measures an absolute distance the light has travelled, the results do not fluctuate with reflective properties of the target object. For our application, it means for example, that a little bit of dust on the protective glass will not generate a false positive of vehicle parking.

Just imagine how accurate these sensors have to be measuring 1cm distance - it takes only 67 picoseconds for the light round trip!

The ToF sensor also has much better ambient light rejection and cover glass cross-talk compensation. For those reasons, it makes a better choice for augmenting the magnetometer reading data in our parking space occupancy detection accuracy race.

But as often happens, everything comes at a price. Let’s summarize the pros and cons of ToF IR sensor.

ToF IR sensor pros:

  • Not sensitive to target object material - can measure the distance to objects with reflective indexes starting from 1%.
  • Ambient light rejection.
  • Cover-glass cross talk compensation.
  • Long sensing range (up to 3m) can detect high clearance vehicles.

ToF IR sensor cons:

  • Much higher current drain - approximately 2mA at 10Hz sampling rate (20x magnetometer consumption).
  • Higher footprint 5x3m which can be further increased for additional crosstalk compensation.
  • Approximately 3x more expensive than a magnetometer.
  • Narrow emitted beam may be reflected in unpredictable patterns as the bottom of the car is far from flat.
  • But most importantly, it is very sensitive to any optical obstruction: imagine a tree leaf in the autumn or light snow in the winter can make the sensor “temporarily blind”.

Ultrasonic ranging sensors

The sensor uses the same time-of-flight method as IR but the emitter sends ultrasound waves in (40-60KHz range) instead of photons. The most widespread use of the sensor is, of course, parking assistance systems in modern cars: the sensors are affixed in rear and front bumpers and help you park by signaling proximity to obstructions in the short range.

Ultrasonic ranging sensors

ToF Ultrasonic sensor pros:

  • Wider emitter beam than IR sensors which makes the measurement more integral and less prone to random reflections errors.

ToF Ultrasonic sensor cons:

  • Does not operate well under a cover plate, the emitter needs to have “open-air” view on the target. This exposure creates a risk of mechanical damage in case of in-ground parking occupancy sensor.
  • Extremely power hungry: 10-30mA at 5-12V.
  • Much bigger mechanical dimensions and higher current drain makes thin surface-mount sensor design particularly challenging - casing needs to accommodate quite a big emitter and receiver plus larger battery pack.

Radar ranging sensor

Historically radars came to use in extremely long-range sensing applications, particularly air and naval defense systems and aviation. With subsequent miniaturisation, performance improvement and cost reductions radars started to be applied in a much wider range of use cases.

Radar utilizes the same ToF principle but with radio waves rather than sound waves or photons (light). The radar wavelength is generally a balance between a target object size and distance to the object. In the case of in-ground sensor-based smart parking system, radars must be at least 15GHz frequency (2cm wavelength) to be able to measure reflection from a low clearance vehicle.

Generally speaking, radar shares most of the pros and cons of IR ToF sensor over magnetometer but there are a few differentiating points.

Radar ranging advantages over IR ToF sensors:

  • With a lower frequency of 15-20GHz, these sensors may be less sensitive to some thin obstructions and may work under thin ~2cm snow cover.
  • Wider beam - less prone to random reflections problem of IR.

Radar disadvantages over IR ToF sensors:

  • More expensive sensor and may require special high-frequency circuit design knowledge.
  • Radar signal processing requires much more MCU horsepower, forget about Cortex-M0/M3s, you are going to need Cortex-M4 with native floating-point support and higher clock rates.

Sensor selection roundup

If you are not living in an evergreen tropical environment and have proper autumn and winter our advice would be to go with a combination of a magnetometer and radar. You can use a more power-efficient magnetometer for permanent scanning at a 1-10Hz frequency and turn on the radar to verify the parking event.

If you are not concerned by snow, leaves and other optical obstructions you can as well use IR ToF sensor.

We could not cover absolutely all edge cases and nuances of vehicle detection. Obviously. the best way to prove that you have solved the problem is to validate it via real-life tests and observations. Now here a question for you: how many tests do you need to prove your detection is 99% accurate?

You may find an answer in our blog on statistics around vehicle detection sensors accuracy.