Ha! I think i've nailed it!
The bugs are, in fact, related!
It seems that, while the emitter is exposed to light, a cap is charging somewhere. If the voltage on that capacitor exceeds a certain threshold, it first needs to discharge (first click) for the MCU to start functioning properly and lets you switch the light on (second click). Above an even higher threshold, discharging doesn't help and it's completely locked out until you bring it in the shade and click it once.
The thing is, i've just realized the 15 second lock out isn't, actually, a 15 second lock out!
It seemed like it yesterday because i was in a constantly lit room! But the fact is, the amount of time needed for the lockout varies with the amount of light the emitter is exposed to. In complete darkness it never locks out, no matter how much you wait. In bright light it takes 15 seconds. In even brighter light it's shorter than that.
So it seems like it's most definitely a hardware bug.
The bugs are, in fact, related!
It seems that, while the emitter is exposed to light, a cap is charging somewhere. If the voltage on that capacitor exceeds a certain threshold, it first needs to discharge (first click) for the MCU to start functioning properly and lets you switch the light on (second click). Above an even higher threshold, discharging doesn't help and it's completely locked out until you bring it in the shade and click it once.
The thing is, i've just realized the 15 second lock out isn't, actually, a 15 second lock out!
It seemed like it yesterday because i was in a constantly lit room! But the fact is, the amount of time needed for the lockout varies with the amount of light the emitter is exposed to. In complete darkness it never locks out, no matter how much you wait. In bright light it takes 15 seconds. In even brighter light it's shorter than that.
So it seems like it's most definitely a hardware bug.