oil density

Hey guys,
am doing a school project and am looking for a sensor that can be used to determine the density of oil in a car engine.
Typically am looking for something that can withstand high temperatures of an engine as well as provide real-time data.

Any suggestions please, n considering am still a student, it shouldn't b something expensive!
And it will be quite helpful if its compatible with any arduino mcu

Density or viscosity? I know of no sensor that will give real time data in a running engine for either.

think for most oils the viscosity is a function of the temperature so measuring the temperature could be an indirect method.
look at the graphs here - http://www.cwbearing.de/e/mod_ratinglife.html -
(just as an example, you must find the right graph for your oil)

Another way to measure viscosity is to take a tube and give it an known angle and measure the speed of the oil (time it takes to move a certain amount)

other reads

interesting question btw

well viscosity since its the main parameter needed for lubrication really.
actually my project aims at coming up with an alert system that warns you when your engine oil is used up or degraded(for lack of better words :roll_eyes:) and takes a precautionary action to prevent stalling of your engine.
I know the mileage is the one usually used for the next oil change but its usually a bargain and does not factor in variable aspects.

for the temperature, it will always affect viscosity but there is always a threshold which when exceeded, indicates the oil needs to be changed.

How about a small motor with an impeller attached, small enough that it could fit in the oil drain and replace the oil plug. Drive the motor with a precise voltage and watch its current consumption as it stirs the oil: more current used by the motor would suggest a higher viscosity. This would need to factor in the temperature of course.