Post APmlPfj1aG7q0MxbQO by mattdm@fosstodon.org
 (DIR) More posts by mattdm@fosstodon.org
 (DIR) Post #APmlPeFv2zFXRoKqQ4 by mattdm@fosstodon.org
       2022-11-20T01:50:09Z
       
       0 likes, 0 repeats
       
       Feeling pleased with myself: used a time-of-flight laser module (https://www.adafruit.com/product/5425) and an ESP32 board to make a MQTT occupancy sensor for my desk.Unlike with a traditional motion sensor, won't turn the lights of because you've been sitting in a call too long.
       
 (DIR) Post #APmlPep0wVK3Ceks7c by mattdm@fosstodon.org
       2022-11-20T01:54:39Z
       
       0 likes, 0 repeats
       
       It has a field of view of about 18°, so I'm considering making a version that has 3 sensors pointed different ways, and replacing most of the IR motion detectors in the house.Faster to respond, more accurate, more precise (if you need that), and less family complaining about lights going off on them. :)
       
 (DIR) Post #APmlPfKZ3CYkmVW4Ia by mattdm@fosstodon.org
       2022-11-20T01:55:43Z
       
       0 likes, 0 repeats
       
       And won't be tripped by the pets because I can aim it at people-height.I do need to write something that determines the "ambient" distance automatically, rather than having hard-coded.
       
 (DIR) Post #APmlPfj1aG7q0MxbQO by mattdm@fosstodon.org
       2022-11-20T01:57:40Z
       
       0 likes, 0 repeats
       
       Also need to 3d print a case so it does not look exactly like a low-budget TV show bomb.
       
 (DIR) Post #APmlPg6m9x7lC24ZRg by pro@mu.zaitcev.nu
       2022-11-20T05:42:40.458318Z
       
       0 likes, 0 repeats
       
       @mattdm Does everything need to be 3D printed these days? Just go to Michael's and buy a small box.
       
 (DIR) Post #APo4RSZNYkP84OyUSW by mattdm@fosstodon.org
       2022-11-20T15:58:54Z
       
       0 likes, 0 repeats
       
       @proI actually _have_ a small box (from Michael's, even!) that I plan to use. But I'd like to print a support piece that would hold the sensor in the right place, with protrusions to match the holes in the board.
       
 (DIR) Post #APo4RT9tMzbxte3eN6 by pro@mu.zaitcev.nu
       2022-11-20T20:50:37.448370Z
       
       0 likes, 0 repeats
       
       @mattdm Good point. Obviously you can make a bespoke box with 3D.