# Planet Arduino

Dic
26

## LittleArm Is a Little Robot with a Little Price Tag

#### arduino, robot arm, Robotics, technologyNo comments

If you're looking for a robotic arm, you wouldn't do badly to et LittleArm.

The post LittleArm Is a Little Robot with a Little Price Tag appeared first on Make: DIY Projects and Ideas for Makers.

Set
14

## Robotic Arm from Cardboard

#### arduino hacks, cardboard, robot arm, robots hacks, servo motorNo comments

Google showed the world that you could make a virtual reality headset from cardboard. We figure that might have been [Uladz] inspiration for creating a robotic arm also made out of cardboard. He says you can reproduce his design in about two hours.

You’ll need an Arduino and four hobby servo motors. The cardboard doesn’t weigh much, so you could probably use fairly small motors. In addition to the cardboard, there’s a piece of hardboard for the base and a few metal clips. You can control it all from the Arduino program or add an IR receiver if you want to run it by remote control. There’s a video of the arm–called CARDBIRD–in action, below.

If you want to build something more robust, we’ve looked at some serious arms before. If you want to go big, we’ve seen that before, too. But every project has to start somewhere, and a cardboard mock-up is one of our favorite things.

Filed under: Arduino Hacks, robots hacks
Ago
02

## The little Arduino robot arm that could!

#### 3D printing, 3D-Printed Robot Arm, arduino, diy, Featured, kickstarter, robot arm, Robotics, Robots, unoNo comments

As its name would suggest, the LittleArm is a mini 3D-printed robot that began as a weekend project. Its creator Gabe Bentz wanted a small arm that was easy to work with, and one that wouldn’t require him to dig deep into his wallet. So, as any Maker would do, he decided to design his own low-cost device.

After showing the LittleArm off, it wasn’t before long that he was approached by some STEM teachers in the area who wondered if the kit was something they could use in their classrooms. Ideally, every student should have one to tinker with, but unfortunately today’s systems tend to be too expensive and quickly loose parts and pieces. This is a problem that LittleArm is looking to solve.

The arm is powered by an Arduino Uno and four identical metal-geared micro servos, while all other mechanical components are 3D-printed. There’s also a modular gripper that’s actuated by a servo along with rigid end-effectors for various tasks. What’s more, a basic GUI enables you to control the arm, its gripper, the speed, as well as use its record function to train the robot to perform a specific task and then watch it play out the sequence.

The entirely open-source gadget comes as a DIY kit that can be purchased or built from scratch. Want one of your own? Check out Bent’z Kickstarter page here, and see the LittleArm in action below (including some of its dance moves).

Giu
24

## Taming Robot Arm Jump with Accelerometers

#### Accelerometer, arduino, arduino hacks, C, robot arm, robots hacksNo comments

Last fall, I grabbed a robot arm from Robot Geeks when they were on sale at Thanksgiving. The arm uses servos to rotate the base and move the joints and gripper. These work well enough but I found one aspect of the arm frustrating. When you apply power, the software commands the servos to move to home position. The movement is sufficiently violent it can cause the entire arm to jump.

This jump occurs because there is no position feedback to the Arduino controller leaving it unable to know the positions of the arm’s servos and move them slowly to home. I pondered how to add this feedback using sensors, imposing the limitation that they couldn’t be large or require replacing existing parts. I decided to try adding accelerometers on each arm section.

Accelerometers, being affected by gravity when on a planet, provide an absolute reference because they always report the direction of down. With an accelerometer I can calculate the angle of an arm section with respect to the direction of gravitational acceleration.

Before discussing the accelerometers, take a look at the picture of the arm. An accelerometer would be added to each section of the arm between the controlling servos.

## Accelerometers

Gravity tugs everything toward the center of the mass of the Earth. It is a force that creates an acceleration exactly just like what you feel when a vehicle begins to move or stop. The force of gravity creates an acceleration of 1 g which is 9.8 m/s2 or 32.15 ft/s2. An accelerometer measures this force.

Integrated circuit accelerometers are inexpensive and small devices readily usable by hackers. One reason they are inexpensive is the high demand for them in smart phones. These small devices are based on etching mechanical structures within the integrated circuit using a technology called MEMS (Microelectromechanical systems).

One design for a MEMS accelerometer is basically a variable capacitor. One plate is fixed and the other mounted some distance away on a spring suspension. When the device is accelerated the suspended plate moves closer or further away from the fixed plate, changing the capacitance. Another uses piezo-resistive material to measure the stress on an arm caused by acceleration.

A single axis accelerometer measures acceleration in only one direction. If positioned so the direction is up and down it will measure the force of gravity but will not detect horizontal acceleration. When the device is tilted between horizontal and vertical the force of gravity is only partially affecting the measurement. This provides the ability to measure the angle of the device with the direction of gravity. The acceleration felt along the tilted axis, for a tilt angle can be calculated by:

$A_{X} = g \sin\left ( \theta \right )$

