Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Calculation of Fluid Level using PIC ADC

Status
Not open for further replies.

skeeterb

Member
I am upgrading my control circuit's Indicator to have an LCD instead of 4 LEDs and to give different information like system run-time, water tank level, and current cell power usage stats. I'm using Flowcode V4 to create the program and need help creating the formulae to calculate the current fluid level in the water tank using a standard gas tank sending unit. The sending unit will probably have to be calibrated, but I think I can do that. I have a formula I used when I was using the ADC to get timing data, but I don't think it would work because it was being used to read a non-changing value where as the run time is always changing. How can I change that formula to get valid run-time data? I also need help figuring the cell power usage stats so they can be displayed on the LCD.


Edit:

the Formula I have and use in my main control program and also in my traffic light program for Timing is
(Result + 1) / 17 or ((Result + 1)/17)/2 for half the duration.
 
Last edited:
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top