Hello everyone,
I'm encountering an issue in Traccar where my vehicle's fuel consumption shows a negative value after I refuel it. I've found that this happens because Traccar's algorithm is summing all the changes in the fuel level, including the increases in fuel level when refueling.
I understand that this issue likely has to do with how Traccar handles the data from the fuel level sensor. I'd like to adjust the data handling such that increases in the sensor reading (i.e., when refueling) are not interpreted as fuel consumption.
Could anyone suggest a solution to this problem or guide me on how I can adapt the algorithm for a more accurate interpretation of the fuel level sensor data?
Thank you in advance for your help.
If you find a good way, feel free to send us a pull request.
Hello there,
I had the same issue, but I have a question does Traccar calculate spent fuel by subtracting the last position fuel level from the first position of the fuel level of a given trip or stop or anyother? if thats the case, how does it calculate if there is a refuel during that given trip or period or stop?
Yes and it doesn't account for refueling, but normally you would need to stop for refuel, so it hasn't been a big issue.
Hello everyone,
I'm encountering an issue in Traccar where my vehicle's fuel consumption shows a negative value after I refuel it. I've found that this happens because Traccar's algorithm is summing all the changes in the fuel level, including the increases in fuel level when refueling.
I understand that this issue likely has to do with how Traccar handles the data from the fuel level sensor. I'd like to adjust the data handling such that increases in the sensor reading (i.e., when refueling) are not interpreted as fuel consumption.
Could anyone suggest a solution to this problem or guide me on how I can adapt the algorithm for a more accurate interpretation of the fuel level sensor data?
Thank you in advance for your help.