MEC2406 Assignment 2
Students will construct a device and program a microcontroller to solve a specific control task. The task will encompass problems such as accuracy, speed, and efficiency. More details of the assignment can be found below.
This assignment is worth 40% of the total course marks (400 marks). Please clarify and state any assumptions with the course examiner.
You are to submit one PDF file for your report (max 10 single sided pages including figures), one video file (.mp4) and one .INO file containing your code. No other special libraries are to be used, apart from the ones provided to you in this course or as approved on the studydesk. Please check marking criteria to make sure you have not missed anything.
SALLY’S PLAYGROUND ROUNDABOUT UPGRADE
Sally owns a playground equipment company that has had several safety incidents reported on the roundabout equipment she sells. Children are spinning around too fast and injuring herself. She has hired you to design and build a roundabout playground that can control the speed of the rotation of the roundabout. Sally wants you to design a system that will ensure the angular velocity can be controlled accurately to safely change the speed accordingly, however she wants to keep the ability for the kids to start and stop the roundabout as they normally do. She noted the idea of ballet dancers and how they can control their rotational speed using stretching out their arms and legs and vice versa, as shown in Figure 2.
You as a Mechatronics expert are to design, build and program a control system to keep Sally’s roundabout rotating at a certain angular velocity, and be able to adjust the rotational velocity to a desired value. The more stable and more responsive it is to commands, the better.
You will need to purchase parts for you to complete the task, check the parts you require using the Parts List pdf on the Studydesk. A general assembly guide of the parts is shown below in Figure 3, however, you are free to do your own design if you wish. You are required to justify the design choice and component positioning either way.
There are some parts/components that you may have to acquire, please ensure you have them prepared before starting. Feel free to substitute parts you already may have.
Some things to note in the hardware design:
• Ensure that the system weight is balanced along the correct axes. I suggest using some bearings to limit the movement only rotate in one axis. Disassembling some fidget spinners are a good option for this.
• Ensure the plate spinning and the Arduino/batteries are centrally located so that your movement of the weight can have better control.
• You may need to play around with materials and designs to get optimal control. Try to avoid making certain parts too heavy – balsa wood is pretty good and rigid and can be modified easily.
• If the servo motor cannot hold the weight, a linear guide may need to be constructed with a low friction. This way the motor is only moving the weight, not holding it. Experiment!
Control System Design
Control of the weights position will be done via a servo motor attached to the weight. The angular velocity with will be set to change as stated in ‘What is needed’ below. To do this, we will need to create a control system with an inertial measurement unit attached to the spinning body. The control system will adjust the position of the weight by commanding the motor to move the appropriate angle. The movement of the weight will then theoretically control the rotation velocity of the system. When choosing control parameters PID, try to observe system’s response and adapt, or use some PID tweaking methods, rather than just guessing. As always, please record and note observations in your video and report.
What is needed
1. Video of control system in action with detailed commentary (no more than 5min) of what is happening (explain the control dynamics such as overshoot, undershoot, etc.) uploaded to youtube.com, with a link in your report. Please ensure it is clear enough to see the stable system and responsiveness of the system. Place an object/diagram/figure below the system (with angles marked out) to help show relative movement.
a. Phase 1 – Demonstrate that the motor angles can be controlled via the code, move the servo motor to a 45-degree angle and then to a 160-degree angle.
b. Phase 2 – Demonstrate that the inertial measurement unit is reporting the correct rotational velocity, time number of rotations and find out the average velocity to compare.
c. Phase 3 – Demonstrate the system without any control in place (just moving motor to fixed positions) showing the position of weight and how it affects the rotational speed of your system.
d. Test 1 – Start the system at a chosen rotational velocity, weight should closest to centre. Capture angular velocity and delay for 5 seconds then set the angular velocity to a slower velocity and let the control system hold the slower rotation velocity for 10 seconds.
e. Test 2 – Start the system at a chosen rotation velocity, the weight should be in a position so that it can speed up and slow down the rotational velocity. Get your control system to speed up the rotation velocity and hold for 5 secs, then slow down your rotation velocity and hold for 10 secs.
f. Try introducing or removing some rotational velocity using external forces (moving the table/base or through manual manipulation). Be very careful and gentle with your motions to avoid instability.
2. Report of system (10 single sided pages max including figures) containing:
a. Aim/Summary – include your video link on the title page please!
b. Design choice and justification. Include an overall system block diagram here!
c. Flowchart block diagram of your software plus brief explanation of main sections.
d. Control system – Draw a feedback block diagram and discuss the way in which you determined the control parameters, with respect to control system’s response you observed. I.e. overshoot, settling times, etc.
e. Reflection – what went wrong and why, how might you look to improve the system overall.
3. RAW Arduino Code(.ino file) – commented code so that each part that you wrote is explained and follows your flowchart in 2b.
10 W% Accomplished
(High Distinction) Developing
(Distinction) Developing (Credit) Benchmark
10% Well-structured and logical, easy to understand. The work is clearly
Some logical issues.
The structure of the work
is evident, but some
systems are not
The work presented can
be followed, but has no
and construction of sentences and links between
the different parts are lacking.
25% Flowchart clear and easy to
understand, no missing blocks.
Comments are clear and not overly obtrusive. Flowchart contains main
blocks and flow.
Comments are mostly
complete. Some details missing. Flowchart contains general flow, either
missing detail or at a too low
level. Some missing comments. Flowchart is very basic, missing lots
of details, parts of chart match code.
Code briefly commented, some structural issues.
30% Video walks through the
control loop tests clearly and
explains design of system and some reflection.
Control parameters are
tweaked to allow
a good response of the system appropriately. Video walks through the control
experiments but lacks some
control the system
appropriately. Video walks through the control
explanation and some control issues observed. Video shows parts of the control
explanation, partial working system
and control issues observed.
30% The design is well researched and feasible. No conflicting systems.
Sequence of operations is well specified. The design is sound and
feasible. Minor issues only. The design looks to be sound and
some feasibility issues. Some
systems were not well
designed/explai ned. The design looks to be sound. Some
systems were not
well designed or linked well together.
5% Student has reflected well on their design
identifying critical flaws and
possible issues, as well as the
advantages of their design. Student has reflected on their design identifying
critical flaws and possible issues. Student has reflected on their design identifying
some possible issues. Student has reflected briefly on their design,
however, some of the reflection is
disconnected from their design choices.