Earlier quoted context omitted.
If you want to get really spicy, you can use two antennas and an SDR to compute angle of arrival using nothing but a BLE advertisement's data . This is different from BLE AoA as it doesn't require a cooperative transmitter.
If you want to get really, really spicy, use three devices/antennas and you can roughly track in three-dimensional space.
Building an occupancy sensor with a $5 ESP32 and a serverless DB
191–200 of 221 posts
Re: Building an occupancy sensor with a $5 ESP32 and a serverless DB
#192Re: Building an occupancy sensor with a $5 ESP32 and a serverless DB
#193While I don’t discourage learning a new language the immediate toss aside of rust on esp32 was perplexing. It sounds like a lot of the memory issues would have been mitigated by sticking with a language better understood. Rust’s esp32c3 support is pretty good IMO, that’s all I use. Writing in C++ makes me feel dirty in ways that even COBOL doesn’t. I also think I would have implemented presence by TTL, updating the T…
The hash map was definitely not robust enough, that’s why I ultimately switched back to the default behavior and increased the memory available on the board! Also, I am a Rust fanatic. I do nearly everything in it! I gave a talk on it at our last hackathon! I even wear a Rust t-shirt regularly! So rest assured I will be exploring my options with Rust. I would love to get rid of my dependence on Arduino. But C++ was e…
Whether I'll use C++ or Rust for my next project depends on which one I can first get working on this board with the standard toolchain (GCC and Rustc respectively)
Re: Building an occupancy sensor with a $5 ESP32 and a serverless DB
#194Earlier quoted context omitted.
I wonder what the "rules" are for things like tracking beacons. They're being broadcast, and they're almost certainly collected without consent everywhere we go. I happen to live at a junction where my home is regularly surrounded by large numbers of Bluetooth devices; I had considered setting up a BLE tracker purely for "fun" to see what I could collect and discern from the data. For example, one thing I'm certain o…
> So a hidden industry of third-party location-marketing firms has proliferated in response. These companies take their beacon tracking code and bundle it into a toolkit developers can use. The makers of many popular apps, such as those for news or weather updates, insert these toolkits into their apps > Location marketing aims to understand “online-offline attribution.” If a Starbucks coffee ad is sent to your email…
Almost all devices you’re carrying with you will regularly rotate the ID they transmit in order to avoid correlation, so reading those beacons in a location can’t really be used for much beyond rough numbers of devices.
Re: Building an occupancy sensor with a $5 ESP32 and a serverless DB
#195> not losing momentum in a nerd snipe like this is CRITICAL This line got me laughing! My nerd brain has tried so many times to convince me to splurge money with this exact line!
It's funny, but it's also true. There are definitely times when I'm more "in the mood" for projects; In the winter particularly, I work more on my electronic projects, and do more gaming (my Gaming "season" just started again last week). Of course the dramatic shift from "what do I feel like doing today" to "what am I in the mood for / have time for this season" has a lot to do with me being older and having children…
As long as children are smaller even things like scheduling time for your projects don't work very well. Usually because unexpected things happen that need to be handled. Sickness, children waking up early or taking longer to go to sleep, etc..
Re: Building an occupancy sensor with a $5 ESP32 and a serverless DB
#196Earlier quoted context omitted.
This is correct, I thought it wasn't and was going crazy trying to debug my Pi 3 resetting my 3D printer every time, with any of ten power supplies I tried, including a configurable bench PSU. I switched to the official Pi PSU after someone said "trust me on this" online, and yep, zero issues in all the years since.
It's voltage for Pi 3. They forgot to account for voltage drop due to protection or something. Official as well as third-party Pi 3 specific adapters are rated at 5.1V to mitigate that problem.
Re: Building an occupancy sensor with a $5 ESP32 and a serverless DB
#197> Linux Bluetooth is incredibly painful to handle in a headless way. Binding to DBus requires cross-compiler magic and not even Cross was getting me out of it. That was my experience as well. I was doing something different so ultimately I just decided I'd put both the devices on the same WiFi network and then scan for "pi.local". Do wish I knew how all those other crates work though where it crashes at runtime if yo…
Home assistant does headless bt presence detection in ~200 lines of python I think the author had a painful experience because they wanted to do embedded and had to interface at a much lower level, where it's a long ago solved problem in higher level languages. Considering the tracker ended up in their door next to their computer, they could have stuck with the rpi that ran python and been fine https://github.com/hom…
If I do the home assistant route and just copy my source code over to the raspi and build the binary there it all compiles+runs fine. Except for the part where I can't compile it locally and so I don't know of a build issue until its been transferred + built.
Re: Building an occupancy sensor with a $5 ESP32 and a serverless DB
#198Earlier quoted context omitted.
It’s definitely not a reliability issue, with the platform - ESP32 in general is very popular so it’s surely an issue with my usage. I’m fairly certain it’s just a cheap manufacturer issue I ran into. I bought essentially a no-name ESP32 at first and that’s the one that refused to last. Proper manufacturer solved that issue for me and now ESP32 works just fine. The raspberry pi actually never worked, largely because…
> I don’t think it’s a power issue as it’s getting 5V1A from a power outlet directly to USB-C into the device. It's not the total voltage/wattage the PSU can provide, but the voltage at the processor. The ESP's varying current draw notoriously causes too much noise and a lot of boards don't have large enough decoupling capacitors so the voltage drops too much and it glitches out. Also a warning that USB PSU's can ver…
Is this something you can eyeball to guess at quality?
Re: Building an occupancy sensor with a $5 ESP32 and a serverless DB
#199My alarm clock consists of an ESP32 and has a somewhat big LED-array connected to it (powered by a transistor), a buzzer and a PIR sensor. It doesn't show the time, but buzzes (and flashes) and takes care of slowly brightening the room, or at night slowly dimming it into darkness some time after all the lights have been turned off. One added benefit I discovered afterwards is that even though the AP is not between me…
Re: Building an occupancy sensor with a $5 ESP32 and a serverless DB
#200Earlier quoted context omitted.
If you want to get really spicy, you can use two antennas and an SDR to compute angle of arrival using nothing but a BLE advertisement's data . This is different from BLE AoA as it doesn't require a cooperative transmitter.
If you want to get really, really spicy, use three devices/antennas and you can roughly track in three-dimensional space.