Andrea-Fox / peopleCounter

Code for a cheap people counter based on VL53L1X sensor and ESP32/8266
The Unlicense
95 stars 27 forks source link

Several updates #13

Closed noxhirsch closed 3 years ago

noxhirsch commented 3 years ago

I added some functions for my sensors - feel free to take what you like and discard what you dislike

  1. With the new variable update_raw_measurements the sending of raw measurements can be disabled to save traffic and system resources. I'd suggest only enabling it for debugging - especially with multiple sensors this a lot of data which needs to get processed.
  2. threshold_percentage is a new variable to quickly change the threshold. I had a little better experience with 40 - especially with two people relatively close together.
  3. The biggest change is devicename and new MQTT topics. This makes it easier to maintain multiple sensors easier (in my case, I'll soon have 7). With this variable you can change the middle part of the MQTT topics and set a ArduinoOTA hostname. The topics now all start with "people_counter" - then comes the devicename and then a more descriptive last part.
Andrea-Fox commented 3 years ago

I was coding the exact same thing you proposed in the first two points, so I completely agree with you on those. I also really like the idea of having a devicename. Thank you for the suggestions and I really appreciate your work