PC Ts World Raildriver And Joystick Interface

Discussion in 'TSW General Discussion' started by CobraOne, Nov 8, 2022.

  1. CobraOne

    CobraOne Active Member

    Joined:
    Jun 3, 2022
    Messages:
    254
    Likes Received:
    189
    Compatability with TSW5
    If you are purchasing/upgrading to TSW5, in order for my program to copy over the PieHid64.dll automatically, you need to run TSW5 once without my program running and then exit TSW5. This then creates the necessary folders in Documents\MyGames\TrainSimWorld5 which my program looks for to find the versions of TSW installed on your machine. When it finds the folder, it checks the relevant PieHid64.dll and updates it if necessary.
    I don't have TSW5 yet, so haven't tested this but this should work.
    Chris

    Edit: See post #509 below for a working fix
     
    Last edited: Sep 19, 2024
    • Like Like x 2
  2. OttoPilot

    OttoPilot New Member

    Joined:
    Sep 16, 2024
    Messages:
    2
    Likes Received:
    0
    Pardon my confusion but where do I copy the PieHid64.dll to? I have a binary folder in My Documents and in the TSW folder in my steam common folder. I am unable to connect so I am not doing something right.
     
  3. CobraOne

    CobraOne Active Member

    Joined:
    Jun 3, 2022
    Messages:
    254
    Likes Received:
    189
    In your Steam folder you should have
    steamapps\common\Train Sim World 5\WindowsNoEditor\TS2Prototype\Binaries\ThirdParty\PieHid\Binaries
    Copy it there but before you do, either rename or backup the original first.
    I take it the suggestion in my last post did not work?
    Are you using a Raildriver or Joystick?
    Chris
     
  4. OttoPilot

    OttoPilot New Member

    Joined:
    Sep 16, 2024
    Messages:
    2
    Likes Received:
    0
    All cleared up! Was not going into the TS2Prototype folder originally. Now everything is working - thank you! (For Joystick)
     
  5. ixofxiii

    ixofxiii Well-Known Member

    Joined:
    Apr 21, 2020
    Messages:
    334
    Likes Received:
    273
    ok, i dont know whats wrong. I just spent the last 30 mins looking thru this thread trying to find out what dll file to copy over. I understand where to, but i dont know where from. Where do i find the file to copy over to the tsw5 binary folder? what do i rename it too? When i first opened up tsw5, closed it, then went into TSW raildriver and joystick then ran tsw5, the buttons work, but not the joystick itself. i get the "unable to connect" message. Sorry if i seem a little incoherent, My brain is pretty fried figuring this out and going thru multiple pages here

    UPDATE: I had uninstalled tsw4 prior to installing tsw 5. Once i unstalled, and ran tsw4 to make sure everything still worked, i ran tsw5, shut that down then copied the Piedid64 file from tsw4 to tsw5 then started tsw raildriver and joystick, ran tsw5 and all is now well in the Collective. Resistance is futile.
     
    Last edited: Sep 18, 2024
  6. chippiearnold

    chippiearnold Member

    Joined:
    Oct 24, 2017
    Messages:
    32
    Likes Received:
    59
    I'm assuming from your update you got it working? The instructions for copying the DLL are in the Quick Start manual of the Joystick Interface software (inside the Manuals folder):

    Do the following:-
    1. Locate the PieHid64.dll located in the following Steam folder(s) replace the * with the version number of the game i.e 2, 3, 4 etc.
    “SteamApps\Common\Train Sim World *\WindowsNoEditor\TS*Prototype\Binaries\ThirdParty\PieHid\Binaries”

    2.Open the ‘TSW Raildriver And Joystick Interface’ folder.
    Next copy the new PieHid64.dll from the DefaultSettings folder (not the PIEHid64Net.dll located in the main folder) and copy it to the same location in TSW in step 1

    Some people suggest re-naming the original dll in the TSW folder rather than overwriting it with Chris's version, just so you can roll back in case there's any issues.
     
    • Helpful Helpful x 1
  7. KCRCRailway

    KCRCRailway Active Member

    Joined:
    Mar 3, 2021
    Messages:
    143
    Likes Received:
    96
    Hi Cobra,
    Yet to have time to try use the program, will it work with controls that lacks hotkey in game by default? What if I already removed most existing hotkey? Will both cause issue?
    Example 1: Some train has buzzer or depot whistle which cannot trigger by hotkey.
    Example 2: I removed most unneccesary hotkey such as wiper control in game.
     
  8. CobraOne

    CobraOne Active Member

    Joined:
    Jun 3, 2022
    Messages:
    254
    Likes Received:
    189
    If by HotKey you mean KeyBoard key then Unfortunately, if there is no hotkey/keyboard key for a control in the game, then my program will not be able to operate that control.
    If by HotKey you mean the button assignments in the ButtonMap, If the buzzer or depot whistle has a keyboard key assigned to it in game, then you can add it to the ButtonMap, see the Edit Button Maps on Page 7 of the "TSW Raildriver and Joystick Interface Manual.pdf" in the Manuals folder.
    Chris
     
    • Like Like x 1
  9. CobraOne

    CobraOne Active Member

    Joined:
    Jun 3, 2022
    Messages:
    254
    Likes Received:
    189
    Compatability with TSW5
    As a quick workaround to allow the PieHid64.dll to be updated automatically, can you edit the "Game Versions.txt" file located in the "DefaultSettings" folder and add the following line to the end of the file:
    Train Sim World 5
    Then run my program again and the dll should be copied over. I will update the program to not require this file at a later date (Time is limited at the moment).
    Chris

    I have just updated V2.0.0.8 to include the change, you can download it from here:
    https://www.dropbox.com/scl/fi/8qh3...ey=y28j41v1002trj53n43a4n9f1&st=k7kfg7t3&dl=1
     
    Last edited: Sep 19, 2024
    • Like Like x 1
  10. KCRCRailway

    KCRCRailway Active Member

    Joined:
    Mar 3, 2021
    Messages:
    143
    Likes Received:
    96
    I see, guess still need keyboard time to time.
    On 2nd point, for example wiper, do I have to set an in-game hotkey first (example: Y) before I can set the RD to work the wiper by turning knob, or I can choose to leave in-game hotkey blank?
     
  11. CobraOne

    CobraOne Active Member

    Joined:
    Jun 3, 2022
    Messages:
    254
    Likes Received:
    189
    If you set the Master Lever Map to look like this:

    upload_2024-9-19_14-58-39.png

    then the wiper switch on the Raildriver will control the wipers on most trains and it does not use the Button Map.
    On the Raildriver, the wipers and lights are actually potentiometers the same as the other levers, and not buttons so are controlled by the PieHid64.dll. I hope that makes sense :)
    Chris
     
    • Like Like x 2
  12. warham2er

    warham2er New Member

    Joined:
    Sep 21, 2024
    Messages:
    1
    Likes Received:
    0
    Great tool, appreciate your efforts
    The only issue is that I cant assign AFB to the lever on Honeycomb Bravo- when set to the lever, it does not work. It only works when set up as a controller stick- that means if I make a small increase of a lever, it will increase till maximum unless I make a small movement backwards.
    As a workaround I assigned AFB to flaps toggle
     
  13. amtraknick1993

    amtraknick1993 Well-Known Member

    Joined:
    Dec 22, 2019
    Messages:
    568
    Likes Received:
    921
    I just tried using this with TSW5 and all the control levers (for example, the Metrolink MP36) are noisy and twitch back and forth. Surprisingly, the default TSW5 RD setup doesn't have this issue but using your mod, it causes the control levers to twitch.
     
  14. lawn.chairs

    lawn.chairs Member

    Joined:
    Aug 8, 2021
    Messages:
    39
    Likes Received:
    40
    CobraOne no idea if literally anyone else uses this but I was messing around with some Arduino parts and I got the app to write to a 14-seg alphanumeric display. Figuring out the parsing was a bit of debugging but nothing too tough. Looks great and now I have big plans if an API ever comes to life...

    IMG_4182.jpeg IMG_4184.jpeg IMG_4186.jpeg IMG_4188.jpeg
     
  15. PrimeMoverSimulator

    PrimeMoverSimulator New Member

    Joined:
    Sep 21, 2024
    Messages:
    6
    Likes Received:
    1
    CobraOne Just started using this program on my RailDriver, and I have to say everything works great, better than the default software that dovetail uses in game. HOWEVER, the bail off position on the independent brake seems to not work with this program. I've tried configuring it on both the configuration software in the program, as well as on the Master Joystick Assignment tab, and it doesn't seem to work for any of the locomotives that I play ingame. I also noticed, there's no BailOff data being sent to the game as well. Any help would be appreciated, as I'm still fairly new to using this program.
     

    Attached Files:

    Last edited: Sep 23, 2024
  16. PrimeMoverSimulator

    PrimeMoverSimulator New Member

    Joined:
    Sep 21, 2024
    Messages:
    6
    Likes Received:
    1
    Oddly enough, I was experiencing that same exact problem when I installed TSW5, even without the TSW Raildriver and Interface program. I think that is something on Dovetail's end to fix since other people have been having that same erratic movement with the levers and buttons as well using the raildriver. https://forums.dovetailgames.com/th...ers-ingame-move-uncontrollably-in-tsw5.84656/

    Funny, it was me downloading THIS program that I hoped that the levers moving erratically would be resolved, which it sadly didn't.
     
  17. razmatus#2517

    razmatus#2517 Well-Known Member

    Joined:
    Feb 17, 2022
    Messages:
    3,112
    Likes Received:
    2,074
    thats seriously impressive... I wish there was a way to make some data on displays more readable - the new GNT display is a great progression, but the thing you show on pics is really neat :)

    I am surprised some tech savvy guy/dudette hasnt yet done sth like maybe buy a used real train control desk and start adding custom-done levers and buttons and somehow also making it work software-wise :)
     
  18. amtraknick1993

    amtraknick1993 Well-Known Member

    Joined:
    Dec 22, 2019
    Messages:
    568
    Likes Received:
    921
    After further troubleshooting, I found that setting the sensitivity to 3 gets rid of all the twitching of the control handles. The only issue now is that the independent brakes bail off position doesn't work properly. You have to move the handle forward a little bit. Normally, the bail off should work from the fully released position. This was not an issue on previous versions when I used it on TSW4.
     
    • Like Like x 1
  19. LeadCatcher

    LeadCatcher Well-Known Member

    Joined:
    Dec 9, 2016
    Messages:
    1,547
    Likes Received:
    4,157
    That is exactly the opposite of my experience. Raildriver implementation in TSW4 was decent, no twitching of the levers… only problem I had was the button mappings were all over the place. In TSW5 levers were all very twitchy. Even after several re-calibrations, the twitchiness remained. That is the only reason I loaded CobraOne’s program ( have used it exclusively in TSC for years for my Raildriver).
    While not perfect, for me, CorbraOne’s software provides a much smoother experience.
     
  20. amtraknick1993

    amtraknick1993 Well-Known Member

    Joined:
    Dec 22, 2019
    Messages:
    568
    Likes Received:
    921
    What’s interesting is seeing the varying reports of peoples experiences with RD in TSW5. After I made this post, RD completely stopped working in TSW5. Showed detected and calibrated but just wouldn’t work at all. Cobra’s program is working much better now that I’ve been able to fine tweak it. Setting the sensitivity level to 3 works perfect for removing any noise or twitching. I’ve also custom mapped several buttons. So as of now, there’s simply no other way to run TSW5 without using this program, in my opinion. It’s a night and day difference. Works great with TSW5. As you said, a smooth experience.
     
    • Like Like x 2
  21. knuckleshed

    knuckleshed Well-Known Member

    Joined:
    Jul 14, 2024
    Messages:
    441
    Likes Received:
    448
    I think my RD is faulty or worn out, I seem to be getting sponginess at the top and bottom ends of the PB and other brake levers, it's like they spring creep back a bit all the time.

    Funny I never noticed this in TSC but with TSW's twitchiness it's made my RD unusable does anyone else have similar RD issues or is it just my unit?
     
  22. amtraknick1993

    amtraknick1993 Well-Known Member

    Joined:
    Dec 22, 2019
    Messages:
    568
    Likes Received:
    921
    I had this exact same issue with sponginess in some of my control levers. The only way I fixed it? Purchased a new RD. Works flawless in TSW5 with Cobra’s mod now.
     
    • Like Like x 1
  23. LeadCatcher

    LeadCatcher Well-Known Member

    Joined:
    Dec 9, 2016
    Messages:
    1,547
    Likes Received:
    4,157
    Glad hear it is working well for you -- Don't know why I waited so long to move to the software after using for several years in TSC... I guess prior to TSW5 the raildriver driver by DTG was "good enough". I doubt I will ever go back to the ingame driver now.
     
    • Like Like x 1
  24. lawn.chairs

    lawn.chairs Member

    Joined:
    Aug 8, 2021
    Messages:
    39
    Likes Received:
    40
    Like I said, big plans. I've already got many of the parts on hand and DTG Matt did say something about an API in the works....
     
    • Like Like x 1
  25. razmatus#2517

    razmatus#2517 Well-Known Member

    Joined:
    Feb 17, 2022
    Messages:
    3,112
    Likes Received:
    2,074
    so they MIGHT be working on an actual kind of RailDriver kind of thing or joystick support?

    anyway, good luck with your efforts, looking forward to progress reports :)
     
  26. LimitedEdiition

    LimitedEdiition Well-Known Member

    Joined:
    Dec 16, 2017
    Messages:
    341
    Likes Received:
    827
    They must have altered the sensitivity settings from TSW4 to 5, because trains that I have operated with it that had no issues in TSW4 (played as recent as a week ago before launch day), have this phenomenon you are describing. I hope they can give us a patch that increases the deadzone similar to what it was back in TSW4, otherwise this is borderline unplayable with it.
     
  27. knuckleshed

    knuckleshed Well-Known Member

    Joined:
    Jul 14, 2024
    Messages:
    441
    Likes Received:
    448
    An API (application programming interface) is a piece of coding usually in the form of a .dll (dynamic link library) that allows communication between the base games data (speed, location, control states and so on) and controllers, software or display screens.

    TSC has always had this (well for as long as I've played it for at least) hence why you have many 3rd party controllers and 3rd party software like RWE2 and ThirdRails that work really well because they all communicate with the game via the API.

    It's something many have wished for and requested in TSW since CSX Heavy Haul so hopefully it finally comes to fruition.

    Also highly unlikely DTG are or ever will be working on an actual controller as it's outside their remit, they deal in coding, graphics, animation and sounds not physical plug-in peripherals.
     
    • Like Like x 1
  28. knuckleshed

    knuckleshed Well-Known Member

    Joined:
    Jul 14, 2024
    Messages:
    441
    Likes Received:
    448
    Yeah it's my actual physical levers that are the problem, it's just the problem is exasperated by the poor execution in-game.

    Gonna have to strip it down and see if there's anything I can do to fix it.
     
  29. LimitedEdiition

    LimitedEdiition Well-Known Member

    Joined:
    Dec 16, 2017
    Messages:
    341
    Likes Received:
    827
    I gave this a try today, and am very impressed with what I am seeing. Increasing the deadzone sensitivity value helps a lot in mitigating the "twitchyness" introduced in TSW5, but I have a major issue with the throttle application and the "neutral" zone. I'm not sure how TSW calculates the throttle axis, but they are able to extrapolate the axis values and can calculate the dead space as the neutral/no throttle application, but I can't seem to get this right with the Interface.


    This causes operations with one handed EMUs such as the LIRR M7 from the Extended route (one of the best examples of the problems introduced in TSW5's Rail Driver implementation) problematic since what should be neutral is depicted as Min Brake application. If you can figure out a way to allow us to customize a custom throttle axis for a neutral/no throttle application, this would be great!
     
  30. CobraOne

    CobraOne Active Member

    Joined:
    Jun 3, 2022
    Messages:
    254
    Likes Received:
    189
    I have just run th LIRR N7 using both a Raildriver and a Joystick and only noticed a slight twitch on a couple of occasions while testing for about 20 minutes, this was with the snsitivity set to 0.
    The main problem seems to be that the neutral position on the N7 is at 33% and not 50% as on most loco's and there are 11 notches from emergency brake to neutral. meaning a move of only 3% between notches. If the lever is not exactly on a notch, then TSW5 can't decide which notch to apply, so you get the twitching.
    I did take my Raildriver apart a couple of years ago and tightened up the screws on the circuit board which did help.
    The problem with the Raildriver is, it has long plastic rods going from the levers to the potentiometers which causes slack in the movement. Also, the potentiometers do not utilise their full travel.

    Unfortunately, due to unforeseen circumstances, for the foreseeable future, I won't have any free time to look into adding the option to select a neutral position like you can in my TSC version, this would require a large rewrite of some of the code.
    Chris
     
  31. noroshi

    noroshi New Member

    Joined:
    Sep 26, 2024
    Messages:
    1
    Likes Received:
    0
    thank you so much man ive always tried to find a way to use tsw with my thrustmaster joystick
     
  32. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,514
    Likes Received:
    796
    CobraOne First I want to thank you for creating the program for all of us to use and make our gaming experience better. Now that I have TSW5 and I am also afflicted with the nervous twitchy train effect I figured it's time to take advantage of the program you created. I have the latest version, v2.0.0.8, I don't know if I need to run the program from the game folder, the C Drive, or if I'm just having a problem period because the program goes into non-responding after I'm able to do the calibration of the rail driver.

    Even to get there the pop-up boxes I need to close or acknowledge, the only option I have to close them is to right-click the close window or right-click 'X' out. That's the only way I can close the windows. Then I get the window for calibration, I click save, the pop-up comes up to save, I click yes and that is where I end up with a non-responding window, see attached image. I did disable, close, and shut down the Macroworks program which I am using for another train sim game, but I do close it before I start your program. I also have version 2.0.0.2.

    Any tips or hints as to what I should do, I would greatly appreciate it. I know you're busy, I just thought I'd let you know what I'm experiencing.
    CobraOne Program_09-26-2024_01.jpg
     
    Last edited: Sep 27, 2024
  33. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,514
    Likes Received:
    796
    A small update, I did get the Raildriver calibrated, I was using the mouse to select everything when I used the enter key, the program did not hang or stop responding as shown in the image, once I selected the callback and ran TSW5, it did work on GE RhB 4/4 ii but the brake goes from release to emergency with nothing in between and the throttle/brake wheel was either full throttle or full braking. I'm sure that I'm missing something in the setup, but at least the train is not a nervous wreck Twitching like crazy. I used this train to test because it can be the most tricky to control the throttle brake with the wheel.
     
  34. Sharon E

    Sharon E Well-Known Member

    Joined:
    Dec 9, 2016
    Messages:
    1,987
    Likes Received:
    1,961
    I have run into an issue, probably of my own making. I saw a post in the thread on Rail Driver in TSW5 Raildriver User Feedback Wanted Please, not this one that talked about using game calibration once this interface was installed to fine tune the settings. Well, doing this has gotten me into a right pickle, I can't get into reverse. I have recalibrated 3 time in the interface, reinstalled the dll file from the default folder all to no avail. Everything else still seems to work fine, just no reverse. Any thought or ideas on how to correct this.
     
    Last edited: Sep 28, 2024
  35. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,514
    Likes Received:
    796
    I got it all working last night, Followed the quick start guide, ran the program got it calibrated, at first things were working as I stated in post #533. I reinstalled the default Piehid file because of the patch DTG pushed out, but it was just as erratic, I reinstalled CobraOne's PieHid file that was already calibrated and I ran the in-game calibration, and tested it with several trains and everything was working as expected. I will see what is happening later and if all is still working as "normal" if we can call it that.
     
  36. Sharon E

    Sharon E Well-Known Member

    Joined:
    Dec 9, 2016
    Messages:
    1,987
    Likes Received:
    1,961
    This is really strange, since it was running in game calibration that seemed to have caused the issue noted in the above post.
     
  37. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,514
    Likes Received:
    796
    I just jumped into the BR 114 Training module in the Training Center and was working well, except the force selector bouncing from 100 to 102 to 99, other wise all is okay so far now with CobraOne's program and Piehid file.
     
  38. Sharon E

    Sharon E Well-Known Member

    Joined:
    Dec 9, 2016
    Messages:
    1,987
    Likes Received:
    1,961
    I still have, even after doing an in game calibration, no reverse on any locomotive I try. Everything else is working fine. How do I get my reverse back???? Only thing I have not tried at this point in uninstalling and then reinstall CobraOne's interface program.
     
    Last edited: Sep 28, 2024
  39. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,514
    Likes Received:
    796
    That is odd, that all is working except reverse, did you try loading the default button-mapper with Cobraone's
     
  40. Sharon E

    Sharon E Well-Known Member

    Joined:
    Dec 9, 2016
    Messages:
    1,987
    Likes Received:
    1,961
    I thought that loaded automatically when you load the program?
     
  41. CobraOne

    CobraOne Active Member

    Joined:
    Jun 3, 2022
    Messages:
    254
    Likes Received:
    189
    Hi Sharon
    Can you check your Master Lever Setting to confirm they match this:
    upload_2024-9-29_11-10-58.png

    Chris
     
  42. Sharon E

    Sharon E Well-Known Member

    Joined:
    Dec 9, 2016
    Messages:
    1,987
    Likes Received:
    1,961
    CobraOne, it matches line for line, but thanks for responding Chris. Still with that ??? of why reverser will not engage while everything else is normal. That lever has in the quadrant away from center, off at full throw and forward then to the center, the entire quadrant from center to full movement to the front is neutral.
     
  43. SJAY_ONE

    SJAY_ONE Active Member

    Joined:
    Mar 11, 2022
    Messages:
    143
    Likes Received:
    194
    Good afternoon. Please tell me what is the current situation with the management of AFB and LocoBrake on German trains? Now I have AFB triggered instead of LocoBrake.
     
  44. SJAY_ONE

    SJAY_ONE Active Member

    Joined:
    Mar 11, 2022
    Messages:
    143
    Likes Received:
    194
    If you do not install the mod, then the reverse works as it should. But the locomotive brake and AFB do not work,
     
  45. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,514
    Likes Received:
    796
    I only suggested to try it and see what happens.
     
  46. Sharon E

    Sharon E Well-Known Member

    Joined:
    Dec 9, 2016
    Messages:
    1,987
    Likes Received:
    1,961
    I do have to say, with all the things I have done to try to get reverse back, the throttle/brake handle is now more responsive and allows me to do finer settings without having to resort to the keyboard.
     
  47. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,514
    Likes Received:
    796
    And you re-calibrated in-game and with Cobraone's program and set the callback before starting the game.
     
  48. SJAY_ONE

    SJAY_ONE Active Member

    Joined:
    Mar 11, 2022
    Messages:
    143
    Likes Received:
    194
    Hello. What do these buttons mean?
    upload_2024-9-30_20-25-17.png
     
  49. Sharon E

    Sharon E Well-Known Member

    Joined:
    Dec 9, 2016
    Messages:
    1,987
    Likes Received:
    1,961
    Yes...
     
  50. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,514
    Likes Received:
    796
    And still no reverse now that is odd, outside of replacing the default Piehid file "as long as you backed it up" and starting over as if you never used Cobraone's program. And you are using 2.0.0.8 correct, I would suggest you try an older version but that is up to Cobraone, and if it's an option.
     

Share This Page