PNP Sensor Hookup

Try it this way, first:

And if that doesn't give you enough range, then try it this way:

The first circuit is more efficient, but has more limited range. The second one uses more current, but has a larger potential range (i.e. more "sensitive").

The resistor values are quesses (I downloaded one of the product photos from the eBay link you provided and then "blew up" the image and examined the markings on the chip resistors).

The 2k resistor was chosen based on my "Voltage Sensor" resistor value guesses -- the logic being, to select a resistance value low enough to minimize the effect of current flowing into the Voltage Sensor, yet, not over tax the photo sensor. That 2k resistor value may be too low. You'll probably have to experiment.

Connect "SIG" to an Analog Input, in Setup, do an pinMode(analogInput, INPUT), and then, to read the level, do an analogRead(analogInput). analogInput is, of course, defined as the pin number you connected SIG to [e.g. #define analogInput A1]