Funbit / ets2-telemetry-server

ETS2/ATS Telemetry Web Server + Mobile Dashboard
GNU General Public License v3.0
613 stars 205 forks source link

average fuel consumption #71

Open tarikayaz opened 8 years ago

tarikayaz commented 8 years ago

I am preparing a new skin. I want to show average fuel consumption. But something is wrong. It shows 49.23 Litre everytime. I noticed that the test file in webserver shows the same amount. Then I noticed in the renault skin in web server shows 49.23.!

I think there is a problem wtih the telemtry.dll file. If you fix it I'll be happy.

yodek commented 8 years ago

Are you sure you don't have enabled "UseEts2TestTelemetryData" ? In tutorial.pdf Funbit mention about it - you can use this to test new skin without playing game.

[quote] [...] To enable test mode open Ets2Telemetry.exe.config file and set UseEts2TestTelemetryData option to true and restart the server: [add key="UseEts2TestTelemetryData" value="true" /]

tarikayaz commented 8 years ago

When I see your comment, I re-checeked it I see it has false value.

yodek commented 8 years ago

Then it is weird - sorry, but I can't help you, I'm newbie [try to understand all programming stuff, but still can't :( This is the reason why I didn't update my skin and make my own version of .dll file for my purpose [to use in my arduino project].

My suggestion for you was based of value / information you gave - you mean "test file" is it the same values as in the file "Ets2TestTelemetry.json" in main folder of ETS2-Telemetry ?

mike-koch commented 8 years ago

There is a TODO statement right above the average fuel consumption channel, as shown in https://github.com/Funbit/ets2-sdk-plugin/blob/master/ets2-telemetry/src/ets2-telemetry.cpp#L352-L353.

A possible alternative is to perform the calculations on your own, by taking snapshots of your fuel usage over a period of time, and then taking that average.

Funbit commented 8 years ago

Yea, this is a known problem, will try to do something with it.

webxpl commented 8 years ago

On my skin peterblit avg works fine, shows value from game dashboard https://github.com/Funbit/ets2-telemetry-server/pull/75