Jump to content

Open Source Joystick FFB / DIY FFB Joystick


Recommended Posts

@ MetalGear Honk

 

The motor shield is Due compatible. Have a look at the diagram pic I posted and imagine you move the shield straight down on top of Due. Mounting holes and pin layout is identical.

 

Regarding the "cross" gimball STL you were asking for..

I don't think it's worth the effort to struggle with 3D printed version as it is very delicate and precise mechanism requiring some level of rigidity and since you have workshop available I would suggest to go for metal solution right away.

I can draw a 3D model, verify it's functionality and share it here if that helps..

 

Jay

Link to comment
Share on other sites

  • Replies 419
  • Created
  • Last Reply

Top Posters In This Topic

Thanks, your advise is very useful!

Because I want to implement A/T disconnect with simple mechanism, I thought that servo output info(rotate speed, position) is good.

How do you think about A/T disconnect?

 

from A1-F18AC-NFM-000

"If a force of approximately 12 pounds (with friction off) is applied to either throttle the system automatically disengages."

 

BTW, Should I create a new thread…?

I want to add simplified function for OSFFB Option.

Link to comment
Share on other sites

well you don't have to disconnect A/T mechanically.

The slip clutch in the video provides natural friction on the levers when the motors are not active and as soon as you engage A/T and let go of them, they will follow the A/T.

In conclusion I would suggest to program "disconnect" function into firmware that looks after servo circuit (dc motor - hall sensor/pot)

Something like [when pot reading and motor position differ for more than ? sec = A/P disengage]

 

Jay

Link to comment
Share on other sites

What do you want FFB to do?

 

Have looked at the possibilities of force feedback for a flight stick several times. The original idea was a stepper motor for each axis. Would be simple to implement. There are two primary drawbacks. 1. The amount of force applied in the leverage of the stick exceeds what the stepper motor can handle. 2. The step size was too large for accurate control.

 

The last few days have been trying to understand the trim system on the A-10C. There are approximately 20 increments for nose down and 40 for nose up. One of the main concerns I have with the trim system is that it requires two simultaneous actions. Activation of the trim and then an unrealistic repositioning of the stick to offset the trim input.

 

Once I could observe what the trim was doing and then remembering my private pilot days it occurred to me that I have been looking at FFB from a wrong perspective.

 

So I'm going to ask a somewhat silly question. What are you trying to achieve with a FFB joy stick?

 

My concept is to feel the loading of the elevator and aileron in reference to the set trim position. That would allow for trimming of the aircraft by feel.

 

Your thoughts please.

VR with Oculus Rift preferred flying method.

Link to comment
Share on other sites

Wow, I hadn't checked this thread for a month or two thinking it had all gone quiet but POW, it's just exploded!!! Great to see :thumbup:

 

I made a brief mention in this thread, adding my voice as support back in June when I thought things were stalling out but am delighted to see this project picking up steam again :) :)

 

So I'm going to ask a somewhat silly question. What are you trying to achieve with a FFB joy stick?

 

My concept is to feel the loading of the elevator and aileron in reference to the set trim position. That would allow for trimming of the aircraft by feel.

That is pretty much exactly what I am after CrossWise. For my part I am working on designing a sim-pit to replicate a glider and accordingly was designing a joystick (control-stick) to use in the sim-pit but hit a road block when it came to designing the re-centering springs. It is actually surprisingly difficult to design a good centering mechanism, at least it is for a bloke like me :D. That is when I happened upon this thread and have been following its progress with great enthusiasm ever since. In particular what I am most hoping to achieve from this project is the ability to set a trim point that is off-center of the joysticks center. That is, if the trim is set nose down, have the stick 'return' to a point a little forward of center and if trimmed nose up have it 'return' aft of centre. This would also be most welcomed when flying helicopters that use a 'force-trim' (such as in the DCS Huey). The current system of re-mapping what the center of the joystick represents (rather than changing where the stick returns to) is cumbersome to say the least. As it is I have actually resorted to removing the spring entirely from my X56 HOTAS when flying the Huey as I find the simulated force-trim so disagreeable. While removing the spring works fine for flying it means you can never let go of the stick while in motion as once you do the stick just flops over leading to an inevitable crash. Most annoying!

 

