I have a project where I have to detect the presence of 110V DC. It turns out that the voltage on the point I am connected has voltages from some 70V - 130V DC. In some of the other projects I use this setup:
According to the datasheet for the optocoupler I use, the max forward current is 50mA:
My guess is R1 resistor of some 10K will do the job. The problem is, I don't have any power supply to try it with those voltages. That said, I am not sure which resistor to use.
Any of you messed up with this? Or is there some other way to detect those voltages?