Building a Drying Recorder with Arduino UnoR3

Greetings, folks. I work for a chemical company, and my supervisor asked me if I could build a Drying Recorder. Now, these machines are typically very pricy, but they do not seem very complicated, and I have a good concept for building one that would meet the needs of several coworkers.

A Drying Recorder is basically an apparatus which contains a movable arm with a bunch of needles attached; and the arm moves very slowly, dragging the needles through some setting liquid (plastic, paint, etc). Based on the speed of the armature and the scratch marks made by the needles, you can tell exactly how long it takes for your liquid to dry.

More conventional models of Drying Recorders use gearboxes to achieve different rotational speeds, but I think we can take a more high-tech approach with an Arduino microcontroller in conjunction with a stepper motor. The stepper motor would turn a leadscrew, with the armature attached. The device would need to travel a constant distance in varying amounts of time, determined by the approximate drying time of the liquids we're trying to test.

Some of the test times quoted to me ranged anywhere between 4 minutes and 24 hours; so basically the Arduino stuck out as the only option which could control the motor through the turning speeds necessary to achieve these requirements.

In order to vary the speed, based on the prescribed drying times, I was thinking of hooking up a potentiometer to the final assembly and turning a dial to set your desired speed. In terms of other inputs, I would use a three-position switch to start the motion of the armature. A "forward" position on the 3-position switch would cause the stepper motor to spin the leadscrew and move the armature forward at a prescribed speed. A neutral position would be "off". Lastly, the "reverse" position on the switch would cause the motor to spin at full speed to return the armature back to its original position. Two limit switches would be incorporated at either end to make sure that the armature does not exceed the allowed limits of motion.

I will be using a 5V DC Stepper motor to drive the leadscrew. I would love some additional information about programming the Arduino (I have never used one before), some tutorials would be excellent. I would basically need to know how to hook up the Potentiometer to vary the motor speed as required by the particular drying times, as well as to incorporate the three switches (3-position, and two limit switches). I'm also interested in learning how to microstep the stepper motor through Arduino (so we get very smooth, uniform, high torque motion). The motor must be very slow, and very smooth.

If I'm not being clear enough in this original description, please let me know and I will explain more thoroughly. I would greatly appreciate any advice you guys could give me on this project. Thank you for your time.

You might be better of with a rotary encoder as the input device, and an LCD screen to readout the amount you have dialed up.

... some tutorials would be excellent ...

This site has a lot of tutorials, and there are example programs in the IDE. Perhaps get an Arduino and work your way through some of them, and then ask a more specific question?

Well, I'm a physicist with basically no electrical engineering experience. I'm still learning about this stuff, haha.

Well, I'm a physicist with basically no electrical engineering experience.

Rotary encoders, stepper motors, LCDs, etc. are hardly electrical engineering specific tools. What you have here is almost entirely a mechanical engineering project with some help (and not much) from computer science major. As a physicist, I'm surprised that a little programming scares you so much.

It doesn't scare me; that's why I'm trying to learn it. It's the only part of the job I don't know how to do yet, and I want to make sure I do it correctly.

So I was wondering if one of you guys could point me in the right direction.

Okay, so here's basically what I want to do.

For a .5" diameter leadscrew with .125 in/rev lead; 12" length, mass .489 lbs; and 10" effective length (the travel distance of the recorder, a point on the screw travels 10" in 80 revolutions of the screw)

I have calculated the number of steps/second as a function of time, assuming a 10:1 gear ratio between the motor and leadscrew (10 revolutions of the motor = 1 revolution of the screw)

Steps(t) = (Gear Stepdown)(2pi)(number of revolutions to travel distance)(180/pi) / ((1.8 degrees per step)(time in seconds))
Steps(t) = (102pi80/t)(180/(1.8pi))
Steps(t) = (160000/t)

For this prescribed input time (in seconds), my motor speeds are as follows:

4 minute test = 666.6666 steps/s = 200 RPM
10 minute test = 266.66667 steps/s = 80 RPM
30 minute test = 88.88888 steps/s = 26.7 RPM
2 hour test = 22.222222 steps/s = 6.7 RPM
10 hour test = 4.4444444 steps/s = 1.33 RPM
24 hour test = 1.8518 steps/s = .56 RPM

If we scale the voltage to my 5 volt stepper motor, and set the motor to run at 200 RPM while at 5 volts, and scale the voltages accordingly: the following voltages correspond to each test lengths.

5 V = 4-Minute Test
2.000000225 V = 10-Minute Test
0.666666667 V = 30-Minute Test
0.166666682 V = 2-Hour test
0.033333336 V = 10-Hour Test
0.013888501 V = 24-Hour Test

Attached is the scaled voltage/time relationship.

Because I am so unfamiliar with the arduino programming environment, or programming a stepper motor control in general, where should I start looking to learn about this stuff? I'd like to eventually have a numpad and LCD display that allows you to input your desired runtime in seconds, and have the arduino take care of the motion control; while outputting the time/distance scale to the LCD so that you can measure drying time. Any help would be greatly appreciated. Thanks for your time.

Hi George,

You need to understand Stepper Motors.. See the Arduino built-in Library here:

See an overview on the http://ArduinoInfo.Info WIKI here:
http://arduino-info.wikispaces.com/StepperMotors

IF you need to accelerate/decelerate, see this library:
http://www.open.com.au/mikem/arduino/AccelStepper/

Let us know what you think....

As I gather more resources on the subject, I'm becoming a bit more unsure if the Arduino can serve my needs here.

I don't know if there are simply enough inputs and outputs on the Arduino for what I want to do. I'd like to have the following:

Inputs:
Numpad for Time Entry (also outputs to LCD)
One button to start motion of the motor.
Another button to recall motor to starting position.
Two limit switches to terminate motion.

Outputs:
LCD Screen to display entered time and time/distance scale
Stepper Motor

I'm looking at Jeremy Blum's tutorial on the LCD display, and that already uses damn near half the outputs on the Arduino Rev 3. I currently have two arduino Rev 3's, will I have to use both in this project?

Hi George,

I think it can fit.. You need a display with only 2 pins needed, and maybe pushbuttons that need only one pin. See:

http://arduino-info.wikispaces.com/LCD-Blue-I2C
and
http://goo.gl/2RaBc (Pushbuttons on one pin) See "read_LCD_buttons()" code at the bottom of this page:
http://arduino-info.wikispaces.com/LCD-Pushbuttons

DISCLAIMER: Mentioned stuff from my own shop...

DISCLAIMER: Mentioned stuff from my own shop...

Haha, all good. I'd rather buy stuff from someone trustworthy, such as yourself, any day!

GeorgeT:
I'm looking at Jeremy Blum's tutorial on the LCD display, and that already uses damn near half the outputs on the Arduino Rev 3. I currently have two arduino Rev 3's, will I have to use both in this project?

You can use LCDs with port-expanders, eg. as described here:

You can also buy them (LCD "backpacks"), eg.

This significantly reduces the number of pins you have to dedicate to the LCD display (down to 2 or 3, plus power and ground).