I see the typical way of detecting voltages above five (5) volts, or three (3) volts, is to use a voltage divider. However, I simply need to detect the presence of power and do not care about voltage measurements.
I will be measuring my car's 12 volt, brake and turn signal lights. Both of which, I believe, are PWM controlled. Therefore, using PulseIn seems to be the correct thing to do. Actively depressing the brake increases the duty cycle of the lamps. The car also runs the amber turn signals at reduced duty cycles for other things such as getting out of the car or remote start.
I believe a simple, high value, resistor in between an arduino (microcontroller) will work well.
I don't have a background with resistors but believe a 100K resistor should do nicely and handle large voltage spikes well.
I have a load of various common resistors on hand, so I can change to another valued resistor.
The rear lamp assemblies have a 4 wire harness: GROUND (-), RED LAMP (+), AMBER LAMP (+), IGN SWITCHED POWER (+).
I hooked up a relay to the brake (red) lamp and it made a humming sound. I tried another relay, on the board, and it clicked back and forth violently. I then realized that PWM was being used.