I am starting a project. I have used the Arduino IDE while working with my 3d printer, and fiddle with a raspberry pi before. I have a basic understanding of electronics, so the wiring and stuff I will grind out with the help of 5000 google searches. What I'm wondering about is the modules, and the particular Arduino model I should get.
I need:
Arduino (Thinking about the UNO)
Small stepper motor (Doesn't need to be strong)
Small camera module (Doesn't need to be high resolution - considering the OV7670)
If I get these, will I need a "shield" of any kind?
Can the Arduino and modules be power via USB?
The project will take a picture of an object, the stepper will push that object out of the way, and repeat many times. I would like the pictures to be saved in a folder on a PC (linked via USB cable). Later there will be post processing on the images in the folder, but that is the 2nd step of the project.
Thanks so much for any help. It's much appreciated!
How large an image are you going to work with, in terms of file size? The pi may be better for this, as the Arduino does not have very much ram to buffer that image in (2k), so the transfer will be slow and awkward - Arduino (at least the 8bit avr ones -the zero and due use fancier chips) is generally not recommended for working with cameras or large volumes of data.
Don't plan on using an Arduino to process any image. Use the PC or an RPi for that.
How will the system know that there is an object that needs to be pushed out of the way ?
The Arduino is good for controlling motors and reading simple sensors. Have a look at stepper motor basics before you spend money. However that Thread does not deal with the small 28BYJ unipolar steppers that are controlled via a ULN2003 chip. There are many other Threads about them.
An Uno should be fine.
All motors should be powered separately from the Arduino.
The system will push in a new object every 5 seconds or so.
I wonder... is there a way to have a USB Webcam with a little motor attached? XD
An RPi + Cam module is just tooo expensive. I might want to make a bunch of these.
If I had an arduino push in new objects every 5 seconds, I guess a USB webcam with some software could just take a picture every few seconds and at least never miss an object...
However, if the device itself will literally only have a stepper motor, maybe the uno is a little overkill? Would a nano suffice? Is there anything cheaper?
How will the Arduino detect the fact that an object has been pushed in?
If this detection is visual it must be done on a PC.
However if there is, say, a IR beam that is broken that could certainly be detected by an Arduino.
You can certainly get Arduino devices that are cheaper than an Uno but it is probably best to develop the prototype on an Uno as they are the most "standard" of the Arduinos. The code should transfer to another Arduino without any (or very few) changes.
Why would you need a stepper motor to push an object out of the way ?
What exactly is the object ?
Your earlier Posts dis not suggest that the camera needs to move. Maybe a small servo would be sufficient for moving the camera.
You would get a lot more useful information if you give a full description of the project.
Sorry about the confusion. I will try to be more specific.
The objects will likely be thin petri plates. The stepper will shove a plate out of the way, and another will be placed under the camera (it will be placed by a different mechanism, not in the scope of this project).
The camera does not need to move. It will be stationary, placed over the platform that holds the plates.
Basically the camera takes a picture of a plate, a stepper will push the plate away, and then another device will slide the next plate in. Ideally the camera will send information via USB to a PC, and the PC will recognize that the plate has been switched (or simply be on a timer syncronized with the arduino), and then take the next picture. Software will later read a code (possible QR code) from the plate and then add the photo (with attached ID code or whatever) to a database.
My rambling about the camera with a motor attached was this: I've noticed that USB webcams have LED's that turn on. I was wondering if the LED could be rewired to send a signal to the Arduino to trigger the stepper motor... If the LED just turns on when the camera has power then that's not going to work.
I think it would help if you can make a simple drawing showing how the apparatus is intended to work and post a photo of the drawing. Don't worry about artistic style.
My guess is that you need something that the Arduino can use to know when the petri dish is in the right place. Maybe a microswitch would be suitable, or an optical detector. Then the Arduino could send a message to the PC to tell it to take a photo and after that it could move the dish onwards.
I am still at a loss to understand the need for a stepper motor - though they can easily be controlled by an Arduino.