Additional 'effects' such as velocity dependent force (ie. sloppy controls at stall point) and 'canned effects' such as machine gun fire and landing gear jolts etc. are added benefits, but it really is the trim that I hunger for. That and a way to re-centre my homemade joystick without resorting to springs :D

Link to comment
Share on other sites

well I have the grip stick gimbels transfer rods and DC torque mothers along with H bridge controllers. as long as we don't fry it I am willing

https://www.shapeways.com/shops/a-10c-warthog-supplies

https://forum.dcs.world/topic/133818-deadmans-cockpit-base-plans/#comment-133824

CNCs and Laser engravers are great but they can't do squat with out a precise set of plans.

Link to comment
Share on other sites

Hi all

Ok first things first.

@crow:

I like your idea but I think it is betterto open a new thread.

As I don't think it can be built into aHID-PID device. Because there is almost no way to transfer the data it wouldneed without additional Drivers/connections.

@Slartibartfast:

Feel free to grab the code and have alook. Ask if something is unclear.

And don't be too shocked about myProgramming style.

@VR FlightSim

About the Motor Shield. The Pins that Iselected for the Bridge are not the same as intended by the shield. So you needto rewire it Manual.

@Deadman

I cannot guaranty that you will not killyour Equipment.

So you (and everybody else including me)do all testing on their own risk.

@crosswise

What Forces are Feld on the stick dependson the Sim Designers. They decide what force to use and how strong/Directionand when.

The PID Document describes all availableEffects, as there are:

1. Constant Force

2. Ramp

3. Custom Force / Data

4. Square

5. Sine

6. Triangle

7. Saw tooth up

8. Saw tooth down

9. Spring

10. Damper

11. Interia

12. Friction

No more no less

Looking at the Forces and the function weall are most interested in are

9. Spring

To give an Offset Center.

10. Damper

To simulate Wing load

11. Ramp

To add to Wing load

And one or more from the PeriodicFunctions

4 - 8

For Ground rumble / Guns / Stall

These functions are supported byDirectInput and are the ones I/we are hoping to get. As these are the ones mostSims Support.

All These Forces are send in three blocks.

1. Effect Type

2. Type Specific Block 1

3. Type Specific Block 2

Exaple1

1. Spring - 2. Condition X-axis - 3.Condition Y-axis

Example2

1. Sine - 2.Periodic - 3. Enveloppe

These Info’s are send at the beginning ofthe Sim (when entering a Plane in DCS)

There can be multiple Effects of the sametype. And they can be changed or deleted during the sim.

When the Sim decides that an Effect shouldbe played it only sends the "number" which should be played. So thereis less delay for the feel.

More in deep Info’s about FFB can be foundin the pid01_01.pdf

In the DirectInput Documentation or at myDesk. smilewink.gif

MetalGear_Honk

The threemost dangerous threads to Programmers:

  • Fresh air
  • Bright sun light
  • The horrifying screams of singingbirds

Link to comment
Share on other sites

Good morning boys:)

 

MetalGear Honk don't forget "Friction". That's what simulates wing mass and cable load.

"Damper" just kills the force when you let go of the stick so it won't overshoot the center resulting in shaky dance.

Other than that, your list has pretty much all we need..

 

How would you guys feel about Trim system that has actually nothing to do with the sim it self

but only moves center of the "spring load" on the stick. We would need to include such function into the script or windows app so we could control this with Hat switch or external axis (physical trim wheel).

 

This is how it works on my yoke at the moment and trimming by "feel" is a breeze;)

 

 

Jay


Edited by VR FlightSim
Link to comment
Share on other sites

@Slartibartfast:

Feel free to grab the code and have alook. Ask if something is unclear.

 

