You need to specify what protocol you are talking about. Each protocol is different.
I was speaking about h02, but it should be for all protocols which include battery stats. Instead of putting a number representing the charge of the battery, which may be different for each protocol, put a percentage. That way, all protocols will look the same in the web interface.
The problem is that some protocols report battery voltage instead of percentage.
OK, for those it's probably better to leave voltage. But for the others it could be interesting to put a percentage instead of having a number which doesn't indicate much.
Where did you get the mapping between numbers and percentage from?
Anton, I have found it in new documentation (in English). Also confirmed here http://stackoverflow.com/questions/30652661/gps-tracking-grtq and in examples from this thread https://www.traccar.org/forums/topic/traccar-3-7-odd-position-issue/ values are looks like fit to such decoding.
Can I see the documentation?
It's in https://dl.dropboxusercontent.com/s/th4i62kmuvxq6vy/H02%20protocol%20EN.doc
Multi-base battery Protocol: adding one byte behind status means battery. *HQ,7893267560,NBR,081606,460,0,1,4,9338,3692,150,9338,3691,145,9338,3690,140, 9338,3692,139,220513,FFFFFBFF,cell# cell range of value: 1-6 6=100% 5=80% 4=60% 3=20% 2=10%
It's quite interesting as 2 is already 10%, which probably means 1 is 0%, so it will never arrive there
Are you saying that "cell range" means battery level? I thought it's something to do with GSM cell signal.
Yes, it's battery "cells". Besides, it's written battery on top.
I have implemented decoding of battery percentage.
awesome, thanks
Hello,
Instead of putting the power in numbers like
06=100% 05=80% 04=60% 03=40% 02=20% 01=10%
Wouldn't it be better to show them directly as percentage in the web interface? That would be clearer for most people I think.
Regards