Back to Parent

Outcome


Show Advanced Options

The code uses the if, else if statements to define the conditional logic for sensing level.

Cokelevel full.thumb
Show Advanced Options

This picture shows how the LEDs correspond to a full bottle of diet coke.

Cokelevel half.thumb
Show Advanced Options

This picture shows the corresponding LED output with a less than full level but not empty bottle of Diet Coke. The resolution of such a level detection system can be increased by adding more LDRs. 

Cokelevel empty
Show Advanced Options

An empty bottle corresponds to both LEDs turned off. 

Img 20150128 wa0004
Show Advanced Options

The ambient light from the sides may affect the output of the system, therefore the LDRs are placed inside cups to eliminate light from the sides.

Drop files here or click to select

You can upload files of up to 20MB using this form.