Yeah, I'll be keen to, though I'm a little unsure of where to start. I am however between jobs at the moment so have plenty of time to devote to the venture.

 

So, where do I start???

I've read through the entire thread and never came across a guide or even a particularly succinct parts list. While I've been a software engineer for many years now I've never worked with embedded code before so find the initial step a little daunting, though I'm most definitely keen to get into it!

 

So I take it the first thing I'll need is an Arduino, yeah. But which should I order (DUE?, pro mini?, or even a Teensy?). When I was looking into building my own joystick I was leaning toward the Leo Bodnar boards but I take it the advantages of the Leo boards would never be realised in this project as we are essentially programming the whole thing ourselves, yeah? So what would be a suitable board to start off with? And what else should I order in order to get cracking?

 

Cheers,

Slarti.

Link to comment
Share on other sites

Hi Slartibartfast

Given that you are Familiar with c++

Get the Atmel Studio 7 and open the code Ihave uploaded.

This Version is for an ATMega32u4 NOT foran Arduino.

You can use the Micro that is onboard aPro Micro but you need to kill the Bootloader to get the Joystick running.

LUFA is running inside the Micro so if yougot it right you can use "Flip" to reprogram the Controller.

@ All

I really thought that I had written asmall tutorial about programming a Controller. But I can't find it.

For short Google "ISPProgramming" there are plenty of tutorials.

MetalGear_Honk

The threemost dangerous threads to Programmers:

  • Fresh air
  • Bright sun light
  • The horrifying screams of singingbirds

Link to comment
Share on other sites

Hello again to all FFB freek ;) !

 

@melalgear honk may i suggest a littlebit crasy idea ...

 

As i and perhaps many don t have the knownledge about coding , would it be possible to send me a preprogramed arduino nano pre-loaded with the code so we would only have to connect the pin to potentiometers and pwm output to a l298 controler ?

 

I can pay via paypal for example a reasonable price and you could get more feedback and share our hardware building.

 

Just a prposition , if you can think about it ;) .

 

Best regards ,

 

JP

Link to comment
Share on other sites

@MetalGear

 

I would be keen to follow this, although I haven't done any C++ for many years I have done fully interrupt driven assembler code for AVR some time ago as well. :D

 

Where can I get the source code??

 

Frag

Control is an illusion which usually shatters at the least expected moment.

Gazelle Mini-gun version is endorphins with rotors. See above.

 

Currently rolling with a Asus Z390 Prime, 9600K, 32GB RAM, SSD, 2080Ti and Windows 10Pro, Rift CV1. bu0836x and Scratch Built Pedals, Collective and Cyclic.

Link to comment
Share on other sites

...would it be possible to send me a preprogramed arduino nano pre-loaded with the code so...

 

Once I've worked out how to do it myself I would be willing to do as much for you but I really would suggest you'd be far better of learning how to do so yourself. The problem with sending pre-installed boards out is that you would then be stuck with whatever version was sent to you and I dare say there are likely to be several revisions to the code as this project progresses. Loading a program onto a PCB really isn't that hard and no real programming knowledge is required to do so. It really would be just a process of "following the instructions".

 

