MECH 400 Adam Schuetze:

Slides:



Advertisements
Similar presentations
EMS1EP Lecture 8 Pulse Width Modulation (PWM)
Advertisements

EMS1EP Lecture 9 Analog to Digital Conversion (ADC) Dr. Robert Ross.
Servo Background Servos provide control of rotary position Servos are used extensively in the remote control hobby world for: Aircraft (flaps, ailerons,
Anurag Dwivedi & Rudra Pratap Suman.  Open Source electronic prototyping platform based on flexible easy to use hardware and software.
SPI Serial Peripheral Interface. SPI Serial Peripheral Interface is communication between two devices, one bit at a time sequential one bit at time over.
Chapter 2 Digital Electronic Signals and Switches 1.
Controller Design for a Linearly Actuated Suspension System (cdlass) Dan Altman, Tim Reilley & Joseph Sholl Advisors: Prof. Gutschlag & Prof. Anakwa.
EML 2023 – Motor Control Lecture 4 – DAQ and Motor Controller.
BME/ECE 462 Presentation II Arduino basics & Visual display Yue Yin & Chenchen Qi 09/18/2014.
Active Suspension System Test Platform Bradley University Department of Electrical & Computer Engineering By: Craig Chan & Olusegun Michael Abidoye Advisor:
Lecture. Outline Bits Gates Combinatorial Logic Spice Hands-On Stuff.
MECH 400 Underwater Glider Design Project May 20, 2008MECH 400 Tips and Tricks1.
ECE 3110: Introduction to Digital Systems Instructor: Dr. Omar Elkeelany Tel: Course web:
ECE 265 – LECTURE 13 Interface to switches and LEDs 7/3/ ECE265.
Car RamRod Bringing Pinball Into the Future! Brian Arment, Ryan Hunter, Aaron Shoaf.
ECGR-6185 Advanced Embedded Systems University Of North Carolina at Charlotte A. Srinivas Reddy Stepper/Servo/DC Motors.
Chapter 8 Output Modules.
PLC Fundamentals Module 2: Hardware and Terminology.
Digital I/O Connecting to the Outside World
Module 2: Hardware and Terminology
Basic Circuits – Lab 2 Arduino and Sensors Xmedia Spring 2011.
Engineering 1040: Mechanisms & Electric Circuits Fall 2011 Introduction to Embedded Systems.
Image of Arduino. Arduino discussion Address issues with circuit walk-through – Electricity, Programming, Arduino Concepts Work on BeatTable (next week)
Audio Players 1 Audio Players. Audio Players 2 Introductory Question Audio players record sound in digital form but play it in analog form. The transformation.
Arduino Josh Villbrandt February 4, Digital Circuits Analog versus digital – What’s the difference? – How to represent an analog signal in a computer?
OOPic Programming Fundamentals Compiled vs. Interpreted programs –Compiled program converts high level code into native machine language e.g., y=x+5; Machine.
Segway Controller Notes. = connection on top layer of circuit board = connection on bottom layer of circuit board Ground Plane: Areas enclosed by the.
Rowan Hall 238A April 09, 2006 Sophomore Clinic ENGR , CRN Integrating the PIC and the H- Bridge.
1 ARM University Program Copyright © ARM Ltd 2013 General Purpose I/O.
Presentation of the DriveLab Board Opal-RT Real-time institute 2009.
OOPic (Object Oriented Pic) Dominick D’Aniello Jacques Bosman.
CHAPTER 2: TYPES OF CONTROLLER
CBC BODY COMPUTERS CHAPTER 12. CBC OBJECTIVES H ANALOG AND DIGITAL VOLTAGE SIGNALS H COMPUTER COMMUNICATION H COMPUTER MEMORY H INPUTS H OUTPUTS H MULTIPLEXING.
Good LED Circuit 5V0 GND. What Voltage Does Meter See? Answer: 5 V.
Chapter 12 : Field – Effect Transistors 12-1 NMOS and PMOS transistors 12-2 Load-line analysis of a simple NMOS amplifier 12-3 Small –signal equivalent.
Automatic accident avoiding system PROJECT MEMBERS MUTHUKUMAR.K (05ME33) SAKTHIDHASAN.S (05ME39) SAKTHIVEL.N (05ME40) VINOTH.S (05ME56) PROJECT GUIDE:
ELECTRONIC SYSTEMS ENGINEERING TECHNOLOGY TEXAS A&M UNIVERSITY Innovating tomorrow’s products and systems today Krisys Technology Krisys Robot Sensor Board.
CSE Fall Introduction - 1 What’s Inside the Buffer? IhIh IlIl Write Reg This device always “drives” either high or low. Current is a function.
Arduino Circuits and Code. int ledPin = 9; void setup() { pinMode(ledPin, OUTPUT); } void loop() { digitalWrite(ledPin, LOW); delay(1000); digitalWrite(ledPin,
SAMPLE AND HOLD CIRCUIT. CIRCUIT CONSTRUCTION The circuit samples the input and holds the last sample until the input sampled again. The circuit has an.
Electrical Characteristics of Logic Gates Gate Characteristics Last Mod: January 2008  Paul R. Godin.
PROGRAMMABLE LOGIC CONTROLLER
How do ABI test Digital ICs?. Test principles ABI digital tests are designed to find faults on boards. To do this the following principles are used: Confirm.
ECE 101 Exploring Electrical Engineering Chapter 7 Data Acquisition Herbert G. Mayer, PSU Status 11/30/2015 Derived with permission from PSU Prof. Phillip.
Proportional and Servo Valves
Electrical signaldigital signal Actuators and acting.
WHY PARALLEL PORT? The simplest computer controlled robot Requires only basic programming skills in C to start off with Can take inputs from your robot.
Arduino Application: Speed control of small DC Motors
INTERFACING HARDWARE WITH MICROCONTROLLER GUIDED BY: Prof. ASIF SIR 1. AKSHAY KIRAN 2. DEEP PARIKH 3. JIGAR PATEL 4. TILAK PATEL ,05,D2D06,09.
Zilogic Systems 1 Device Interfacing with Python and ZIO Zilogic Systems.
Zilogic Systems 1 Device Interfacing with Python and ZIO Zilogic Systems.
Arduino based Automatic Temperature Controlled Fan Speed Regulator.
Lesson 1 PLC BASICS. PLC Definition  Programmable Logic Controllers are industrial computers that control machine and other applications.  PLC have.
4. Operational Amplifiers
Intro to USB-6009 DAQ.
Outline Introduction to digital-to-analog converter (DAC)
Using Arduino to modify RC controls Nick Carter 12/31/2015
What’s Inside the Buffer?
Project Members: M.Premraj ( ) G.Rakesh ( ) J.Rameshwaran ( )
Interfacing different devices & considerations
How to avoid catching things on fire.
Introduction to Arduinos
ARDUINO     What is an Arduino? Features 14 Digital I/O pins 6 Analogue inputs 6 PWM pins USB serial 16MHz Clock speed 32KB Flash memory 2KB SRAM.
Lesson 9: Digital Input-Output Signal Interfacing
On/Off Control (bang-bang) Proportional Control
Sensors and actuators Sensors Resistive sensors
Actuators and acting electrical signal digital signal.
ACOE347 – Data Acquisition and Automation Systems
Robotics System Lecture 11_12: DC Motor
Presentation transcript:

MECH 400 Adam Schuetze:

Outline for today Motor control with a Pololu MD03A Solenoid control with a MOSFET Digital input hardware Pressure sensor acquisition with a SenSym ASDX Sequential versus event driven controller

Motor control with a Pololu MD03A Encapsulate with oUserClass object: oUserClass Motor = New oUserClass(“MD03A.osc”); Create an interface to access motor functions Motor.cw(127); Motor.ccw(127); Motor.stop; Hide technical details inside the object oPWM and oDio1 objects

Motor control with a Pololu MD03A MD03A.osc oPWM pwm = New oPWM; oDIO1 inA = New oDIO1; oDIO1 inB = New oDIO1; sub void Config(bit motor_num){ ooPIC.PullUP = cvTrue; pwm.Operate = cvOff; pwm.IOLine = motor_num; pwm.DutyCycle = 0; pwm.PreScale = 2; pwm.Period = 255; if (motor_num == 0){ inA.IOLine = 26; inB.IOLine = 27; } else { inA.IOLine = 24; inA.IOLine = 25; } inA.Direction = cvOutput; inA.State = cvOff; inB.Direction = cvOutput; inB.State = cvOff; pwm.Operate = cvOn; } sub void stop(void){ inA.State = cvOff; inB.State = cvOff; pwm.DutyCycle = 0; } sub void cw(byte speed){ inA.State = cvOn; inB.State = cvOff; pwm.DutyCycle = speed; } sub void ccw(byte speed){ inA.State = cvOff; inB.State = cvOn; pwm.DutyCycle = speed; }

Motor control with a Pololu MD03A

oUserClass Motor = New oUserClass("MD03A.osc"); const FWD_SPEED = 127; const REV_SPEED = 127; const FWD_BUTTON = 5; const REV_BUTTON = 6; const STOP_BUTTON = 7; const MOTOR_PORT = 0; oButton ForwardButton = New oButton; oButton ReverseButton = New oButton; oButton StopButton = New oButton; oWire ForwardWire = New oWire; oWire ReverseWire = New oWire; oWire StopWire = New oWire; oEvent Forward = New oEvent; oEvent Reverse = New oEvent; oEvent Stop = New oEvent; Sub void Forward_CODE(void){ Motor.cw(FWD_SPEED); } Sub void Reverse_CODE(void){ Motor.ccw(REV_SPEED); } Sub void Stop_CODE(void){ Motor.stop; } sub void main(void){ OOPIc.Delay = 1000; Motor.Config(MOTOR_PORT); ForwardButton.IOLine = FWD_BUTTON; ReverseButton.IOLine = REV_BUTTON; StopButton.IOLine = STOP_BUTTON; ForwardWire.Input.Link(ForwardButton); ForwardWire.Output.Link(Forward.Operate); ReverseWire.Input.Link(ReverseButton); ReverseWire.Output.Link(Reverse.Operate); StopWire.Input.Link(StopButton); StopWire.Output.Link(Stop.Operate); ForwardWire.Operate = cvTrue; ReverseWire.Operate = cvTrue; StopWire.Operate = cvTrue; }

Solenoid control with a MOSFET To drive a solenoid with logic-level power, you can use an n-channel logic level MOSFET When digital output pin is high, gate is saturated

Solenoid control with a MOSFET Encapsulate with oUserClass object: oUserClass Valve = New oUserClass(“Solenoid.osc”); Create an interface to access solenoid functions Valve.Open; Valve.Closed; Valve.Invert; Hide technical details inside the object oDio1 object

Solenoid control with a MOSFET Solenoid.osc oDio1 Coil = New oDio1; sub void main(void){ } sub void Config(Byte IOPort){ Coil.IOLine = IOPort; Coil.Value = 0; Coil.Direction = cvOutput; } sub void Open(void){ Coil.Set; } sub void Closed(void){ Coil.Clear; } sub void Invert(void){ Coil.Invert; }

Digital input hardware Pull-up resistor circuit Size resistor to limit current into signal pin to ~1 mA When circuit is open, signal reads 5V When circuit is closed, signal reads 0V

Digital input hardware Encapsulate with oUserClass object: oUserClass LimitSwitch = New oUserClass(“DigIn.osc”); Create an interface to access functions LimitSwitch.Config(); oByte State = New oByte; State = LimitSwitch.State; Hide technical details inside the object oDio1 object

Digital Input Hardware DigIn.osc oDio1 Hardware_Object = New oDio1; sub void main(void){ } sub void Config(Byte IOPort){ Hardware_Object.IOLine = IOPort; Hardware_Object.Value = 0; Hardware_Objectl.Direction = cvInput; } function Bit State(void){ State=Hardware_Object.Value; }

Pressure sensor acquisition with a SenSym ASDX Analog device with three conductors: +Vs (power to the device) Vout (signal from the device) GND Manufacturer specifies V/psi Calibration is useful to confirm response Use oA2D10 object Other analog input devices can be treated the same

Pressure sensor acquisition with a SenSym ASDX Encapsulate with oUserClass object: oUserClass Depth_Sensor = New oUserClass(“SenSym.osc”); Create an interface to access solenoid functions oWord TheDepth = New oWord; TheDepth = DepthSensor.Depth Hide technical details inside the object oA2D10 object

Pressure sensor acquisition with a SenSym ASDX SenSym.osc oA2D10 PressureSensor = New oA2D10; sub void Config(Byte IOPort){ PressureSensor.IOLine = IOPort; PressureSensor.Operate = cvTrue; } //Returns depth in centimeters function Word DepthCM(void){ Word Signal; Signal = PressureSensor.Value; if (Signal < 102) {Signal = 102;}; DepthCM = ((Signal* )*10)/153; } function Word Voltage(void){ Voltage = PressureSensor.Value; }

Pressure sensor acquisition with a SenSym ASDX oUserClass DepthSensor = New oUserClass("SenSym.osc"); oWord TheDepth = New oWord; oWord TheSignal = New oWord; sub void main(void){ DepthSensor.Config(4); while (1){ TheDepth.Value = DepthSensor.DepthCM; TheSignal.Value = DepthSensor.Voltage; }

Sequential versus event driven controller sequential control scheme if and while loops state machines VERSUS Event driven virtual circuits oWire, oEvent, oCompare

Summary of today Motor control with a Pololu MD03A Solenoid control with a MOSFET Digital input hardware Pressure sensor acquisition with a SenSym ASDX Sequential versus event driven controller