Jump to content

Idea / need help programming, force feedback steering wheel as EU07 power wheel.


Recommended Posts

The EU07 loco's use a 'steering wheel' to adjust the power, a single rotation of just less than 360 degrees, with 43 notches, each one being an increase or decrease in power (ignore the bit about how it's working on the train with the resistances being switched in / out etc) 

Most people into train sims are also into road based driving games / sims, so likely have a force feedback steering wheel already, and i know a lot of people lack the skills, equipment and time to build custom controllers from scratch. 

So how about using that 'store bought' force feedback wheel to drive the EU07 ?

To do this would need 2 things, a program which can 'emulate' a static force feedback map, and the output from moving the wheel to send a keyboard press for increase or decrease power (until we get controller support in the sim)

Now programming is where i fall flat on my face, so i am wondering if there's anyone out there who has an idea if this can be done...

Rather than having the FFB wheel connect to the game being played as usual, we'd run a program that connects to the wheel and sets up a static 'notch map' 
So the wheel will move around from 'straight ahead' to 180 degrees to the left, and then when you grab hold of the wheel and turn it to the right, you feel the feedback increase, then you go 'over the hump of the notch' and the wheel clicks into the first power setting, 

After a pause you turn the wheel some more, clicking through the notches that feel like turning a big heavy rotary switch, a heavier notch is present at notch 28 (the series / parallel motor connection point) then again more clicking / clunking as you move through to notch 43, where the feedback stops you going any further. 


When we get more trains in SimRail that use these notch wheel / handle types of power controls, we could have multiple different 'notch maps' that we set to match the train we are driving, i.e. the EN57... that uses a handle to rotate through i think 7 notches, so again the FFB wheel could be used to drive that train. 

Got 2 FFB wheels and the ability to mod things a little... remove the wheel and fit a handle and you have a brake lever... again a notch map is sent to the wheel and the force feedback generates the resistance and clicks as the brake lever is moved around (i know most car type FFB wheels point at about a 75 degree angle off vertical, but an L shaped piece of wood clamped or screwed to the desk will allow the wheel to clamp on, rotated upwards so the wheel points almost straight up, i did this for my Omsi driving desk) 

 

I had an idea a few years ago about making force feedback train driving levers of the types used in modern trains, there i was going to use an arduino to control it, and someone on the arduino forum made this graph to show the feedback profile for the notches:

image.png.89e19c378611fd5e24d8b97959b339da.png

Can this be done with a windows program / API that would communicate with a standard shop bought FFB steering wheel? 

I found a website that lists how Linux does force feedback, would that be possible to use on a windows program / API to send a static 'notch map' to the FFB wheel? 

https://www.kernel.org/doc/html/v4.13/input/ff.html

 

 

 

Edited by Gazz292
  • Like 2
Link to comment
Share on other sites

that's exactly what i'm thinking... people will have a force feedback wheel already, or can buy one pretty cheaply (i paid £50 for my Logitech driving force GT, 900 degree wheel) 

Find a way to interface with it and set a 'notch map' and we have an awesome and realistic way to operate the EU07's power wheel. 

Anything i find out about this i will share here

Edited by Gazz292
  • Like 2
Link to comment
Share on other sites

Logi G27 dusting down  here aswell, would be fun to use it in SR. 


A little sidetrack/derailment for more ways wheels can operate(sorry 🙂 ):

In Norway we have loco (EL14)with wheel and notches, but is operated in similar manner to the traxx lever:

Brake on left half. 0 top center and throttle on right half with positions:

Brake UP | Maintain brake | Brake DOWN   | 0 |  Throttle DOWN | Maintain throttle | Throttle UP   

The loco has 32 notches thottle and 21 braking.

For going forward;
Move wheel to throttle maintain. To notch up hold it in Throttle UP and it will notch up every 0,3 seconds. When happy keep wheel in Thottle maintain.
Uncertain if its springloaded back to maintain or if its sticks to UP/DOWN. Would suspect it to be spring loaded.

To brake(dynamic):
Move wheel over to "BRAKE MAINTAIN" then add brake notches holding it in Brake UP. To reduce notch, hold it in "BRAKE DOWN"


We also have a EMU "Type 69 / BM69":
Where in automatic mode: you would have a notch for every 10 km/h up to 130km/h.
Acceleration/braking in a standard rate. Possible to reduce the traction/brake force if slippery. Similar to the ELF cruisecontrol operation.

Another usecase would be mounting the wheel vertical and adding a lever of some sort and use it as a brakelever. 😄 


I'll certainly monitor this aspect of the sim, like your buttonbox. Very cool. I have made myself a stand for my old saitek levers, but would love to expand on it later on.
I think I would make it universal though as I like variation 🙂 

Edited by Deadlost
Link to comment
Share on other sites

i have an idea to make force feedback levers one day,  i.e. the traxx power and brake levers, 


But i want to start with using something anyone could use, i.e. an off the shelf force feedback wheel and a little program / API that run on the computer to turn it into a train power control wheel

Then i can get into making a FFB lever from scratch using an arduino to control the motor and output, and as many 3D printed parts as i can, so others can make them without needing a machine shop.

