Hi!
I would like to connect an optical sensor to a Teensy 2 or 3.1. However, I am so new to electronics that I have no idea how to do this
The sensor is the KODENSHI - SG-2BC.
This is the info + data sheet:
http://uk.farnell.com/kodenshi/sg-2bc/opto-switch-reflective/dp/1253374
http://www.farnell.com/datasheets/83024.pdf
I gathered some information, e.g.:
http://letsmakerobots.com/content/optosensor
http://www.navitron.org.uk/forum/index.php?topic=8881.0
http://forum.arduino.cc/index.php/topic,10786.0.html
http://forum.arduino.cc/index.php?topic=86894.0
However I still feel totally lost. I don't really know how to read the datasheet nor do I understand which resistors go where.
- The datasheet mentions so many voltages, I don't even know how much I should feed to the IR diode or the "reflection sensor". Do they both take 5v?
- I'm assuming you can only use this sensor with 5v input? Or would it also work with 3.3v? For instance for connecting to a Teensy 3.1.
- The linked tutorials and articles use various resistors. I think I understand the need for a pull-up resistor, but I don't understand why the led needs one. as pull-up resistor I see both 10K and 100K being used. For the led one article mentions 470 ohms, another 220 and another 330 ohms. On what is this based? How would I calculate it?
I realise my questions are probably related to fundamental electronic theory. I'm working on that, but I was hoping someone could show me how to connect this sensor so I can figure it out from there. It's not really related to Teensy hardware per se, but this seems like a nice community so I thought I'd ask.
Thanks!
I would like to connect an optical sensor to a Teensy 2 or 3.1. However, I am so new to electronics that I have no idea how to do this
The sensor is the KODENSHI - SG-2BC.
This is the info + data sheet:
http://uk.farnell.com/kodenshi/sg-2bc/opto-switch-reflective/dp/1253374
http://www.farnell.com/datasheets/83024.pdf
I gathered some information, e.g.:
http://letsmakerobots.com/content/optosensor
http://www.navitron.org.uk/forum/index.php?topic=8881.0
http://forum.arduino.cc/index.php/topic,10786.0.html
http://forum.arduino.cc/index.php?topic=86894.0
However I still feel totally lost. I don't really know how to read the datasheet nor do I understand which resistors go where.
- The datasheet mentions so many voltages, I don't even know how much I should feed to the IR diode or the "reflection sensor". Do they both take 5v?
- I'm assuming you can only use this sensor with 5v input? Or would it also work with 3.3v? For instance for connecting to a Teensy 3.1.
- The linked tutorials and articles use various resistors. I think I understand the need for a pull-up resistor, but I don't understand why the led needs one. as pull-up resistor I see both 10K and 100K being used. For the led one article mentions 470 ohms, another 220 and another 330 ohms. On what is this based? How would I calculate it?
I realise my questions are probably related to fundamental electronic theory. I'm working on that, but I was hoping someone could show me how to connect this sensor so I can figure it out from there. It's not really related to Teensy hardware per se, but this seems like a nice community so I thought I'd ask.
Thanks!
Last edited: