[REL] TinyPedal - open source overlay APP for rF2 (Radar,Pedal,FFB,Deltabest,Relative,Fuel calculator)

Discussion in 'Other' started by svictor, Mar 14, 2022.

Tags:
  1. Flin Faraday

    Flin Faraday Registered

    Joined:
    Aug 10, 2022
    Messages:
    10
    Likes Received:
    0
    Liking TP very much. The only issue I still have is it disappearing randomly for some period during session and when it comes back delta, fuel etc. data are all wrong. If I remember correctly it has not happened during a race, but happens frequently during FP and qualifying sessions.
     
  2. Guillem Rego

    Guillem Rego Registered

    Joined:
    Oct 7, 2020
    Messages:
    15
    Likes Received:
    7
    Is OpenXR support planned?
     
  3. makan

    makan Registered

    Joined:
    Mar 6, 2017
    Messages:
    70
    Likes Received:
    93
    Not yet.
    I'm an openxr user and i hope @svictor will find a way to develop TP for it too.
     
  4. Matlorc

    Matlorc Registered

    Joined:
    Mar 21, 2022
    Messages:
    18
    Likes Received:
    2
    In the last evening race I noticed that relative widget showed gaps from other drivers different from the game.
    RF2 show in his terrible huds the gap with the opponent just behind and the one just in front, and these values were different from the values in the TP relative widget
    ex. RF2 shows 15 sec., TP shows 13 sec.
    Does someone else noticed this discrepancy?
     
  5. svictor

    svictor Registered

    Joined:
    Jan 20, 2019
    Messages:
    935
    Likes Received:
    6,342
    This is normal, TP uses a totally different way for calculating gap, as Relative gap requires different gap calculation than the game.

    Relative gap not only shows gap for an opponent that is ahead or behind you, but also has to show gap for other nearby opponents, and those opponents could be laps ahead or behind, which the game's gap value won't work with Relative gap under those conditions, and requires different calculation.
     
    Last edited: Nov 14, 2022
    davehenrie and Matlorc like this.
  6. instinkt

    instinkt Registered

    Joined:
    Nov 21, 2020
    Messages:
    99
    Likes Received:
    66
    I have weird error
    downloaded it, unpacked, launched and it was fine
    then I wanted to move folder to different location and since then I'm getting error while launching and it only launch if I move folder back to the previous location
    I tried to redownload and unpack in that new location but it still not workin
    any other location different to that one where I launched it at first gives me same error

    this is what error log tells me
    Traceback (most recent call last):
    File "run.py", line 62, in <module>
    File "run.py", line 42, in load_tinypedal
    File "tinypedal\about.pyc", line 43, in __init__
    File "tkinter\__init__.pyc", line 2270, in __init__
    _tkinter.TclError:
    but I don't understand it
     
    Last edited: Nov 16, 2022
  7. svictor

    svictor Registered

    Joined:
    Jan 20, 2019
    Messages:
    935
    Likes Received:
    6,342
    Hi, thanks for feedback.

    I have identified the issue. Currently TinyPedal requires folder path name(include any folders above) to be completely in English, any other languages can cause the above error. I'll see to solve it.
     
    ebeninca, Corti and instinkt like this.
  8. svictor

    svictor Registered

    Joined:
    Jan 20, 2019
    Messages:
    935
    Likes Received:
    6,342
    v1.9.2 update - Preset reload, Estimated tyre lifespan, Improved player status check & auto-hide module
    https://github.com/s-victor/TinyPedal/releases/tag/v1.9.2
    192.jpg

    TinyPedal v1.9.2 now supports (re)load and create preset without exit (as frequently requested). A new "Load Preset" can be accessed from tray icon menu.

    New tyre lifespan display can be found in Wear Widget (as requested by Rui Santos ), which displays estimated tyre lifespan in laps based on previous lap tyre wear.

    New realtime tyre wear of current lap is also displayed on "Last lap tyre wear" section, which auto turns on 10 seconds after crossing start/finish line. This function helps track both last lap and current lap tyre wear.

    Added new customizable warning threshold for all 3 tyre wear sections, which changes color when reaches threshold. All those new options are turned on by default, and can be turned off in JSON.

    Added more player status check methods to help eliminate overlay flickering or data interruption whenever a player enters or exits server during none race session. And improved auto-hide function accuracy by using game's FFB output, which will not be interrupted or affected by other factors.

    See new customizable options for Wear Widget:
    https://github.com/s-victor/TinyPedal/wiki/Customization-Guide#wear

    TinyPedal 1.9.2 (2022-11-19)
    • Preset manager
      • [New]TinyPedal now supports reload & change preset while running.
      • [New]Added "Load Preset" to tray icon menu.
      • Preset manager window no longer opened at launch. TinyPedal will always load last used preset at launch.
      • Due to limitation, active preset name no longer shows on tray icon menu.
    • Wear Widget
      • [New]Added "show_lifespan" option to show estimated tyre lifespan in laps.
      • [New]Added "show_realtime_wear" option to show current lap tyre wear that constantly updated in realtime.
      • [New]Added additional "font_color" & "warning_threshold" and many more customization options.
      • Improved and more accurate tyre wear calculation.
        Properly calculates tyre wear for pit in & out lap.
      • Reduced custom layouts to 2 variations, but added new customizable column order.
    • Core
      • Auto-hide function is now based on game's FFB output value for high accuracy and stability.
      • Added multiple local driver status check method to eliminate data interrupting
        when other players have joined or disconnected from server.
      • Fixed incorrect laptime validation duration for deltabest module.
        Best laptime data is now saved right after validation.
      • Significantly improved code structure.
        All threads are now properly closed before exiting.
    • pyRfactor2SharedMemory library
      • Added additional code to properly close shared memory mapping before exiting.
      • Added number of vehicles difference check.
      • Increased max player index check to 128.
    • Misc
      • Updated customization guide with new configurable setting for Wear Widget.
     
    makan, instinkt, ebeninca and 5 others like this.
  9. ebeninca

    ebeninca Registered

    Joined:
    Sep 7, 2016
    Messages:
    740
    Likes Received:
    526
    The auto hide function isn't working correctly in this version, immediately after loading the track the widgets appears, and only goes away when you close the game, I have a G27 wheel.
     
  10. svictor

    svictor Registered

    Joined:
    Jan 20, 2019
    Messages:
    935
    Likes Received:
    6,342
    hi, can you double check if the preset has auto-hide enabled in tray icon, and post a screen of your controller setting from in game calibration page, thanks.

    Edit: I have identified the cause, if minimum steering torque is set above 0, auto hide would fail. I'll try update a fix asap(likely revert back to old method).
     
    Last edited: Nov 20, 2022
    ebeninca likes this.
  11. svictor

    svictor Registered

    Joined:
    Jan 20, 2019
    Messages:
    935
    Likes Received:
    6,342
    v1.9.3 - Fixed auto-hide function & Improved telemetry info reading
    Edit: there is a missing assignment to a variable in v1.9.3, which could cause error. Sorry for any inconvenience.

    See v1.9.4 for fixed download.


    This update adds new method to sync both Telemetry & Scoring info to local player, which should fully fix the long standing "gets wrong data" issue that associated with players joining or disconnecting from server. This also helps and improves accuracy of all other functions that depends on local player status.

    TinyPedal 1.9.3 (2022-11-20)
    • Core
      • Auto-hide function is reverted back to previous method,
        which depends on player's engine ignition status).
      • Removed all previous driver status check methods,
        as new changes to pyRfactor2SharedMemory library has fixed the issue
        that associated with players joining or disconnecting from server.
      • Now also shows data while "Toggle AI control" enabled.
    • pyRfactor2SharedMemory library
      • All Telemetry & Scoring info is now constantly updated in a separated thread.
      • Now uses deep copy on Telemetry & Scoring info
        and verifies mVersionUpdate values to avoid data changes or corruption.
      • Now finds player's index number against a single Scoring info piece.
        Previously this was not done on a single info piece,
        which data could be changed or corrupted while checking.
      • Now uses player's mID from the verified Scoring info
        and compares with the mID from Telemetry info to ensure
        all assigned Telemetry & Scoring info data is correctly synced to local player.
     
    Last edited: Nov 20, 2022
    makan, ebeninca, DanRZ and 3 others like this.
  12. svictor

    svictor Registered

    Joined:
    Jan 20, 2019
    Messages:
    935
    Likes Received:
    6,342
    makan, Reiche, ebeninca and 3 others like this.
  13. svictor

    svictor Registered

    Joined:
    Jan 20, 2019
    Messages:
    935
    Likes Received:
    6,342
    v1.9.5 - Fuel delta recording, calculation & estimated fuel consumption
    upload_2022-11-24_22-17-20.png
    https://github.com/s-victor/TinyPedal/releases/tag/v1.9.5

    This update adds major improvements to Fuel Widget for more accuracy and easy use.
    See changelog below for details.

    TinyPedal 1.9.5 (2022-11-24)
    • Fuel Widget
      • [New]Show "estimated fuel consumption" that is constantly updated and calculated
        against the new fuel delta consumption data from last recorded lap.
        The new estimated value replaces the old "last lap fuel usage" value and more accurately reflects
        how each fuel info changes with driver's input or engine mixture levels, etc.
      • [New]Fuel consumption & last laptime values are now stored inside new fuel delta consumption file,
        which corresponds to each matching vehicle-track combo and auto-loads while driving.
        User can quickly jump back in a previously driven combo with all fuel consumption data available right away.
    • Core
      • [New]Added fuel consumption recording & delta calculation functions to Fuel module.
      • [New]Fuel delta consumption file is now saved in "TinyPedal\deltabest" folder with *.fuel extension,
        Note: For accuracy purpose, only the fuel delta consumption data from most recent complete lap
        will be recorded and used for delta consumption calculation.
        This includes full laps that have exceeded track limits, but excludes pitin & pitout laps.
      • Fixed an error that occurred after toggle auto-hide and reload preset.
      • Improved auto-hide function.
      • Improved deltabest recording methods.
      • Removed "fuel_consumption" value from fuel section of setting file.
      • Removed "last_laptime" value from timing section of setting file.
    • Misc
      • Updated documents.
    • pyRfactor2SharedMemory library
      • Further improved synced methods for reading local player info.
      • Separated none-synced methods from player-synced methods to be compatible
        with apps or functions that uses none-synced methods.
        Note: TinyPedal now uses player-synced methods for reading shared memory.
     
  14. Lazaros Filippakos

    Lazaros Filippakos Registered

    Joined:
    Apr 15, 2016
    Messages:
    11
    Likes Received:
    6
    Would it be possible to show the limiter and flags widget separately without the gears? And also a way to keep current settings of old confings when we are installing the newest versions.
     
    svictor likes this.
  15. DanRZ

    DanRZ Registered

    Joined:
    Aug 22, 2021
    Messages:
    720
    Likes Received:
    220
    Hello, i currently have an annoying issue.
    Sometimes TinyPedal freezes. I noticed it on races with 32 players.

    Once it freezes it never gets back. I need to pit, restart TinyPedal and it gets back.
    Are there any chance to have a "reset" button that restarts TinyPedal "on the fly" ?
    I already had some latency on datas, like a few seconds delay on previous versions ...
    My CPU is often using 100% CPU by peaks and i suspect TinyPedal to freeze when that happens too longly.

    Also, i have a question : Will it use less CPU if i use only a few widgets ?
    Like Gear + Radar only will use less than Gear, Radar, Fuel, Wheel ... all together ?
    Or is it useles to limit number of widgets ? I mean for the CPU. My GPU seems fine ...
    Just wondering.

    Thanks ;)
     
    svictor likes this.
  16. svictor

    svictor Registered

    Joined:
    Jan 20, 2019
    Messages:
    935
    Likes Received:
    6,342
    thanks, I have thought about creating a separate widget for flags only, I will add this to to do list.

    As for old config files, they will work with new version. However starting from v1.9.0, all old json config files have to be manually moved into settings folder of TinyPedal to be able to load.

    thanks, there is a long standing issue related to memory reading code(python ctypes+mmap) that can be interrupted by currently unknown cause, which results overlay freeze or disappear. I have been trying to solve this problem for the past few weeks, but it is quite difficult to solve, due to the very rare occurrence and without any error reporting from the program. So far this issue only happened during none race session when someone joining server(by ESC to pit and click DRIVE it will work again in v1.9.5) for most people reported. I have been currently testing a few new changes, but due to this random nature of the issue and the requirements of testing it in multiplayer session, it's not easy to get to the bottom of the issue. So this probably require a bit more time.

    As for CPU usage, less widgets will definitely reduce CPU usage. Currently activating all 20 widgets will cost about 8-10% CPU usage, and GUI itself doesn't support hardware acceleration.
     
    Last edited: Nov 27, 2022
    DanRZ and ebeninca like this.
  17. ebeninca

    ebeninca Registered

    Joined:
    Sep 7, 2016
    Messages:
    740
    Likes Received:
    526
    It improved a lot already, now for me sometimes when someone enter the server only the delta bar resets, the rest of the widgets keeps working correctly.

    I think the LFM's practice servers is a good place to test this, because it has a high movement of drivers joining and leaving the server in a short period of time.
     
    Last edited: Nov 28, 2022
    svictor likes this.
  18. DanRZ

    DanRZ Registered

    Joined:
    Aug 22, 2021
    Messages:
    720
    Likes Received:
    220
    If it can help you, i noticed it happens every time on a full server with 32 IAs for me.
    I modified some parameters now but at that time my CPU was at 100% most of the time.
    At the first turn after a start, i always bumped the other laggy cars and get TinyPedal frozen each time.
    I was almost able to froze it "on demand" ...

    I think you need three things :
    • A real "dedicated" distant server
    • Be in a Race "Online" session
    • Lots of drivers or IAs in proximity (Rolling start)
    If you try it on a single player you will probably use less CPU and never get it.
    As said in another post in this forum there is a weird issue with Qualy and Race "Online"
    which seems to be really badly optimized from other types of session. That is easy to notice ...

    When there are too much cars near you, that's probably when that happens. CPU goes ballistic and TinyPedal gets lost.

    That's how i analyzed it and partially solved it.

    I made some improvements on my settings, my CPU stays below 95% and now i never get that phenomenon of Freeze from TinyPedal.

    There is probably no "easy" solution but more an advice : Be sure your CPU is never bottlenecked when using TinyPedal.

    ;)
     
    Last edited: Nov 28, 2022
    svictor likes this.
  19. DanRZ

    DanRZ Registered

    Joined:
    Aug 22, 2021
    Messages:
    720
    Likes Received:
    220
    And also i have a small request.
    I'm trying to learn to trail brake, and it will be cool to have three colors for the brake.
    • Green value under 5% (To maintain grip ...)
    • Red value between 5% an 80% (Brake effective zone ...)
    • Light blue (like the rpm limit) between 80% and 100% (Excessive brake ...)

    json would become something like :
    "pedal": {
    ...
    "throttle_trail_color": "#77FF00",
    "throttle_trail_value": 5.0,

    "throttle_color": "#77FF00",
    "throttle_excess_color": "#00FFFF",
    "throttle_excess_value": 80.0,

    ...
    }

    It would be awesome ;)
     
    Last edited: Nov 28, 2022
    jean pierre and svictor like this.
  20. svictor

    svictor Registered

    Joined:
    Jan 20, 2019
    Messages:
    935
    Likes Received:
    6,342
    thanks @DanRZ , those testing feedback are really helpful, I agree the interruption is highly like to be caused by CPU stuff. There is currently a few code that I'm testing which seems to solve that issue, just need to do more testing.

    And the brake suggestion is very nice, I will add it in next update.
     
    Rui Santos, ebeninca and DanRZ like this.

Share This Page