Page 2 of 2

Re: GEAR number drops to 0

Posted: Tue Jun 27, 2023 11:04 pm
by KAZUNA
2022 Acura NSX Type S

Re: GEAR number drops to 0

Posted: Wed Jun 28, 2023 4:11 pm
by Harry
O.k., your configuration is fine.

After revisiting the code, the problem is indeed related to DCTs:

For standard clutches, there is a considerable gap without a direct connection between drivetrain and motor. During this time, rpm can have any value that must not be mapped to a certain gear. That's the reason LapTimer checks for gear-matches rather than choosing the "best fit". In case there is no gear-match, the gear cannot be calculated and the zero means "undefined".

For DCT cars, technically you will not see an undefined situation. Instead, while shifting, there will be a rpm / speed relation between the old and the new gear. See the sample from your data below... This is a downshift situation from 3 to 2. Speed is decreasing monotonously, rpm is increasing monotonously. For the three samples in the middle, there will be a "best match" of either 3 or 2, but no precise match. Strictly speaking, you are neither in gear 3 nor 2, but have a combination of both.
Screenshot 2023-06-28 at 16.24.34.png
Screenshot 2023-06-28 at 16.24.34.png (116.21 KiB) Viewed 13379 times
Initially I considered switching to a best fit approach (which is just changing a few lines of code. This however, would introduce a problem for standard clutch cars: if e.g. the rpm is falling to idle during the above shift, you would see something like 3 ‣ 4 ‣ 5 ‣ 4 ‣ 2. That's because rpm is falling rapidly while speed is falling slow. Once the clutch is closed again, rpm will go up and the gear will go to 2 again.

So different algorithms need to be chosen depending on the clutch type. The later would require a new parameter for vehicle parameters.

The approach to keep the last valid gear when "undefined" is returned is an option, but something that should be done during display. Calculating the gear is a stateless function used in numerous contexts. I keep this on my list for now.

Re: GEAR number drops to 0

Posted: Wed Jun 28, 2023 6:02 pm
by KAZUNA
Thank you for looking into this and sharing your detailed analysis.
Yes, it does make sense why the problem is happening while shifting and it is related to DCT.

For the time being, I'm fixing the GEAR numbers in the csv file by replacing the 0 with the last valid gear and it looks good so far.

Re: GEAR number drops to 0

Posted: Fri Oct 20, 2023 6:34 pm
by KAZUNA
I had a tracking weekend and I ran into this problem again without noticing it until I created a video on RaceRender.
Any update on this for having the new vehicle parameter (clutch type = DCT) that is going to keep the last known gear (best fit) rather than dropping into the zero (undefined)?

Re: GEAR number drops to 0

Posted: Sat Oct 21, 2023 8:40 am
by Harry
Please wait for the next bugfix release, gears shown are one too low currently.

Re: GEAR number drops to 0

Posted: Sat Oct 21, 2023 8:58 am
by KAZUNA
Is next next bugfix released until the next tracking season next year, hopefully?

>gears shown are one too low currently.

Are you talking about the other issue I reported that the gears are shown one higher currently?
viewtopic.php?t=6573

Re: GEAR number drops to 0

Posted: Sat Feb 17, 2024 10:24 am
by KAZUNA
Are there any updates on this issue (DCT gear drops to zero(undefined))?
Are you considering a new vehicle parameter (clutch type = DCT)?

Re: GEAR number drops to 0

Posted: Sat Feb 17, 2024 10:25 am
by Harry
The gear bug fix will be part of LapTimer's Spring release.

Re: GEAR number drops to 0

Posted: Sat Feb 17, 2024 10:33 am
by KAZUNA
That's great news!

Is the Spring release going to fix not only the "GEAR number is one higher" issue but also this "GEAR number drops to 0" issue?

Re: GEAR number drops to 0

Posted: Tue May 07, 2024 5:10 am
by KAZUNA
My HLP just got updated to 24.9.0 saying "fixed a bug in gear calculation".
Is it going to fix this "GEAR number drops to 0" issue?