I am trying to connect slotted opto ( TCST2300 ) to raspberry pi. I would like to receive 1/0 on GPIO input pin. Programming is not a problem but the circuit is.
I referred following circuit
But it is unclear which pin goes where. ("GPIO Pin" and "Input" particularly )
I tried with:
1: connecting "GPIO Pin" to Pi's 3.3V through 10K resistor
2: connecting "input" to P17.
Then I always received 1 on P17, regardless of infrared being interrupted.
Could you please guide me here?