Knowing the output of the accelerometer we can determine the angle by taking the inverse sine, the arc sine, of the output:

$\theta = \arcsin \left ( \frac{A_{X}}{g} \right )$

If you rotate a single axis device through 360° the output is a sine wave. Start with the device outputting zero and consider that 0°. As it rotates, the output is 1 when the angle is 90° and back to zero at 180°. Continuing the rotation, the output becomes -1 at 270°, or -90°, degrees and back to zero at 360°, or 0°.

Notice on the chart that between -60° and 60° the output is nearly linear. This is the best orientation for measuring inclination. Increases in inclination are not as accurate on the other portions of the curve. Also notice that the same output is generated for 45° and 135° (90° + 45°) creating an ambiguity. With a single axis you cannot determine which of those angles is measured.

Putting two accelerometers at a right angle to one another creates a 2-axis device which solves the ambiguity problem. As the device is rotated through 360° the outputs are 90° out of phase, the same relationship as the sine and cosine. By combining the measurements there is a unique solution for every angle throughout 360°. The acceleration due to gravity at each angle is given by:

$\frac{A_{X}}{A_{Y}} = \frac{\sin\left ( \theta \right )}{\cos\left ( \theta \right )} = \tan\left ( \theta \right )$

which leads to calculating the angle by:

$\theta = \arctan \left ( \frac{A_{X}}{A_{Y}} \right )$

Actually, one more step is needed to determine the sign of the angle. This requires examining the sign of the values for the X and Y axis. It isn’t necessary to go into this here because a standard programming function handles this automatically.

The orientation of a quadcopter requires a 3-axis accelerometer. The calculations for the three spherical angles combine all three inputs for their results. You’ll need to study this carefully because the standard trigonometric equations can cause anomalies when the quadcopter flips.

## First Pass Solution

Accelerometers are easily obtained and relatively cheap. You can find them mounted on breakout boards with voltage regulators and all the supporting circuits from the usual vendors. They are available for 1 to 3 axis, various amounts of g force, and providing either analog or digital outputs. Analog devices need an analog input for each axis being measured. Digital outputs use I2C or SPI buses for communications. I decided to use analog devices because digital units typically only allow two addresses and the arm needs three devices, one for each section.

The robot arm uses an Arduino board so there are at least 6 analog inputs. The original board was a Robot Geek Geekduino, their version of the Arduino Duemilanove, with 8 analog inputs. Unfortunately, when working with the arm I broke the USB connector so switched to a Uno equivalent having only 6 inputs.

My choice for accelerometer is a 3-axis, ±3 g accelerometer breakout from Adafruit, their ADXL335. It has one analog output for each axis. Since I’m measuring three joints that means three boards which adds up to 9 analog outputs.

Because of the geometry of the arm, however, I only need 5 inputs for these three joints. The shoulder joint only moves from 0° to 180°. This can be handled by a single axis accelerometer by mounting it to read acceleration of 1 g for 0° and -1g for 180°. That provides a unique output for the necessary angles. The elbow and wrist joints each require two inputs. The third input is not needed because their motion is constrained to moving within the vertical plane of the arm.

## Frame of Reference

The next issue is the frame of reference. This is a standard problem in robotics work. Early in a project, a global frame of reference is decided upon. This sets the origin for the coordinate system that the robot will follow and the direction of the three axes, usually specified as X, Y, and Z. For the arm, X is straight forward, Y is to the left, and Z is straight up. The zero point is the base of the shoulder. This also defines a global frame for rotation of the arms limbs with zero degrees also toward the front.

Sensors and controllers each have their own frame of reference. Any differences among these devices and the global frame need to be resolved in software. The shoulder servo’s frame of reference is 0° at the back of the arm and 180° at the front, a clockwise rotation. This is the reverse of the global frame. The elbow servo worked the opposite with a counter-clockwise rotation putting 180° straight up and 90° straight out when the shoulder was vertical. It is 90° off from the global frame of reference.

Sensors also have their own frame of reference. The Y-axis accelerometer measuring the shoulder orientation worked counter-clockwise. Both axis on the accelerometers measuring the elbow worked in the clock-wise direction. This may seem strange but it’s because of the different mounting orientations of the sensors.

## Software

The actual code is straightforward once the frame of references are sorted out. A single axis is read from the analog input and its angle calculated with:

const int shouldery = shoulderAnalogY.read();
float shoulder_angle = degrees(asin(shouldery_value / 100.0));


The  read() method scales the raw analog input values so ±1g is represented as ±100. The input to asin() is divided by 100.0 to convert to the actual g value. That suffices for the shoulder angle.

The elbow and wrist angles use values from two axis and the calculation is:

const int elbowx = elbowAnalogX.read();
float elbow_angle = degrees(atan2(-elbowy, elbowx));


The atan2() function is a special version of the arc tangent calculation. It examines the signs of the input value to determine the quadrant of the angle to set the appropriate sign on its result. The negative sign on the elbowy is needed to set the appropriate quadrant. There’s the frame of reference issue, again.

