yes it possible but it would only be a rough giude
if you search on google you should find what your after, I would do it with a PIC16F876 with 10 LEDS but it can easily be done wiht lm3914
there is no 100% way of telling how much charge there is left in a battery.
letas say if your battery was 4AH and your load was 200ma then it would take 20hrs to discharge it but if you was to say that you discharged it at
battery cap discharge current time
4 / 200ma 20hrs True ? yes
but's let say if the continuous dischaege was 500ma you wouyld then say that it should last 8 Hours TRUE or FALSE
answer is FALSE because you have got something called the Peukert's effect and my calculations would say that the battery would only last 6hhrs 2hrs shorter
T=C(C/R)N-1/IN works like this c =capacity R is rating 20/5hrs n is the exponent and I is dishcharge current like this below
4*(4/20)^(1.3-1)/0.2^1.3 = 20hrs
but say if the discharge rate was higher then it would look like this
4*(4/20)^(1.3-1)/0.5^1.3 = 6.07hrs and not the expected 8hrs if you worked it 4 devided by .5 = 8hrs
Hope I've not bored you to much but hopefully it wil give you a rough guide when chosing a battery
)
wizpic