First Arduino Project

I am a freshman in college and am interested in doing a project that utilizes the Arduino board. I have basic C++, Java, and Python experience, and have soldered pcbs before. I am coming from a quadcopter background (where I mostly use pre-programmed boards with integrated sensors) so I have heard of the Ardiuno platform, however I have never done any true projects that had me rewriting code or messing with sensors and their integration. I would like to know where to start so I can learn how to use the board, which will undoubtedly give me an edge in engineering projects.

I am currently pondering buying an Arduino Uno - I want to use it as a learning base, and have the capability to do my first few "real" projects on it later on. Is this a smart step, or should I invest in a bigger/smaller board?

The project that I want to be able to complete once I am accustomed to the board and its nuances is this: I need to connect a sensor to the Arduino that tells me the time it takes for a piece of paper to pass by it. This can be an IR, color, or sonar, I am not sure yet. It will sense when the paper blocks the sensor, and start a timer. This timer will stop when the paper passes over the sensor and no longer blocks it. Knowing the length of the paper, I will be able to take this time and figure out the speed that the paper is traveling at. The speed range could be anywhere between 250mm/s to 750mm/s. I would like to display this speed on a display or on the screen of my computer.

Does this logic sound feasible, or will I find that once I get accustomed to the Uno that it isn't possible? Is the hardware available to do this sort of task? Is this too challenging a project to be a first or second Arduino project? If so, what would you recommend so that I would be able to do it? I am sorry for all of these questions, but having wanted to do an Arduino project for close to 3 years now, I am very excited at the opportunity. Thanks in advance for your feedback!

Looking at using this sensor for the project: Still want to know your opinions and advice, should I get a Uno and just experiment?

I’d stick with IR, reflective or interruptive.
Just start with Uno, and see how it goes.

Thanks - I will be ordering my Uno tonight. How do you guys learn how to work with these? Just do the tutorials and simple programs?


Uno board coming this Saturday... I can't wait!

How do you guys learn how to work with these? Just do the tutorials and simple programs?

Also, read the forums for a couple of hours: there are a number of questions that come up very frequently, as well as a few very common mistakes - misuse of serial.available is one. Just knowing about these issues, even if you didn’t fully understood them when you read them, can be useful when you find yourself going down the same path.

Alright, I have been playing with the Arduino for about 2 hours now and it is a breeze - instant gratification! I think I will be able to do this project earlier than I anticipated. Now the question - which sensor would be best to use to accurately sense when a page starts passing over the sensor and ends passing over it? I need this figure to be accurate so I can use the time elapsed between the two points to calculate the velocity of the paper. Here are the two option I am looking at right now: Any differences in performance/accuracy between the two?

First one looks o’k for me. Second is wrong choice:

Basic breakout board for the TEMT6000 Ambient Light Sensor. Only what you need, nothing you don’t. Sensor acts like a transistor - the greater the incoming light, the higher the analog voltage on the signal pin

Thanks a bunch! Now if I want to go measure the speed of a rotating shaft, can I still use the sensor, or do I need an encoder for that?

Okay, here is some code I wrote for the project - I don’t have the sensor yet, so I am not sure if it works or not, I am just posting it to get preliminary feedback. Anything stand out to you as bad practice or something that probably will fail?

 * Zerox Project Paper Velocity Sensor
 * Program Written By: Ivan Iakimenko 
 * October 15, 2011
 * This program is written for use in an Arduino Uno microcontroler. 
 * It finds the speed of a peice of paper in a printer feed using an IR
 * LED and a photoresistor to sense how long it takes for the paper to pass
 * a certain point in the feed. This figure is then used to find the true
 * speed of the paper and is displayed via serial port on a computer screen.

int lightSensorPin = 0; //connected to analog 0
float paperLength = 279.4; //length of 11" paper, in mm
float paperSpeed = 0; //calculated paper speed
int paperSensorValue = 5; //the sensor value when paper passes over it
long lowerTimeLimit = 350; //shortest possible time for paper to travel

void setup() {
  Serial.begin(9600); //starts serial connection


void loop() { //main loop
  int lightSensorValue = analogRead(lightSensorPin);
  long startTime = micros(); //this sets the starting time
  while(lightSensorValue <= paperSensorValue){
    lightSensorValue = analogRead(lightSensorPin);
  long timeElapsed = startTime-micros(); //finds how long paper blocked sensor
  if(timeElapsed >= lowerTimeLimit){ //eliminates false data fluctuation
    calcPaperSpeed(timeElapsed); //calculates paper speed
    Serial.print("Measured Paper Speed ");
    Serial.println(" mm/s");
    paperSpeed = 0; //resets paper speed for next sheet coming in

void calcPaperSpeed(long timePaperPass){
  paperSpeed = paperLength/timePaperPass; //d=rt formula transformed

Once again, thanks for your feedback!

SFE has two version of, I think you should order analog version. Code would be easier and results more accurate if you use digital input, attachInterrupt and pulseIn library functions.

So I should get the analog version and plug it into the digital input?

Frankly, I have no clue why SFE used analog/digital classification, looking at the drawings, I'd say they swap a names by mistake

That code looks nice :) all of my codes get alot of /**\ deals due to tests I always try to see how 'safe' the code is (like if for example my code crashes while waiting for event 2 to happen after event 1 is triggered...)

If I may , I would recommend a 16*2 LCD or any sort of lcd or display so that if you aren't on a serial connection (using some other power source) you can still see what the code is outputting. This may just be me,but I use mine all of the time to see if everything is still working.

Thanks for the compliments on the code - its true test will be when I get the sensor and can fine tune it. I like your LCD recommendation, I will probably get one once I get more funds to play around with. Right now I plan to stay connected to the serial since this project is rather immobile, however for future projects I can see how it could be very useful.

I got bored and made the lcd a part of the project as a clock :) If funds are limited you could get the cheapest ones (the odd or mass produced colors) and then just wait for a while :)