Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. ·...
Transcript of Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. ·...
![Page 1: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/1.jpg)
Automotive and Aerospace Systems
• Networked control.• Vehicular networks:
• CAN.• TTP, FlexRay, etc.
• Safety and security.
Computers as Components 4e © 2016 Marilyn Wolf
Marilyn Wolf“Computers as Components, 4e”
Chapter 9
![Page 2: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/2.jpg)
Networked control
• Computer networks that perform real-time control functions.• Allows more computing power to be applied than is available from a single
CPU.• Allows processors to be physically near the devices they control.
• Electronic control unit (ECU) is a digital unit in a car.• Line replaceable unit (LRU) is a module in an airplane avionics system.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 3: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/3.jpg)
Vehicles as networks
• 1/3 of cost of car/airplane is electronics/avionics.• Modern cars may have 100+ processors and operate with 100 million
lines of code.• Network applications:
• Vehicle control.• Instrumentation.• Communication.• Passenger entertainment systems.
![Page 4: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/4.jpg)
Example automotive processors
• Infineon XC2200 body control processor:
• 16/32 bit processor.• SRAM and EEPROM.• Analog/digital converter.• Pulse width modulator.• Serial channels.• Light drivers.• Network connections.
• Freescale MPC5767R for powertrain systems.
• Dual-processor Power Architecture CPUs, including vector processors.
• 16K data and instruction caches.• Time processing unit used to
generate and read waveforms.• CAN, Lin, FlexRay interfaces.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 5: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/5.jpg)
Automobile network
• Engine provides power to drive the wheels via the transmission.
• Transmission adjusts gearing based on operating characteristics.
• ABS controls brakes.
![Page 6: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/6.jpg)
Avionics
• Avionics design must be certified.• Architectural evolution:
• Modular architecture has a separate LRU for each function (artificial horizon, engine control, etc.)
• Federated network has networks grouped by function (flight controls, navigation, etc.).
• Genesis Platform defines virtual avionics system that is mapped onto a physical network.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 7: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/7.jpg)
CAN bus
• First used in 1991.• Serial bus, 1 Mb/sec up to 40 m.• Synchronous bus.• Logic 0 dominates logic 1 on bus.• Arbitrated with CSMA/AMP:
• Arbitration on message priority.
![Page 8: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/8.jpg)
CAN data frame
• 11 bit destination address.• RTR bit determines read/write
from/to destination.• Any node can detect bus error,
interrupt packet for retransmission.
![Page 9: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/9.jpg)
CAN controller
• Controller implements physical and data link layers.
• No network layer needed---bus provides end-to-end connections.
![Page 10: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/10.jpg)
Other vehicle busses
• Time-triggered architecture (TTA) assigns communications to time slots.
• FlexRay is next generation:• Time triggered protocol.• 10 Mb/s.
• Local Interconnect Network (LIN) connects devices in a small area (e.g., door).
• Passenger entertainment networks:• Bluetooth.• Media Oriented Systems Transport (MOST).
![Page 11: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/11.jpg)
Safety and security
• Vehicles are safety-critical systems.• Threat models:
• Maintenance technicians may introduce problems either maliciously or accidentally.
• Component suppliers may supply components that don’t work with the system or include malware.
• Passengers may introduce malware either maliciously or accidentally.• Passers-by may connect to vehicle wireless networks.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 12: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/12.jpg)
Car hacking (1)
• UCSD researchers demonstrated a variety of attacks that allowed them to gain complete control of a car.
• Attack vectors:• Infecting diagnostic computers used by mechanics.• Using a specially-coded CD to load malware onto the CD player.• Sending signals over the car’s telematics connection.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 13: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/13.jpg)
Car hacking (2)
• CMU researchers demonstrated a takeover of a Jeep Cherokee driven by a journalist.
• Attack vector:• Entered car through telematics systems.• Entertainment system was then attacked and modified.• Car components did not check the validity of software updates.
• Entertainment system was used to send messages over CAN bus to kill engine, disable brakes.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 14: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/14.jpg)
Car crashes
• Oklahoma court ruled that Toyota was liable in a case of unintended acceleration.
• Electronic throttle control system source code contained 67 functinos with a cyclomatic complexity of over 50; throttle angle function had a cyclomaticcomplexity of 146.
• Car’s fail-safe capabilities were both inadequate and defective.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 15: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/15.jpg)
Airplane hacking
• A computer security researcher was arrested in 2015 on suspicion of having hacked into a Boeing 737 during a flight.
• Attack vector was through in-flight entertainment system.• Allegedly modified code in the Thrust Management Computer.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 16: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/16.jpg)
Software implicated in fatal airplane crash
• Software bugs are suspected to have caused the crash of an Airbus A400M.
• Software in the ECUS are suspected to have caused three of four engines to shut down during flight.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 17: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/17.jpg)
VW diesel defeat
• VW admitted to installing a defeat of its own software on diesel cars.• Defeat enabled strong emissions controls while car was being tested, disabled
emissions controls during normal driving.
Computers as Components 4e © 2016 Marilyn Wolf
![Page 18: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/18.jpg)
Solar Car CAN DevelopmentSenior Design ProjectMike CornelisonBeau EckermannDavid LastAaron SteinerLuke StewartBrian Whitehousev
![Page 19: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/19.jpg)
Sol of Auburn•Student built and maintained vehicle•Runs completely of solar energy•Races long competitions
![Page 20: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/20.jpg)
Problem Description
• Improve method of communication between subsystems of AU solar car
• Allow driver access to new features such as turn indicators, trip odometer, cruise control, etc.
• Provide driver and chase vehicle (via wireless modem) with real-time system information
• Improve vehicle safety by implementing a “safe mode” for powering down in the event of a system fault
• Reduce size, weight, power consumption
![Page 21: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/21.jpg)
Systems
Motor Controller:• Powers the motor• Breaks the vehicle• Monitors the primary electrical systems
Steering and Throttle:• Acceleration• Regenerative breaking• Turing and breaking signals
Display and Power Controls:• Speed• Currents and voltages• Switch bank
![Page 22: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/22.jpg)
The Design Problem
• Bulky wire harness
Adds weightReliability and packaging problemsNoise due to other voltage systems
![Page 23: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/23.jpg)
Solution Idea
Implement a Controller Area Network:• Connect system devices Motor controllerSteering and throttleDisplay
• CAN Advantages:Fewer wire countFailure detection and safe modeWeight lossEasier installation and maintananceDriver safety
![Page 24: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/24.jpg)
Requirements Constraints
• Data handling Speed (1 Mbs)
• Safe Mode for driver safety
• Must run and not exceed 48 watts
• Low current limits• Low power consumption• Lightweight• Functionality• Cheap
![Page 25: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/25.jpg)
The Approach - Overview
• The Controller Area Network• Localized network of independent node devices
• Most commonly microcontrollers• Standardizes communication format, arbitration, and addressing
• Other network layers (i.e. Physical Layer) can be implemented as the designer sees fit• Hardware and Software must be implemented
![Page 26: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/26.jpg)
Overhead Car Diagram
![Page 27: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/27.jpg)
Network Architecture
CAN NETWORK
Steering InterfaceμController Module
Display InterfaceμController Module
Motor InterfaceμController Module
Driver Inputs
Signal Controller
Sensor Inputs
Vehicle Controls
Motor ControllerDriver Display
Wireless Modem
Battery ProtectCircuit
![Page 28: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/28.jpg)
I/O SummaryI/O Name I/O Label Type Source NodSource DevDestination Destination Driver Display display Digital Display - - -
dir Digital Display Switch Motor Motor ContHazard Lights hazard Digital Display Switch Motor Signal ConIgnition Control ignition Digital Display Switch Motor Motor ContMph/kph Toggle mph/kph Digital Display Switch Display InternalThrotle Enable threnable Digital Display Switch Motor Motor ContAuxilary Battery Voltaaux_volt Analog Motor Sensor Display DisplayBreak brake Digital Motor Motor Cont? ?Main Battery Voltage main_volt Analog Motor Sensor Display DisplaySolar Array Current array_amp Analog Motor Sensor Display DisplaySolar Array Voltage array_volt Analog Motor Sensor Display DisplaySpeed Pulse spdpulse PWM Motor Motor ContDisplay DisplayState of Charge SOC PWM Motor Motor ContDisplay DisplayBreak Light brake_light Digital Steering Switch Motor Signal ConCruise Control - cc_down Digital Steering Switch Motor InternalCruise Control + cc_up Digital Steering Switch Motor InternalCruise Control Set cc_set Digital Steering Switch Motor InternalDisplay Control disp_toggle Digital Steering Switch Display DisplayLeft Turn Signal left_turn Digital Steering Switch Motor Signal ConRegen rgn Analog Steering 5K POT Motor Motor ContRight Turn Signal right_turn Digital Steering Switch Motor Signal ConThrottle thr Analog Steering 5K POT Motor Motor Cont
Direction Control
![Page 29: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/29.jpg)
Hardware
• Freescale’s MC9S12C32 microcontroller• Versatile microcontroller core with CAN interface• Plenty of input and output pins• Development hardware (MCU-SDK)• CAN Transceiver (Phillips PCA82C250N)
• Three modules throughout the car• Steering, Motor and Display Interfaces
![Page 30: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/30.jpg)
Development setup
![Page 31: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/31.jpg)
Hardware Schematic
![Page 32: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/32.jpg)
Optrex 20x4 LCD display
![Page 33: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/33.jpg)
Software
• CAN communication• Analog-to-Digital conversion• Push button interrupts• RS-232 communication• Timers• Display
![Page 34: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/34.jpg)
Steering Interface Module (SIM)
• Collects driver inputs• Acceleration, deceleration, brake rate and turn signals
• Analog inputs (ADC)• Two potentiometers and one brake rate sensor
• Momentary switches (Interrupts)• Cruise control, turn signals, brake pedal, display toggle
![Page 35: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/35.jpg)
Motor Interface Module (MIM)
• Analog outputs• Acceleration, deceleration, breaking rate
• Digital outputs• Cruise control, turn signals, brake lights
• Pulse width modulated input communicates motor speed and current• Analog inputs
• Battery and solar array current, battery voltages
![Page 36: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/36.jpg)
Display Interface Module (DIM)
• Input from other modules• Analyzes and outputs information to an LCD display
• Input from bank of eight switches• Switches do not yet have a function
![Page 37: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/37.jpg)
Software
• Sends and receives data over the network• Collects data from car components
• Decide priority structure of data
• Forces car into shut-down “safe mode” if network connectivity has been lost
![Page 38: Automotive and Aerospace Systems - Auburn Universitynelsovp/courses/elec5260... · 2019. 4. 22. · Mike Cornelison. Beau Eckermann. David Last. Aaron Steiner. Luke Stewart. Brian](https://reader033.fdocuments.in/reader033/viewer/2022061001/60b06179a5b20e565470f64f/html5/thumbnails/38.jpg)
Future Work
• Node formation for each subsystem• CAN message hierarchy• RS-232 packetization of streaming data• Safe Mode implementation