So I would advice that getting your own board and learning how to upload code to it (even if you don't understand how that code actually works yourself) would serve you a lot better. In fact, if you have the know how to build the rest of the FFB system uploading the program to the PCB would be the easy part :smartass:.

 

When I get on top of this myself I'll do my best to provide a set of easy to follow instructions for the community such that everyone can install/update their boards, regardless of their level of programming knowledge :baby:


Edited by Slartibartfast
Link to comment
Share on other sites

Hi

To use a Pro Micro:

First we need to get rid of the ArduinoBootloader.

For that we will need an ISP or a JTAGProgrammer.

ISP is cheaper and you can use anotherArduino for that.

The Problem here is that most Programmeruse their own Software.

I will try to get the instructions out ofmy Memory.

Usingan Arduino uno:

1. Load the Arduino IDE.

2. Connect the Uno to your PC (USB)

3. Open the source code"ArduinoISP" from the Examples Folder

4. In the Tools/Board Folder select thecorrect Serial port.

5. Press the upload button

6. Wire the Uno to the Pro micro

UNO Name Micro

Pin 11 MOSI Pin16

Pin10 Reset RST

Pin12 Miso pin14

Pin13 sck pin15

+5V Voltage VCC

GND Ground GND

7. Select sketch/Upload with programmer

8. Select the HEX I uploaded.

That should be it.

No guaranty I haven’t done it this way fora Long time.

MetalGear_Honk

The threemost dangerous threads to Programmers:

  • Fresh air
  • Bright sun light
  • The horrifying screams of singingbirds

Link to comment
Share on other sites

I am not much help when it comes to programming, but I can help with the gimbal design if it is needed. Let me know.

 

I would certainly appreciate some help with gimbal design.

 

As mentioned before the joystick I've been working on is intended to be used in a glider sim and a curious thing about gliders is that the X and Y axis often pivot at different heights. That is the pitch-axis is literally longer than the roll-axis.

 

Like this:

Piper.png

(but the other way round, ie. long pitch and shorter roll)

 

I have done the best I can designing such a gimbal in SketchUp and even made a prototype but I'm afraid I really am at my limit as far as mechanical design goes :sly:

 

Here's an image of what I have designed though:

BoltLimit_axis.jpg

The bolts in the image are so you can set physical limits on the amount of travel (arc) each axis has available.

The glider I'm modeling has a range of movement of:

10° forward

25° backward

17° side to side

 

And here is a short video of the prototype I made:

 

However I have no idea how I'm going to fit the FFB gear to this. Fortunately space isn't too much of a constraint as this is going to be bolted into a pit and the rest of the pit can be literally designed around whatever's needed.

 

One thought I had was rather than connecting the motors to the axle's of the gimbal itself either notch or attach gears on these parts:

Gears.jpg

 

And place the motors themselves on the 'inside' such that when activated they 'crawl' around the stationary gear and turn themselves along with the rest of the stick.

 

Anyway, if you willing to offer any assistance on this design (or something else that can be modified to accommodate my unique requirements) I'd me most appreciative.

 

P.S. If their of assistance I'll be more than happy to make my SketchUp models available but like MetalGear_Honk says, these files are far from professional :wacko: :doh:

Link to comment
Share on other sites

It is the same in the A-10 gimbal. in my cockpit the gimbal is attached to two transfer rods both pitch and roll are transferred down the length of the cockpit in for and aft motion then attache to the DC torque motors

https://www.shapeways.com/shops/a-10c-warthog-supplies

https://forum.dcs.world/topic/133818-deadmans-cockpit-base-plans/#comment-133824

CNCs and Laser engravers are great but they can't do squat with out a precise set of plans.

Link to comment
Share on other sites

Hi all

I have been playing around with someMotors. And now I think that I need to adjust my Idea for the PWM to use forPower.

The Motors I have tested are weak so itmight be the source of my concerns. When I test some of the effects it looksmuch like the Motors don't do anything. Only if I use effects with Forces over70% I get Feedback. So I investigated some more and realize that my Motors arenot linear thou there power usage.

I am still using the internal ADC scaleddown to one Byte. Using a 16bit ADC would give us more precession in theForces. But I am afraid that we lose a lot if I simply cut the lower PWM rangeand use the upper 30% linear.

Any Thoughts on that?

Someone with more Info’s on Motors?

I am thinking of using a sort ofCalibration Ramp to make the Motors power range more linear. But that wouldmean that every Motor needs its own Calibration curve.

For the Gimbal:

I am working on a very simple design and Ihope to finish it over the Weekend. If it works out it will be easy enough tobe reproduced in a Basic Workshop. With no Special Tools needed.

I couldn't get it 3D-Printer friendly so Iswitched back to Aluminum.

I don't have the drawings completed as Idraw it up while I test it out.

Although I am using Old-school Equipmentin my Workshop (pen and Paper)

MetalGear_Honk

The threemost dangerous threads to Programmers:

  • Fresh air
  • Bright sun light
  • The horrifying screams of singingbirds

Link to comment
Share on other sites

if we are discussing about motor regulators and and the signal is PWM... would not be possible to use RC motors and their regulators? I know their regulators are at least 16 KHz precisison and can be found for 32 KHz with ease. Good regulators can be also calibrated according with the number of poles of the motor they are controlling.

Also the power drained by motors will not be a problem at all.

Romanian Community for DCS World

HW Specs: AMD 7900X, 64GB RAM, RTX 4090, HOTAS Virpil, MFG, CLS-E, custom

Link to comment
Share on other sites

Hi all

I have been playing around with someMotors. And now I think that I need to adjust my Idea for the PWM to use forPower.

The Motors I have tested are weak so itmight be the source of my concerns. When I test some of the effects it looksmuch like the Motors don't do anything. Only if I use effects with Forces over70% I get Feedback. So I investigated some more and realize that my Motors arenot linear thou there power usage.

I am still using the internal ADC scaleddown to one Byte. Using a 16bit ADC would give us more precession in theForces. But I am afraid that we lose a lot if I simply cut the lower PWM rangeand use the upper 30% linear.

Any Thoughts on that?

Someone with more Info’s on Motors?

I am thinking of using a sort ofCalibration Ramp to make the Motors power range more linear. But that wouldmean that every Motor needs its own Calibration curve.

For the Gimbal:

I am working on a very simple design and Ihope to finish it over the Weekend. If it works out it will be easy enough tobe reproduced in a Basic Workshop. With no Special Tools needed.

I couldn't get it 3D-Printer friendly so Iswitched back to Aluminum.

I don't have the drawings completed as Idraw it up while I test it out.

Although I am using Old-school Equipmentin my Workshop (pen and Paper)

MetalGear_Honk

 

Hi

 

I'm watching this thread closely with great interest...

 

As from my experience there are some important things:

 

1) Which voltage level are you using to drive the motors ?!

 

