dhenry:
the internal pullup resistor from the arduino active.
That pull-up "resistance" is too high and you may not be able to turn off the phototransistor and generate a logic 0.
Use a resistor and its value will generally be < 10k.
ok i just say the internal pullup resistor of the arduino is 20Kohms.
I will use a 10k then ! thanks for the information dhenry