Detecting 12v, car brake lights, with a simple resistor

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.


Why is it the correct way to do it? I don't see why you need a voltage divider if your just checking on and off states.

One of the reasons a voltage divider is the preferred method is that some chip manufacturers state in their data sheets that the input protection diodes are for intermittent use only and are not to be used for clamping down an input higher than spec'd Vcc. Can't really say which manufacturers and which devices but the topic was heavily debated on an 8052 forum several years back and the consensus was to always use a divider with greater than Vcc inputs.
In the end, though, it is your controller and if you want to stress the input circuits to save a penny on an extra resistor, by all means go for it.

Or add a cd74HC4050 to convert the 12V+ signals down to 5V. Power it from 5V to get 5V outputs.