Creating a timer that performs an action

  • Thread starter dunar21
  • Start date
  • Tags
    Timer
In summary, you have an IR sensor that detects when objects pass by, and you want to create a circuit that will activate a motor after a certain number of objects have been detected. You need a microcontroller to count the objects and send the appropriate output signals. There are many microcontroller options, but you'll need to research which one will work with the circuit you've linked.
  • #1
dunar21
3
0
Hello, I am not even a novice at electrical engineering. I am a web designer and a programmer (Actionscript 3.0 and PHP - also MySQL for my websites' databases-). Anyway, I am attempting to create a series of circuits that count items moving on a conveyor belt with an IR sensor, and runs a motor in one direction after a certain count and then in the opposite direction after a repeat of that count. So, say for every five items, once the fifth item breaks the IR connection and sends the fifth pulse to the counter, I need the counter to run a motor in one direction(and to switch directions after every 5th count) and begin counting the next item as number 1. I have an IR circuit that sends pulses to this counting circuit kit I bought at an electronics store: http://www.kitsrus.com/pdf/k129.pdf (This kit uses the IC described on the datasheet at http://www.atmel.com/dyn/resources/prod_documents/doc0838.pdf). How would I arrange the circuit to run a motor (about 9V to the motor) after every 5 counts. I would need it to start the next count at 1 instead of using a count to reset and then the following count set to 1. So, as the 5th count runs the motor that same connection would have to reset the clock instead of the 6th count resetting it. It would be nice to have a switch that allows me to switch between a 5 or a 6 count, but once I see how to do one, it shouldn't be that difficult to make a switch that runs a similar process at a different count. Any help or advice would be greatly appreciated. Thank you in advance.
 
Last edited by a moderator:
Engineering news on Phys.org
  • #2
Without getting too deep into this...

It sounds like you've got your sensor figured out, but you need a simple micro-controller to do the counting and motor control. There's hobbyist sorts of things like the Basic Stamp and Arduino, or you can spend a few months becoming an embedded engineer and use a MicroChip PIC or many others.

The main problem is running your motor in both directions. For this you need an "H-bridge" driver, which could lead to another few months of electronic engineering degree study. There are commercial boards and motor controllers for automation and such, e.g., I have used these guys products: http://www.geckodrive.com/
 
  • #3
Swapping the leads on a dc motor reverses the direction of rotation. So if you didn't want to get into the H bridge thing, you could either:

1. Wire up two separate batteries (with the leads wired opposite each other at the input) to a transfer switch (if such a thing exists on this scale) or...

2. Wire up two different motors to the same conveyor. Each would run the opposite way.

You'd still need the microcontroller to do the counting and send the appropriate output signalling, of course
 
  • #4
Evil Bunny said:
Swapping the leads on a dc motor reverses the direction of rotation.

Not necessarily. This is true only on a motor with permanent magnet fields.
 
  • #5
good point... I think most smaller motors will work this way. You should check first.
 
  • #6
Thanks for your help guys. It seems that the circuit I linked to is programmed in a specific way and the software is proprietary, so there is no real way to modify that particular circuit to suit my needs. There have to be many IC circuits, though, that will allow me to send a series of pulses and then to simply have current flow after a certain amount of pulses, reset and repeat. I'm google hunting for the solution now. Thanks again for the assistance.
 

What is a timer that performs an action?

A timer that performs an action is a function that allows you to set a specific time interval and perform a specific action once that interval has elapsed.

What is the purpose of creating a timer that performs an action?

The purpose of creating a timer that performs an action is to automate certain tasks or actions that need to be performed at specific intervals. This can save time and improve efficiency in various scientific experiments or processes.

How do you create a timer that performs an action?

To create a timer that performs an action, you can use a programming language such as JavaScript. You would need to define the time interval and specify the action that you want to be executed. This can be done using functions and conditional statements.

What are some common types of actions that can be performed by a timer?

A timer can perform a wide range of actions, depending on the specific needs of the experiment or process. Some common types of actions include displaying a message, playing a sound, updating data, or triggering another function.

What are some considerations to keep in mind when creating a timer that performs an action?

When creating a timer that performs an action, it is important to consider the accuracy and precision of the timer, as well as any potential errors or interruptions that may occur. It is also important to ensure that the action being performed is relevant and necessary for the experiment or process.

Similar threads

  • Electrical Engineering
Replies
1
Views
1K
  • Electrical Engineering
Replies
11
Views
2K
Replies
19
Views
4K
  • Electrical Engineering
Replies
2
Views
2K
  • Electrical Engineering
Replies
10
Views
8K
  • Electrical Engineering
Replies
8
Views
5K
Replies
11
Views
3K
Replies
2
Views
1K
  • Electrical Engineering
Replies
5
Views
5K
  • Engineering and Comp Sci Homework Help
Replies
5
Views
3K
Back
Top