electronic automobile fluid level sensor. team members team nick johnston, team leader alex garr,...

Post on 01-Jan-2016

220 Views

Category:

Documents

2 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Electronic Automobile Fluid Level Sensor

Team MembersTeam

Nick Johnston, Team LeaderAlex Garr, Communications CoordinatorDrew CombsDan Dillon

ClientChris Justice

Faculty AdvisorDr. Jiming Song

PlanningProblem Statement

The current method for measuring engine oil level is messy, time consuming, and inconvenient.

Market surveyNo simple replacement for the conventional

dipstick exists.Several measurement methods were considered.Capacitive sensor is small, cheap.

System

System descriptionSensor sends reading to measurement circuitMeasurement circuit sends signal to microcontrollerMicroprocessor determines oil level, displays

readingUser interface tells microcontroller when to read

dataCalibration gets input from user, reads data from

sensor, and stores settings in microcontroller

Concept DrawingBlock Diagram

Functional RequirementsPressing the “measure” button shall return a

reading within 3 secondsThe device shall correctly measure whether

the oil is below, within, or above acceptable limits

The proper LED shall remain lit for 15 seconds

The devices shall provide over 300 oil checks on one battery.

Non-Functional RequirementsSensor components immersed in oil shall

withstand 220° FDevice shall not require any external power sourceDevice shall work regardless of orientationSensor shall not degrade or introduce harmful

substances into the engineUser shall be able to drop in the device in place of

current dipstick with no modification to vehicleAll currents within the device shall not exceed 50

mAAll voltages within the device shall not exceed 3 V

Project PlanMicrosoft Project used to generate work breakdown

DeliverablesProof-of-concept prototypesSensor schematics, PCB layoutsSoftware design documents

Risks involved

Block Diagram

Design Method- Capacitive Sensor

- A sensor which is placed on the end of a dip stick to measure the level of oil through by seeing how much capacitance the sensor outputs.

- Capacitance Measuring Circuit- This circuit uses a 555 timer which is dependent on a sole

capacitive value to create a square wave output. The square wave’s frequency is dependent on the capacitive value and preset resistor values.

- Microcontroller- The microcontroller then is able to count the pulses in the square

wave to determine it’s frequency and the level of oil. The microcontroller will then output the corresponding value to the user interface.

Software Specification

UI Specifications3 LEDs – Red, Yellow, Green

2 Button – Measurment, Hard Reset

red: need >= 1 quartyellow : need ~ ½ quart

green : goodred flash : too much oil

green/yellow flash : measuringAll LEDs flashing : calibrating

measurement button : press to take a measurement, hold to calibratehard reset button : press to reset entire system, possible transient

hardware/software faults

Testing SpecificationSoftware

white boxblack boxcode analysis

Hardwarecomponentsystem

Integration black boxmicrowaveheat

Circuit DiagramThis is the overall circuit which can be separated and examined in 3 different blocks: The microcontroller, the capacitance measuring circuit, and the capacitive sensor

Capacitance Measuring CircuitThe circuit diagram to the left is the capacitance measuring circuit. This circuit uses a 555 timer to create a square wave which is dependent on the capacitance of C4. C4 will be the capacitance gathered from the capacitance sensor. In this way we are able to tell the change in capacitance by relating it to the change in frequency of the output.

Sensor Layout• Cadence Layout Plus used for design drafting.• Narrowest possible traces (6 mil) to maximize

capacitance surface area and resolution.• Use of both sides of the board so traces can be as wide as

possible.• Differential design so that outside influences will have

minimal effects on reading.

Sensor Principles• Measures Capacitance of the area surrounding the

sensor.• Fringe effect capacitance is the primary amount of

capacitance measured.• As an object with a higher dielectric constant

approaches the sensor, the total capacitance of the circuit increases.

• Minimal distances between traces lead to greater effects on capacitance due to the oil surrounding the sensor.

Sensor Application• The sensor is attached the end of an OEM equivalent

dipstick and is submersed in the oil of the automobile engine.

• There are five capacitive circuits on the board.• Each circuit will be polled numerous times by the

microcontroller to gain an average capacitance per circuit.

• Finding the greatest difference in capacitance between two adjacent circuits determines where the oil level is.

• The differential design allows for repeatable and accurate results despite changes in oil temperature, oil quality, and the external environment.

Software Design (1/2)Powerup:

void Init():Sets the power mode to the higher power, operational state.

Powerdown:void Shutdown():Sets the power mode to the lowest power state.

Calibration:void mainCal(): Main calibration routine

void setCalData(char data, char stage): Saves the calibration data into nonvolatile memory

void blockInterrupt(): Wait until the pushbutton interrupt arrives

Software Design (2/2)Measurement:

void mainMeasure(): Main measurement routinechar interpolate( char data ): The returned value is the relative oil

level based off interpolated calculations

UIControl:char buttonPressed(): Determines whether or not the button is

pressed.void LEDController( char active, char blink): Two LED mapped

characters are set to either activate or blink LEDs.

SensorInterface:char pollSensor(): Sets the lines to poll the sensor and return the

raw data

MicrocontrollerTI-MSP 430 chipsetSuggested by customerChosen Model MSP430FF1101ANeeded small amount of flash memory

1KB program memory128B flash memory128B ramTwo I/O, 8-bit and 6-bit buses

The CR2032 Battery•One 3 Volt battery gives significant voltage and power for use in our embedded system.

•A Lithium battery

•Chosen for it’s small and slim like size

Summary Of WorkNick Johnston – 76.5Dan Dillon – 76Drew Combs – 63Alex Garr – 68

Created engineering project plan and designStarted implementation of hardware and

software designs

Questions?

top related