Okay, so I’ve been messing around with this idea of tracking how many people come into a space, like a store or something, and then also trying to get them to, you know, engage somehow. So, I started looking into foot traffic sensors with some extra features.

Getting Started

First, I did a bunch of digging online. Just trying to figure out what kinds of sensors are even out there. There’s a lot! Some just count people, some try to figure out if it’s the same person coming back, and some even have little screens or something to try and get people’s attention.

The Hardware

I decided to keep things on low level,I grabbed a few different types of sensors to play with:

  • Basic infrared beam sensors: These are the super simple ones. You put one part on one side of a doorway and the other part on the other side. When someone walks through, they break the beam, and it counts them.
  • Thermal sensors: the solution provided by the thermal sensors offer much more detailed counting and tracking solution.
  • Cameras with people-counting software:This set up is more complex, using cameras with video processing capabilities.

Setting Things Up

I started with the infrared sensors because they seemed the easiest. I just taped them up to a doorway in my house (my family thought I was nuts). I hooked them up to a little microcontroller,I chose Raspberry Pi.

Messy Code and Counting

Wrote some code to count every time the beam was broken. It was super basic at first, just adding 1 to a number every time. Of course, I ran into problems. Like, if someone walked in and then right back out, it would count them twice. So, I had to mess with the code to try and account for that.

I used python to connect and get data from those sensors,for the thermal sensors,it was tricky to distinguish multiple individuals close together,leading to inaccurate counts under crowded * also cameras,despite the cameras being effective in counting,Integrating the hardware was complicated,and there were also unexpected difficulties processing the video data in real-time, requiring significant computational resources.

Adding the “Engagement” Part

Then came the tricky part – trying to get people to actually do something. I had a few ideas:

  • A screen that shows the count: I thought maybe people would be curious to see how many others had been there.
  • A QR code: Maybe I could get them to scan a QR code to see some kind of offer or something.
  • A little game: I even thought about making a super simple game that people could play on a screen for a second as they walked in.

What I Learned (So Far)

This is still a work in progress, but I’ve already learned a bunch:

  • Counting people is harder than it looks: You have to deal with people going in and out, people standing in the doorway, all kinds of stuff.
  • Getting people to engage is even harder: Just putting something there doesn’t mean people will use it.
  • Simple is probably better: The more complicated I made it, the more problems I ran into.
  • The infrared sensor beam sensors were straightforward to install and use.but they could only provide basic counts without distinguishing entry and exit directions.

I’m still messing around with this, but it’s been a fun project. I’m thinking about trying to use some machine learning stuff to see if I can get better at counting people and maybe even figuring out if they’re, you know, interested in whatever I’m trying to get them to engage with. We’ll see how that goes!