opto isolated arduino input
This shouldn't be too hard:  



Vcc is the +5 V Arduino power supply, Vout goes to an I/O pin.  

Important parameter for an optocoupler is its CTR (Current Transfer Ratio), comparable to HFE for a transistor. But where HFE is often around 100 for a general purpose transistor, it's often less than 1 for an optocoupler, and therefore often expressed as a percentage, like CTR = 50 %, which means that you get 5 mA out for 10 mA in.  

You seem to have enough current available, but we won't need it all. The CNY17-2 has a CTR of 22 % min at 1 mA input, so we can get 0.22 mA out. The Arduino works at 5 V then the pull-up resistor should be minimum 22.7 k&Omega; to allow the transistor to pull the output low. You can even go higher but then you'll have to keep an eye on the transistor's leakage current. The CNY17-2 has a low 50 nA for that, so that won't cause any trouble. There's also a maximum 1 &micro;A leakage into the AVR controller, but even that will only cause a 100 mV drop with the transistor off, so that's safe.

The 100 k&Omega; also would mean that you only need 50 &micro;A output current to pull the output low. At 1 mA input we had 220 &micro;A out, so everything is peachy. For 35 V input and a maximum voltage drop across the LED of 1.65 VR1 should be maximum 33 k&Omega;. 

You'll have to check what the current will be at the minimum input voltage with this resistor value. For instance if the input voltage can be as low as 12 V then you need maximum 10 k&Omega;.

The anti-parallel diode protects against reversed connection, and can be any diode, like a 1N4148.

Note: Darlington output optocouplers like Oli's 4N32 have a much higher CTR, but it looks like we can do without that, and Darlington devices are more expensive: the 4N32 is twice as much as the CNY17.