I don't work in an office anymore either, but when I did (years ago), I would get constantly interrupted by people walking up to my desk and talking to me. I like talking to people but I also need uninterrupted focus time.
I made something similar with a blink USB light: https://blink1.thingm.com/ . I had a little sign that said "when it's red, I'm busy". And a keyboard shortcut to toggle it from red to green (it just ran a little bash script that invoked the blink CLI). It was duct-taped to my monitor so you could see it from far away.
It worked very well to prevent interruptions from other people walking up to my desk and chatting with me.
I had the same issue when I was in an office and we were getting close to a deadline, so everyone was constantly chatting about this and that to unblock themselves. It's understandable when the rhythm of the office gets to that point that people want answers now, but it would get to ridiculous levels where you couldn't focus for 10 minutes before somebody else came by with a question.
I never got to the point of having a USB light as a semaphore or anything like that, but I really wanted to find and hack a toy traffic light that would indicate if it was a good time to interrupt me or not. So yeah, it was a very real problem.
I made something similar with a blink USB light: https://blink1.thingm.com/ . I had a little sign that said "when it's red, I'm busy". And a keyboard shortcut to toggle it from red to green (it just ran a little bash script that invoked the blink CLI). It was duct-taped to my monitor so you could see it from far away.
It worked very well to prevent interruptions from other people walking up to my desk and chatting with me.