Project tutorial
Ball and Beam

Ball and Beam

The ball and beam system is a popular textbook example in control theory and nonlinear dynamics.

  • 826 views
  • 0 comments
  • 2 respects

Components and supplies

Necessary tools and machines

Hy gluegun
Hot glue gun (generic)
83x7311 40
Scissor, Electrician
09507 01
Soldering iron (generic)
26w6260 40
Multitool, Screwdriver

Apps and online services

About this project

Video

Video of the System working

Introduction

This was a school project. The assignment was to construct a ball and beam control system.

A ping pong ball sits on top of the beam rolling forwards and backwards according to the pitch of the beam. The pitch is controlled by a servo that is connected to an Arduino. The position of the ball is measured by a distance sensor mounted at the end of the beam.

An PID controller is used to control the position of the ball on the beam.

Physical Setup

A ball is placed on a beam, see figure below, where it is allowed to roll with 1 degree of freedom along the length of the beam. A lever arm is attached to the beam at one end and a servo gear at the other. As the servo gear turns by an angle theta, the lever changes the angle of the beam by alpha.

When the angle is changed from the horizontal position, gravity causes the ball to roll along the beam. A controller will be designed for this system so that the ball's position can be manipulated.

So the transfer function becomes as shown in equation:

Mechanical Parts

A simple card box can do the job.

  • Base support (40 cm x 20 cm)
  • 2 x Support (20 cm)
  • 2 x Beam (34 cm)
  • Servo motor horn (5 cm)
  • Lever horn (10 cm)
  • Ping pong ball

this is what parts look like before assembling them:

Electrical Parts

You will need:

  • Arduino (Nano)
  • Servo motor
  • Sharp sensor
  • Cables and jumper
  • Breadboard

The wiring should be the following:

LabVIEW

First of all, you should know how to establish correct communication between Arduino and Linux. If not, check this link.

So a basic dashboard for the control system should look like this:

You should adjust the control parameters with the correct values.

If you want to no more how to determine these coefficients, navigate to this link.

Code

LINX_-_BallAndBeam_v8.viLESS
No preview (download only).

Custom parts and enclosures

Assembly
Uploads2ftmp2f4dd163ba 1f33 40e8 98f6 474f142a25402fimg 20190410 170818 efda76esaj ydq2yuqi1h
Showcase 1
Uploads2ftmp2ffa71dc43 3fc0 470b a950 9ca1eb5428b52fimg 20190410 180314 xpeblb3ijh ov9vvoiyqm
Showcase 2
Uploads2ftmp2f9deec195 2919 40aa b487 3f298495ed712fimg 20190410 182131 07vwxbnwfu cvlufymq4d
Showcase 3
Uploads2ftmp2f32bbdeaf 45c6 4eb5 939e 3eee07c064d12fimg 20190415 153526 ppdnclog0q kj8rb5izha

Schematics

Communication
Uploads2ftmp2f2b38d371 9481 4d92 a0eb b489d4d6db412f3 flex9s7od5 ddea7mdtgk
Why Sharp sensor?
Uploads2ftmp2fcada0e7d cf78 4a55 85c2 5175c77fcaf62fcapture k6ar0lolwc dib6oqkk9r

Comments

Similar projects you might like

Ball and Beam

Project tutorial by Karem Ben Chikha

  • 1,354 views
  • 0 comments
  • 5 respects

RTC Bird Feeder

Project tutorial by Kutluhan Aktar

  • 2,599 views
  • 4 comments
  • 10 respects

Laser Beam Alarm

Project in progress by mmgamitoc and Vrcg03

  • 4,838 views
  • 6 comments
  • 15 respects

Arduino Ping Pong Ball Cannon

Project showcase by Gord Payne

  • 2,138 views
  • 2 comments
  • 6 respects

Arduino Marble Maze Labyrinth

Project tutorial by AhmedAzouz

  • 7,284 views
  • 9 comments
  • 33 respects

Remote Controlled Pet Feeder

Project tutorial by Amal Mathew

  • 5,776 views
  • 1 comment
  • 30 respects
Add projectSign up / Login