0
\$\begingroup\$

I have 13 photodiodes. Positive connection from battery is connected to the positive end of each photodiode. The position of photodiodes is as shown below:

 o  o  o
 o     o
 o  o  o
 o     o
 o  o  o

I would like to connect a motor to the output of these photodiodes.

Now when I throw infrared light on some photo diodes, they will give me 9V output as I have connected 9V battery, others will give 0 as output.

Suppose I throw light on it as below: (generated number 1)

 o  o  1
 o     1
 o  o  1
 o     1
 o  o  1

I want the motor to complete 15 iterations, stop there for 2 seconds and again complete 15 iterations in reverse direction

Suppose I throw light on it as below: (generated number 2)

 1  1  1
 o     1
 1  1  1
 1     o
 1  1  1

I want the motor to complete 30 iterations, stop there for 2 seconds and again complete 30 iterations in reverse direction

Suppose I throw light on it as below: (generated number 3)

 1  1  1
 o     1
 1  1  1
 o     1
 1  1  1

I want the motor to complete 45 iterations, stop there for 2 seconds and again complete 45 iterations in reverse direction

And similarly...

Can somebody just give me an idea of how can I accomplish the above mentioned task? and also what materials I would need?

\$\endgroup\$

2 Answers 2

2
\$\begingroup\$
  1. You are going to need a microcontroller, with a large number of general purpose I/O pins. It could be done with discrete logic ICs, but it would be VERY complicated.
  2. You will need a motor controller to drive the motor (H-Bridge)
  3. You will need some way to detect each rotation of the motor so that your microcontroller can count the rotations. This could be mechanical (given the low number of turns) or you could use a photodiode, a light, and a reflective spot on the motor shaft.

As mentioned in pjc50's answer, the photodiodes alone won't give you a clean on/off so you'll need some additional circuitry.

Lighting just the photodiodes needed for a particular number might be kind of difficult. It might work better if you can put a cardboard cutout over the detectors and shine a larger light over the whole area. Use a 1 shaped cutout, shine the light, 15 rotations.

\$\endgroup\$
6
  • \$\begingroup\$ Thank you for much clean information. Infact this is my first question on this site. I have just started to learn making some circuits. So, I make mistakes. As I will practice some things, I would get some idea and thus less chances of mistake. I would like to ask you 1 thing. Can you please draw my attention to get some good details on microprocessor? \$\endgroup\$
    – Vishal
    Commented Jun 19, 2015 at 14:04
  • \$\begingroup\$ I would suggest you look into the Arduino series boards. The availabe I/O pins won't quite do ( only 13 digital I/O pins if you use one pin as the motor control output PWM,) so you will need to use a shield to provide more I/O. Arduinos are made to be fairly simple for beginners. \$\endgroup\$
    – JRE
    Commented Jun 19, 2015 at 14:10
  • \$\begingroup\$ Thanks for the suggestion. I have already visited their site and I can't figure out what to purchase and what not to. Can you please help me out there? \$\endgroup\$
    – Vishal
    Commented Jun 19, 2015 at 14:17
  • 1
    \$\begingroup\$ Figure out what you need first. How many inputs will you need? How many outputs will you need? What will you need to connect the inputs and outputs to the photodiodes and motor controller? Look at the schematics and specifications of the Arduinos. See what it will accept as an input, and what it can produce for outputs. Once you've got a handle on that, you can start looking at Arduinos. Do you know the programming language "C"? The Arduino programming environment uses that language. Once you've got all that straight, you should be able to figure out what you need to order. \$\endgroup\$
    – JRE
    Commented Jun 19, 2015 at 14:26
  • \$\begingroup\$ Ya, I know C language very well. BTW I am a programmer and like to play with circuits. But don't know much about circuits. :) \$\endgroup\$
    – Vishal
    Commented Jun 19, 2015 at 14:34
2
\$\begingroup\$

Firstly, photodiodes don't give you nice clean 0V/9V signals. You get better behavior from phototransistors, but you will still need some sort of thresholding system to decide where the boundary between light and dark is.

Secondly, you want to read the signals from what looks like a 7-segment display pattern, decode them, and rotate something accordingly. You will probably want a microcontroller to do the recognising. From there you have two options:

  • continuous rotation servo.
  • motor, possibly with a gearbox, driven by an H-bridge, with a revolution counter on the output shaft.

You don't mention what speed or precision you want on the rotation - is it OK to rotate 2.1 times or 1.9 times when you should have rotated 2 times? Do you want 1 RPM or 100 RPM?

\$\endgroup\$
9
  • \$\begingroup\$ First of all Thank you for the great answer to my first question. I would take a look at Microcontrollers as you mentioned. I want the accuracy. So, the revolutions should be in multiples of 15. I would like speed too. But I would prefer only that motor which gives me accuracy. \$\endgroup\$
    – Vishal
    Commented Jun 19, 2015 at 13:59
  • \$\begingroup\$ Do you mean "15 full rotations" or "15 degrees"? \$\endgroup\$
    – pjc50
    Commented Jun 19, 2015 at 14:05
  • \$\begingroup\$ I mean 15 full rotations \$\endgroup\$
    – Vishal
    Commented Jun 19, 2015 at 14:05
  • \$\begingroup\$ Easy enough. The issue is how accurately you want it to stop when it has rotated. For example you need it to line up precisely to the thousandth of an degree, that would be difficult and expensive. You probably don't. But you should come up with a number for desired accuracy. \$\endgroup\$
    – pjc50
    Commented Jun 19, 2015 at 14:19
  • \$\begingroup\$ No, I don't want that much accuracy. I just need 15 rotations. If it's 14.9 rotations, then also its good for me. \$\endgroup\$
    – Vishal
    Commented Jun 19, 2015 at 14:20

Not the answer you're looking for? Browse other questions tagged or ask your own question.