6 ms·
Automatically Light Up a Sign When Your Webcam Is in Use
- nyir 5y agoThe top answer on SO that I found (https://unix.stackexchange.com/a/344463/91434 https://unix.stackexchange.com/a/344463/91434) also uses this way of determining whether the device is being used - is that really the best way, or is there anything to actually query the device? E.g. my webcam has a light already that is only active when images are being captured(?), shouldn't it be possible to query that bit of information directly?
- digitalsushi 5y agoIn the Star Trek sense, anything is possible; if the people making the device had desired to expose the state of the LED to software, it would be very easy for us end users (including people writing a little shell script). But there's no reason to expect that just because the LED is active, they made it easy to sample its state. It's a closed system, like a restaurant kitchen. Determining whether the chef is wearing a hat by examining the plates coming out may be possible with enough plates and time, but the answer sufficiently becomes 'no' for practical purposes.
- nixpulvis 5y agoAll external observables of my software running devices really should have a way to be observed programmatically.
- KMnO4 5y agoI would be worried if there was a way to query the webcam LED. Ideally you want it controlled by the hardware: if power is going to the camera, power the light. If it’s accessible via software, there’s the possibility that it can be controlled with software as well.
- InitialLastName 5y agoPresumably there's a command that drives the common control point. If there's a pin (or more likely, a USB control transfer controlling a pin) that controls the power state of the webcam (and thus the LED), you need to track the state of the pin anyway.
- nemetroid 5y agoTo me, asking the operating system's video abstraction layer seems cleaner than asking the device's binary blob.
- nixpulvis 5y agoBut will less confidence.
- mleo 5y agoFor meetings I now have 3 effects. 1. At 1 minute to meeting start the meeting subject is announced on Sonos speakers to awake me from focus. This uses Node to query my Office365 calendar. 2. Two Pi Zeros with LED hats light up during Zoom meetings. This uses the Zoom APIs to receive webhook events that are published to MQTT. The PIs listen to MQTT and adjust the light colors. 3. I have a color changing Pac-Man Ghost light behind me that turns off during video meetings. In this case, my home automation system listens to MQTT events and turns the plug off and on. Extra. I used the Node/Office365 calendar querying to light up PI LEDs for wife’s meetings and kid’s meetings. I didn’t feel like trying to deal with another company’s Teams API or school’s Zoom settings. The kids meetings were also announced over Sonos in the area of home they were working. It worked well enough we didn’t have to look after them every time class started.
- robbles 5y agoIs there a similar way of detecting the web cam in use on macOS?
- hammock 5y agoMy MacBook has a built-in green LED right next to the camera that turns on when the camera is on.
- giglamesh 5y agoI had the same thought and then read the article. Turns out this is about telling other people in a shared space - such as a work from home situation - that you are in a meeting. Which would not work for me as I generally keep the camera off to save bandwidth and the last remaining shreds of my sanity.
- e40 5y agoThere has to be, as Micro Snitch tells me when it is. EDIT: on my iMac M1 the built-in camera and mic are not detectable by MS. So, maybe not... EDIT2: https://obdev.at/products/microsnitch/releasenotes.html https://obdev.at/products/microsnitch/releasenotes.html It's a bug in Big Sur, so hopefully it will be fixed and MS will work again.
- wvaughan 5y agoI was able to make something similar using Home Assistant to get the webcam status on the mac - https://willvaughan.design/making-an-on-air-light-for-my-home-office https://willvaughan.design/making-an-on-air-light-for-my-hom...
- stevenbedrick 5y agoTake a look at the code for Objective-See’s “OverSight” utility; it is a good example of how to detect AV events system-wide. It’s also a really great app… https://objective-see.com/products/oversight.html https://objective-see.com/products/oversight.html
- 5y ago
- vernie 5y agoIs there a macOS equivalent of this query?
- jhenkens 5y agoSeems so much effort was spent on the lighting of a sign. Put it on a smart switch with a spare USB power adapter - I'm sure the author has a dozen - and control it via rest, MQTT, HomeAssistant, anything. Pros: Not physically tied to PC. Cons: Another wifi device, unless you've already got a z-wave/zigbee stack setup you can piggyback on.
- aksss 5y agoI switched over to using a camcorder with a power switch and electric lens cover. It sits on small tripod behind my monitors, has far better color correction/white balance controls than most webcams out there that I’m aware of. But it makes it quite evident when it’s in use vs not, as the physical lens cover is electronically tied to its power status (automatically shuts when off) and the device is not present to the OS at all when device is powered off. So far zero problems with using it and OBS when flipping its power state back and forth multiple times in a day. Teams/Windows handles the presence/absence gracefully and quickly. It’s also nice to have an IR remote for it, though I rarely use it. I think the only thing to watch out for in this set up - that is potentially inherently worse than a webcam - is latency of video signal. You get what you pay for in cameras, so a cheap camcorder outputting over hdmi may introduce unbearable latency in video signal.
- jrockway 5y agoI use a DSLR with a lens cap on it when not in calls. I also enjoy the light sensitivity; ISO 6400 looks fine in Zoom meetings, and it means I can sit here in total darkness which I enjoy.
- stragies 5y agoIt's a real shame, that USB-Hub manufacturers do not in general implement the Per-Port-Power-Control part of the spec. That would be so useful to controlling 5V/12V powered devices. With QC3.0 to barrel-jack-12V adapters a USB-HUB with PPPC(and QC3) would be a godsend.
- rcarmo 5y agoI would suggest Zigbee LED strips. Cheap, can be made as unobtrusive as needed, etc.
- monkeydust 5y agoThis is great, but all the fancy tech signage in the world won't stop by 2 year old trying to barge in at the worst time possible.