Bradley University Electrical Engineering Department
SAE Formula CarData Acquisition & Display System
April 9, 2015
Advisor : Professor Steven Gutschlag
Ahmed Albitar John Gertie
Justin Ibarra Sean Lenz
Agenda• Problem statement
• Background
• System block diagram
• Division of labor
• Project non-functional requirements
• Project functional requirements
• Discussion of individual contributions
• System test results
• Summary & conclusion2
3
Problem Statement
Every year the Mechanical Engineering department at Bradley University designs and constructs a formula racing car. Past performances have proven to be inconsistent due to engine failures and structural breakdowns. To improve future performance, an advanced data acquisition system will be employed to indicate problems before a failure occurs. Unlike the existing system, data will be monitored by both the driver and the crew. A touch screen mounted in the vehicle will display data and warning signals to the driver. The same data will also be transmitted to a computer, where it will be recorded for diagnostic evaluations. Multiple indicators will be used to warn the driver and crew if data readings exceed a safe limit.This system will provide the necessary information to optimize the formula cars performance, giving Bradley’s mechanical engineering department an edge over the competition.
Problem Description
• Acquire 5 Key data values from SAE Formula Car
• RPM
• Speed
• Oil Pressure
• Water Temperature
• Battery Voltage
• Aggressive Notification system to alert driver if data exceeds threshold values
• Multi-mode touch screen display
• Wireless transmission of data to off-track computer
• Data Logger 4
5
Background
• Design goals
• Aesthetically pleasing
• Economically viable
• Race ready performance
• User friendly for all levels
• '07-'10 Honda CBR600RR engine
• Total budget of $10,000
System Block Diagram
Sensors
Microcontroller
(ATmega128)
Amulet LCD
Wireless Transceive
r
UART
RS-232
Laptop(LabVIEW
GUI)UART
5V Power Supply
6
Division of Labor
• Ahmed
• Sensor selection & interfacing
• Justin
• Amulet display
• Justin & John
• Interface microcontroller with HyperTerminal
• Test microcontroller with simulated sensor data
• Interface microcontroller with LabVIEW
• Sean
• Prepared LabVIEW to receive wireless data
• Interface microcontroller with Amulet
• Setup external power supplies for the microcontroller, Amulet, and Op-Amps7
System Block Diagram
Sensors
Microcontroller
(ATmega128)
Amulet LCD
Wireless Transceive
r
UART
RS-232
Laptop(LabVIEW
GUI)
UART
5V Power Supply
Ahmed
Sean
John & Justin
8
Sean
Project Non-functional Requirements
9
10
Project Functional Requirements
11
Ahmed's Agenda
• Subsystem block diagram
• Pressure and Temperature Sensor Circuitry
• Project functional requirement and specification
• Sensors
• Test result
12
Subsystem Block Diagram
Engine12V
ATmega128
Temperature Sensor
Pressure Sensor
RPM Sensor
Velocity Sensor
Voltage Measurement
13
Pressure and Temperature Sensor Circuitry
14
Functional Requirements and specification
• 12 volts from the car's battery
• Water temperature measured by a temperature sensor
• Oil pressure measured by a pressure sensor
• Velocity and RPM measured by a speed sensor
• Data acquisition maximum error of 5%
• Sensors compatible with engine
15
Temperature Sensor
• ProSense TTD25N-20-0300F-H
• Analog output: 4 to 20mA
• Operating Voltage: 10 to 30VDC
• Temperature range: 0-300 F
• ¼ NPT
• Cable : CD12L-0B-020-A0
16
Pressure Sensor
• ProSense PTD25-20-0100H
• Analog output: 4 to 20mA
• Operating Voltage: 9.6 to 32VDC
• PSI range: 0 to 100
• ¼ NPT
• Cable : CD12L-0B-020-C0
17
RPM and Velocity Sensor
• Supply Voltage: 4.5 - 24 V DC
• Supply Current: 10 mA
• Output Signal: Pulse 0-50 V
• Maximum output current: 20 mA
• Sensing distance: From 0.5 to 2 mm
• Maximum operating Frequency: 100KHz
18
Temperature Sensor Result
• Maximum 5% error
• T = m × Io +k
• m = 10418.75
• k = -59.48 C
• Linear Sensor
• V = Io × Rf (Rf=250 ohms)
T= temperaturem = slopek = Temperature offset
19
Pressure Sensor Result
• Maximum 5% error
• P = m × Io +k
• m = 6250
• k = -25 C
• Linear Sensor
• V = Io × Rf (Rf=250 ohms)
P = Pressurem = slopek = pressure offset
20
RPM Sensor Result
• Maximum 5% error
• F = Frequency
• RPM = F(cycle/sec) (60sec/1min) (1rev/2cycles)
• Linear Sensor
Justin’s Agenda
• Subsystem block diagrams
• Project functional requirements
• Hardware and software used
• Amulet touch screen
• Subsystem test results
• Wireless transmission
21
Subsystem Block Diagrams
22
Oil Pressure Input
Water Temp Input
MPH Input
RPM Input
Batt. Voltage Input
ATmega128ATmega128
Aerocomm AC4790
Amulet Touchscreen
Home Page
Race Mode
Demo Mode
Practice Mode
Aerocomm AC4790
Project Functional Requirements
• Functional Requirement
• Data acquisition sends data for display
• Display accessible to driver
• Specification
• Data can viewed on the touchscreen
• Can be easily seen by driver without posing as a distraction from driving
23
Hardware and Software Used
• Hardware
• Amulet touchscreen
• Laptop
• Atmega128
• Software
• Gemstudio
• Atmel Studio
24
Amulet Touchscreen
• Pseudo data used for demo mode
• Aggressive warning system
• Demo mode sweep
• Navigation between modes
25
Amulet Display Results
• Aesthetics
• Navigation
• Widgets
• Microcontroller communication
26
Home Page
27
Practice Mode
28
Demo Mode
29
Demo Mode
30
Race mode
31
John's Agenda● Subsystem block diagram
● Project functional requirements
● Hardware & software used
● Wireless transmission testing
● Testing with simulated data
● Interfacing with LabView
● Subsystem test results 32
Subsystem Block Diagram
33
Water Temp Input
Oil Pressure Input
MPH Input
RPM Input
Batt. Voltage Input
ATmega128Aerocomm
AC4790
Aerocomm AC4790
LabVIEW Display
34
Project Functional Requirements
35
Hardware & Software Used
Hardware
• Atmega128
• Aerocomm AC4790
• Laptop
Software
• Atmel Studio
• HyperTerminal
• LabVIEW
Wireless Transmission Testing
• Board to board
• Board to HyperTerminal
• Microcontroller to HyperTerminal
36
• Linear Output• Oil Pressure, Water Temperature, Battery Voltage
• Simulated with Power Supply
• Pulse Output• Tachometer, Speedometer
• Simulated with the Wave Generator
Testing with Simulated Data
37
• Communication Protocol
• Universal Asynchronous Receiver/Transmitter(UART)
• Transmission Type
• Ascii
• Sent using packets
Interfacing with LabView
38
39
Subsystem Test Results
• Wireless communication established
• Microcontroller communication with HyperTerminal
• Data displayed is current
• Values displayed in ascii equivalent
40
Sean’s Agenda
• Functional requirements
• Subsystem block diagram
• Equipment used
• Interface Amulet with microcontroller
• Prepare LabVIEW to display wireless data
• Results
41
Functional Requirements & Specifications
Functional Requirements
Specifications
Display data to driver and pit crew
Touchscreen display
Store data for review UART communication
Does not interfere with driver performance
5 V power supply
No loose or exposed wires Display real time data
42
Subsystem Block Diagram
Microcontroller
(ATmega128)
Amulet LCD
Data From Wireless
Transceiver
UART
RS-232
Laptop(LabVIEW
GUI)
5V Power Supply
Hardware & Software
Equipment• Amulet LCD
• ATmega128 (microcontroller)
• DC/DC converter (
• Level shifter (+5 [V] to +3.3 [V])
• Laptop
• Oscilloscope
Software• GemStudio Pro (Amulet
display software)
• Atmel Studio 6.1 (microcontroller software)
• LabVIEW 2014
43
44
Amulet Subsystem Bl0ck Diagram
Microcontroller
Put Sensor Data in Array to Transmit
Send Data Array
Amulet Touchscreen
100 ms interrupt
UART
5V Power Supply
45
Amulet LCD• Serial Protocol
• UART
• Ascii
• 9600 bps baud rate
• Transmit specific protocol to access variables
• Microcontroller is master
• Initializes communication
• Amulet is slave
• Full Protocol- Responds only if Amulet receives valid message
46
Amulet LCD
• Internal RAM (IR) is memory on the Amulet.
• 256 byte variables
• 256 word variables (word = 2 bytes)
• Can receive 14 different command messages from microcontroller
• Can access internal RAM on Amulet
• Changing and copying variables
• Jump to different pages on display
• Draw pixel, line, or box
Amulet Serial Communication Flow Chart
Op-code
Variable Address
(High nibble)
Variable Address
(Low nibble)
Variable Value(High
nibble)
Variable Value(Low
nibble)
Op-code = Tells Amulet what type of variable is being accessed
(byte or word)
Address = The variables location on the RAM of the Amulet LCD
Value = The data to be displayed on the Amulet LCD
Figure 1 – Transmit protocol for a byte variable.
47
LabVIEW Subsystem Bl0ck Diagram
48
Put Sensor Data in
Transmission Array
Send Array Data
LabVIEWI/O Assistant(Parse Data)
100 ms interrupt
RS-232
Log Data
LabVIEWGauge Display
49
LabVIEW Display
• Serial Protocol
• RS-232
• Ascii
• 9600 bps baud rate
• Transmit packets of data
• Instrument I/O Assistant
• Front Panel vs. Block Diagram
• Connect blocks to data type and viewing method
Aerocomm
Transceiver
Laptop(LabVIEW Display)
Instrument I/O
Assistant
Display Data
Save Data
50
Front Panel
Serial Communication Setup
51
52
Block Diagram
53
54
Subsystem Results
• Successful interface between ATmega128 and Amulet LCD• Data sent and displayed on the Amulet LCD
• Successful interface between Aerocomm Transceiver and LabVIEW GUI• Data sent, displayed, and stored on the LabVIEW GUI
55
System Test Results
• Display data to driver with aggressive notification system
• Race, demo, and practice modes
• Wirelessly send data to pit crew’s laptop to be displayed on LabVIEW
• Data logged via LabVIEW
• Sensor’s acquire data with max error under 5%
56
Summary & Conclusion
• BU ME’s require more advanced notification system for driver
• Requires data logging, multiple display modes, and wireless transmission
• System is functional
• Requires installation and further testing
57
Sources
• http://cegt201.bradley.edu/projects/proj2011/pjacher/SAEDAQ/Deliverables_files/SAEDAQ_final_report.pdf
• http://www.atmel.com/images/doc2467.pdf
• http://www.amulettechnologies.com/images/stories/Downloads/mk480272cdatasheet1112.pdf
• https://www.dropbox.com/s/l8abp41iru83oqg/Datasheet_carspd_eng_101.pdf?dl=0
• http://www.automationdirect.com/static/specs/prosensettrans.pdf
• http://www.automationdirect.com/static/specs/prosensetransmitters.pdf
Appendix
58
Initialization
59
ISR
60
.C/.h files
61
to_ascii
62
Amulet Ascii Transmit Protocol Example
MicrocontrollerSet Byte Variable
Amulet Response
MicrocontrollerSet Word Variable
Amulet Response
Figure 2 – Serial communication flow chart 63
64
Amulet Protocol AsciiExample: microcontroller sets internal RAM (IR) word variable to specific value (0x02C9)
Figure 3 – Serial communication flow chart
65
UART Transmit
• 1V per division
• 0.5ms per division
• Transmission contains:
{0x00, 0xD6, 0x31}
66
67
68
Maximum data log time
• Limited by max rows in excel• Max rows about 1 million
• Log data every 100 [ms]
• Max time = 27.8 hours
• 0.1 [sec/row] *1.2E6 [rows] = 100,000 sec
• 100,000 [sec] /60 [sec/min] /60 [min/hr] = 27.8 hrs
69
Max Transmission Rate with 9600 bps Baud Rate
• 1 bit sending time:
• 1/9600 = 104 us
• Assume 16 byte packet
• 8 bits + 1 start_bit + 1 stop_bit = 10 bits/byte_sent
• 104 [us/bit] * 10 [bits/byte] * 16 [bytes/packet] = 16.6 [ms/packet]
70
Research
• Amulet serial communication protocol
• LabVIEW Instrument I/O Assistant
• Troubleshooting errors
71
72
73
74
75
76
77