if the voltage is too low - the motor will develop poor torque.

 

There is a complex theory about it. yet to put things simple - in order to get higher torque - one's need to raise the supply voltage. (this will allow the current levels to raise faster for a given frequency of PWM).

Supply voltage not only has to meet , but exceed the rated voltage of the motor depending on PWM frequency , response time required , torque required and the declared Wattage ratings of the motors for continues operation.

 

Thus been said , the way to achieve all is to raise the voltage. the problem it creates - is higher currents - not good for motors and for the entire project...

 

Overcoming it is rather simple - using current limitation circuitry.

 

What is the PWM frequency ?!

 

A Transformer - is much more efficient at higher frequency.

In DC motors - finding the sweet spot that trades off between torque to efficiency (for reduced loss of energy through unwanted heating) is a challange. yet can be resolved through trial and error...

 

I just cant wait to see further progress on this breakthrough project !

 

Maybe I could help with gimbal design and drive circuitry...

 

I think this thread is magnificent and I urge you to open a parallel post with already achieved milestones of it (files , REV's and more) . in this thread - will keep on active development posts...

 

Cheers !

Nir Bar

"Schredder"

 

"In the warrior code there's no surrender,

though his body says stop,his spirit cries...

NEVER !!!"

Link to comment
Share on other sites

Looks good.

 

How about replacing the drive gears with planetary gears for some additional torque which would reduce the torque requirement of the motors in favour of higher motor shaft RPM?

Control is an illusion which usually shatters at the least expected moment.

Gazelle Mini-gun version is endorphins with rotors. See above.

 

Currently rolling with a Asus Z390 Prime, 9600K, 32GB RAM, SSD, 2080Ti and Windows 10Pro, Rift CV1. bu0836x and Scratch Built Pedals, Collective and Cyclic.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...