Is it possible to use an optointerrupter as a optoisolator?
Don't have an opto-isolator? Make one.
All transistors are photo-electric until put in a can or some opaque plastic. If you have a small signal metal can transistor you can cut or file the top off and super-glue it to an LED.

LED superglued to 'photo-transistor'.

The finished article with heatshrink sleeving.
The transistor is a 35-year old BC108. LED is a generic red - probably same vintage.
Watch out for light getting in the back of the LED. Current transfer may not be very good so you may need to 'Darlington' the output.