## Wrap Up

Adding the accelerometers solved the startup lurching problem well enough. Whether the accelerometers can be used for other purposes remains to be seen.

The accuracy of the angle measurements is not good. In part this is due to using a device that with a +/- 3 g range to measure 1/3 of the devices range, 1 g. The device outputs 0 to 3.3 volts while the Arduino is sampling for 5 volts, again losing accuracy. This might be improved by using an Arduino based on 3.3 volts. I have a couple Dues on hand so might try them. The Uno also provides for adjusting the reference voltage for analog inputs so setting it to 3.3 volts might help.

The analog values need to be calibrated with some care. Each accelerometer outputs slightly different values. Calibration requires measuring the outputs for 1 and -1 g for each axis, recording the values, and using them to scale the voltage input to acceleration. This calibration is not accurate given the other problems with the analog inputs.

Another problem is the mounting of the accelerometers on the arm’s sections. The alignment of the boards with the sections of the arm is not perfect. When the servo is positioned at 90° the accelerometer doesn’t necessarily sit at 90° with respect to the center of the earth. Of course, the servos are not that precise, either. They do not always arrive at the same position, especially when approaching from different directions. Another goal for this project was to use the accelerometer information to more precisely position the servos.

I guess I have to think about this project a bit more, including deciding what I actually want to accomplish with the arm. But then, just saying you have a robotic arm is a terrific hacking cred.

Filed under: Arduino Hacks, robots hacks
Nov
06

## This Cereal-Stealing Robot Will Swipe Your Breakfast

#### arduino, cereal, Fun & Games, Home, line-following, MATLAB, Motion Sensor, range sensor, robot arm, Robotics, Robots, stem, technology, ultrasonicNo comments

One Maker’s experiment in robotics results in an insatiable cereal transport system using Arduino, 3D printing, and Rice Krispies.

Ott
27

## Let This Helmet with a Robot Arm (Sorta) Brush Your Teeth

#### arduino, Fun & Games, helmet, Home, robot arm, robot arms, Robotics, servo, servo shield, technology, toothbrush, WearablesNo comments

Maker Simone Giertz creates a ridiculous, impractical, yet awesome motorized helmet that brushes her teeth. Sorta.

Ago
01

## Human Gestures Control this Robot Arm

#### 3 DOF robot arm, arduino hacks, robot arm, robots hacksCommenti disabilitati su Human Gestures Control this Robot Arm

[Ray Kampmeier] just finished writing some code to allow him to control his robotic arm using force-sensitive hand gestures! He calls it the Robo Marionette.

He’s using a MeArm 4 DOF robotic arm, a Sensel touch interface, an Arduino Uno, and a servo shield for the Arduino to control the MeArm. All the code you need is available on his GitHub, but unfortunately the Sensel touch interface isn’t actually available to the public yet.

Regardless, it’s a very cool proof of concept of what you can do with a gesture interface device like the Sensel. The MeArm ships without a controller and pairing it with a non-traditional control method (joystick, knobs, hardcoding, etc.) really takes the two devices to a new level they wouldn’t reach by themselves. See for yourself in the video below. MeArm is available in the Hackaday Store.

Other gesture controlled robots of note include using two Leap motion controllers to control some industrial robot arms — for robotic surgery! And of course there’s also advanced robotic arm control using a Kinect!

Filed under: Arduino Hacks, robots hacks
Lug
07

## New Project: Building a Robot Arm Part 4: Adding Control with an Arduino

#### 3D printing, arduino, ARM, Design, Electronics, H-Bridge, Robot, robot arm, RoboticsCommenti disabilitati su New Project: Building a Robot Arm Part 4: Adding Control with an Arduino

This project is part 4 in the building a robot arm tutorial. In the first part I show how to design the arm, the second part shows how to design the base, and the third shows how to design the mount. After all of the Computer Aided Drafting (CAD) and 3D modeling […]

Feb
11

## 6-Axis Robot-Arm 3D Printer Runs on Arduino, Slings Spiderwebs

#### 3D printing, arduino, Electronics, knitting, kuka, Machining, robot arm, ToolsCommenti disabilitati su 6-Axis Robot-Arm 3D Printer Runs on Arduino, Slings Spiderwebs

Most industrial robots run on proprietary systems, but this experimental KUKA arm uses an Arduino MEGA to 3D print in 6 axes, mimicking the shapes found in nature. Despite the size of this KUKA arm with a custom toolhead attachment — a 3D printer extruder — carefully looking at the […]

Planet Arduino is, or at the moment is wishing to become, an aggregation of public weblogs from around the world written by people who develop, play, think on Arduino platform and his son. The opinions expressed in those weblogs and hence this aggregation are those of the original authors. Entries on this page are owned by their authors. We do not edit, endorse or vouch for the contents of individual posts. For more information about Arduino please visit www.arduino.cc

• You are currently browsing the archives for the robot arm category.