I did make a 'mostly' 3D printed mechanical set of levers last year, with interchangeable notch plates to suit different trains, but that was when i was messing with tsw... but after waiting almost 5 years the promised joystick control interface never materialised, and i gave up... on the controller build and that game. 

  • Like 1
Link to comment
Share on other sites

so, there's this SDK for adding force feedback to games for logitech wheels :

https://www.logitechg.com/en-gb/innovation/developer-lab.html

but i have no idea what to even look at, i've never written a windows app/program before (writing simple arduino sketches is my limit... and that's modifying existing ones usually)

What i'm thinking... you know with a FFB wheel's software you get some 'test effects', i.e. press a button and the wheel shakes left to right, press another and it wangs right around from stop to stop etc.
Could a constant effect be sent to the wheel i wonder, in the form of a sine wave shaped 'notch map' from this test like thing,
allowing the the wheel to produce the notches of the power wheel as it's rotated,

Then output the wheel position signal, which can somehow be made to give a keyboard key 'press' for each notch that is moved to in one direction, another keyboard key press in the other direction. 

Link to comment
Share on other sites

I found there's a glitch with the pattern on the graph. If you steer the wheel between two notches there's a chance the wheel will stick into a position between two notches (transition from -1000 to 1000 it may stuck at 0). So I recommend a detection mechanism, in that transition area, depending on the wheel rotation direction, just let the wheel produce some self-rotation effect during the transition(when the wheel is turning).

Actually considering the actual shape of the inside, from -1000 to 1000 the static force in the transition area should always be 0 with a static damping effect to simulate friction.

image.thumb.png.47e42325f385eeac9bca8d9d1c9bfd6a.png

Edited by KagurazakaYukari
  • I agree 1
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Our servers

    • Drivers | Maszyniści Drivers | Maszyniści
      • PL2
      • pl2
      • 74 / 82
          • Percentage filling 90%
          • Most players 90
      • PL3
      • pl3
      • 12 / 77
          • Percentage filling 16%
          • Most players 76
      • PL4
      • pl4
      • 20 / 81
          • Percentage filling 25%
          • Most players 84
      • PL8
      • pl8
      • 9 / 80
          • Percentage filling 11%
          • Most players 84
      • EN1
      • en1
      • 58 / 82
          • Percentage filling 71%
          • Most players 81
      • EN2
      • en2
      • 0 / 35
          • Percentage filling 0%
          • Most players 60
      • EN3
      • en3
      • 1 / 78
          • Percentage filling 1%
          • Most players 60
      • DE1
      • de1
      • 51 / 83
          • Percentage filling 61%
          • Most players 87
      • DE3
      • de3
      • 3 / 78
          • Percentage filling 4%
          • Most players 67
      • DE4
      • de4
      • 0 / 74
          • Percentage filling 0%
          • Most players 65
      • FR1
      • fr1
      • 18 / 78
          • Percentage filling 23%
          • Most players 49
      • UA1
      • ua1
      • 1 / 78
          • Percentage filling 1%
          • Most players 27
      • CN1
      • cn1
      • 6 / 79
          • Percentage filling 8%
          • Most players 28
      • CZ1
      • cz1
      • 0 / 70
          • Percentage filling 0%
          • Most players 61
      • ES1
      • es1
      • 1 / 75
          • Percentage filling 1%
          • Most players 23
    • Dispatchers | Dyżurni ruchu Dispatchers | Dyżurni ruchu
      • PL2
      • pl2
      • 30 / 34
          • Percentage filling 88%
          • Most players 34
      • PL3
      • pl3
      • 2 / 34
          • Percentage filling 6%
          • Most players 28
      • PL4
      • pl4
      • 10 / 34
          • Percentage filling 29%
          • Most players 31
      • PL8
      • pl8
      • 6 / 34
          • Percentage filling 18%
          • Most players 27
      • EN1
      • en1
      • 30 / 34
          • Percentage filling 88%
          • Most players 33
      • EN2
      • en2
      • 4 / 34
          • Percentage filling 12%
          • Most players 21
      • EN3
      • en3
      • 2 / 34
          • Percentage filling 6%
          • Most players 13
      • DE1
      • de1
      • 33 / 34
          • Percentage filling 97%
          • Most players 34
      • DE3
      • de3
      • 15 / 34
          • Percentage filling 44%
          • Most players 29
      • DE4
      • de4
      • 4 / 34
          • Percentage filling 12%
          • Most players 24
      • UA1
      • ua1
      • 1 / 34
          • Percentage filling 3%
          • Most players 17
      • FR1
      • fr1
      • 6 / 34
          • Percentage filling 18%
          • Most players 23
      • ES1
      • es1
      • 3 / 34
          • Percentage filling 9%
          • Most players 15
      • CZ1
      • cz1
      • 7 / 34
          • Percentage filling 21%
          • Most players 28
      • CN1
      • cn1
      • 7 / 34
          • Percentage filling 21%
          • Most players 19
    • 30 Total servers
    • 414 / 1640 Total players
    • 25% Filled servers
×
×
  • Create New...

Important Information

Terms of Use Privacy Policy