cdio-oriented inverted pendulum control ... ... proceedings of the 8th international cdio...

Click here to load reader

Post on 13-Mar-2020

9 views

Category:

Documents

0 download

Embed Size (px)

TRANSCRIPT

  • Proceedings of the 8th International CDIO Conference, Queensland University of Technology, Brisbane, July 1 - 4, 2012

    CDIO-ORIENTED INVERTED PENDULUM CONTROL PROJECT FOR

    UNDERGRADUATE ENGINEERING STUDENTS

    John Gallagher and Bill Goodwine

    Department of Aerospace & Mechanical Engineering, University of Notre Dame, USA ABSTRACT This paper presents the design of an undergraduate pendulum feedback control project. The project is low-cost, significantly less expensive than commercially-available systems, and the project based upon it requires, and hence reinforces, substantive understanding of the physics and control-theoretic aspects of the problem in order for students to complete it. This paper presents the pedagogical purpose behind the project experience for the students and also many details of the physical design of the system and the software control system so that it will be straight-forward to replicate elsewhere. This paper is indented to contribute to the “CDIO Knowledge Library” to facilitate projects that implement the “design” and “implement” components of CDIO, with the future goal of extending the scope of the project to include the “conceive” and “operate” components. In order to accomplish this goal, a significant portion of this paper must present the technical aspects of the project which is integral with and shares equal footing with the broader pedagogical goals. KEYWORDS Project-based learning, active learning, feedback control. INTRODUCTION

    This paper presents an undergraduate controls project platform and associated project outline intended to enhance student learning by appropriately requiring them to work though all the steps necessary to implement a digital feedback controller on a real physical system. In the form described in this paper, students are given a physically-assembled system and their task is to design and implement a feedback controller to stabilize the pendulum in inverted configurations. In order to accomplish that objective, students must be able to write programs for the microcontroller, perform system identification, use appropriate analysis tools and insight to design a feedback controller, convert the controller to a discrete-time controller, write a program to instantiate the controller, download and run the controller and systematically test and evaluate the performance on the controller. Because the project is independent of homework and other course materials, it provides an independent context in which students must master certain elements of the course material in order to successfully complete. In the implementation described in this paper, students work in teams, but the project could also be performed individually. As described in detail subsequently, the system is comprised of the following components:

    • the pendulum, which is actuated by a dc motor with an associated optical encoder,

  • Proceedings of the 8th International CDIO Conference, Queensland University of Technology, Brisbane, July 1 - 4, 2012

    • an H-bridge current supply controlled by a pulse-width modulation input signal, • a commercially-available microcontroller board, based on the Motorola/Freescale

    HC11-series 8-bit microprocessors with a serial port interface, and • an interface board, which contains the circuitry to interface the microcontroller with

    the H-bridge and optical encoder. Programs executed on the microcontroller are written and compiled on a workstation, and can be downloaded to the EEPROM on the microcontroller board via a serial port. It is well-established that active and reflective learners are not well served by traditional university engineering lectures [ 1 ]. As such, there is wide recognition that project-based experiences enhance both student satisfaction, learning and retention [ 2 ]. Active learning is, of course, an element of the broader framework of the CDIO initiative and this project was specifically designed with the purpose of the CDIO Initiative and related engineering education goal in mind. In the Department of Aerospace and Mechanical Engineering at the University of Notre Dame, this project has been implemented in AME 30315, Differential Equations, Vibrations and Control II. This course is required in both the Aerospace Engineering and Mechanical Engineering Programs. Nominally, students take this course in the spring semester of their third year; however, if a student has Advanced Placement credit for the first two calculus courses in their Program, they may take the course during the spring of their second year. Mechanical Engineering students typically concurrently take EE 20222, Introduction to Electrical Engineering and Embedded Systems, a significant portion of which considers programming embedded microprocessors. Hence, the majority of the Mechanical Engineering students have programming experience relevant to successfully completing the project and typically third-year Mechanical Engineering students comprise a majority of the students enrolled in AME 30315. Hence, in the Spring of 2012, the project was assigned as a group project, with typical groups of two students, one of whom was a Mechanical Engineering student who had either completed EE 20222 or was concurrently enrolled in it. In the Spring semester of 2012, AME 30315 had approximately 130 students enrolled and ten pendulum platforms were constructed and stored in the Stinson-Remick Hall of Engineering where students would have 24/7 access to the projects. A web page for the Spring, 2012 implementation of the project was developed to guide the students through the project [ 3 ]. PROJECT DESIGN AND LEARNING OUTCOMES As indicated previously, the student experience in the project is designed such that a necessary condition for successful completion of the project is substantive understanding of system identification and modelling, feedback control analysis and design, embedded systems programming and post-design validation of the design. The project may be divided into five sequential steps:

    1. an introductory step where students become familiar with the system, including operating the hardware, compiling programs, downloading the programs to the microcontroller and executing the programs,

    2. system identification where a student-written program controls the system in a stable mode (with the pendulum hanging “down”) and the step response of the system is obtained and analysed to determine a second-order transfer function for the system, which is then modified to represent the pendulum when it is in the unstable configuration (pointing “up),

    3. feedback controller design and analysis using root locus and other analysis techniques,

    4. controller software programming, which requires converting the controller design to a discrete-time transfer function and implementing it in the C programing language, and

  • Proceedings of the 8th International CDIO Conference, Queensland University of Technology, Brisbane, July 1 - 4, 2012

    5. running the feedback controller on the pendulum in an unstable configuration and analysing and validating the performance of the controller design.

    A detailed description of each of these steps is presented subsequently in this paper. Student outcomes for the course are enhanced by this project. Specifically, after completing the project, students will be able to:

    1. download a program saved in an S-record format (an .s19 file) to the EEPROM on the microcontroller board and configure the system to execute the program,

    2. write a computer program in the C programming language to execute on the microcontroller including:

    a. programming and handling interrupts (both output-compare and pulse- accumulator interrupts), and

    b. determining the status of microcontroller input pins through bit-masking, 3. perform a system identification and validation procedure on the pendulum by

    commanding a step input when then pendulum is in the stable (down) position and modifying the model obtained to apply to the unstable (up) position of the pendulum,

    4. use the model identified to analyze appropriate feedback controller designs, including accounting for modelling errors such as unmodelled geometric nonlinearities and friction,

    5. design, program and verify a lead compensator to satisfy transient response specifications for the system, including quantified rise time, settling time and overshoot,

    6. design, program and verify a lag compensator to satisfy steady-state specifications for the response of the system,

    7. design a lead-lag compensator to satisfy transient and steady-state specifications, with recognition of the trade-offs between them, and

    8. operate and validate their controller design. This project involves a significant number of elements of the CDIO Syllabus [ 4 ]. In particular, in version 2.0 at the second level of detail, this project incorporates

    1. system identification, model simplification and model validation incorporates elements from sections 1.1, 1.2, 1.3, 2.1 and 2.2,

    2. controller design incorporates elements from sections 1.1, 1.2, 1.3, 2,1, 2.3 and 4.4, 3. implementation of the design incorporates elements from 2.1-2.4 and 4.5, 4. validation and analysis of performance incorporates elements from 2.1-2.4 and 4.6,

    and 5. if implemented in teams with reporting requirements, the project further incorporates

    elements from 3.1, 3.2 and 4.7. STUDENT EXPERIENCE PROJECT DESIGN This section presents the details of each of the steps the students must perfo