Skip to content

Latest commit

 

History

History
439 lines (250 loc) · 23.6 KB

File metadata and controls

439 lines (250 loc) · 23.6 KB

DIY-Sim-Racing-FFB-Pedal-Mechanical-Design

If you're used to standard spring or damper-based pedals with rumble motors attached, a force-feedback pedal is the next step. It uses a high power servo attached to a linear rail to control the motion of the pedal. This allows you to change how the pedal feels with a few changes on your PC, whether that's braking pressure, response or travel or the thottle weight or stiffness. You can even use profiles to build different "feels" for different cars, switching profiles between cars to give each vehicle a different driving experience. Additionally, since the pedal movement is controlled, the feedback it can produce is totally different - imaging feeling ABS feedback moving the pedal, the kick of the gear change through the throttle or feedback from road bumps through the pedals. It's an experience like no other! If that sounds like something you want to build for yourself, then read on! This project documents people who want to design and/or build their own force-feedback pedal.

Tip

Disclaimer This repository documents my research progress. I wanted to understand the necessary signal processing and control theory algorithms behind such a device.

Warning

The FFB pedal is a robot and can be dangerous. Please watch The Terminator before continuing. If not interacted with care, it may cause harm. I'm not responsible for any harm caused by this design suggestion. Use responsibly and at your own risk.

Project repositories

This project has been divided into multiple repositories, each with differt purposes. The mechanical design repository provides the information you need to build the mechanics of ChrGri's pedal. It's not the only design, but it's strong and reliable. There are more options on the Wiki, and you can find even more designs on the Discord server. The Software repo (this repo) discusses how to select, order and connect the electronics, flash the firmware and get the pedal up and running. The final repo, contains designs for the recommended circuit boards that control the pedal.

Description Link
ChrGri's mechanical and electrical design https://github.com/ChrGri/DIY-Sim-Racing-FFB-Pedal-Mechanical-Design
Software (firmware, SimHub plugin, ...) https://github.com/ChrGri/DIY-Sim-Racing-FFB-Pedal
Control Board and Power Board design https://github.com/gilphilbert/DIY-Sim-Racing-FFB-Pedal-PCBs

Support the team

We ❤️ doing research. New hardware (e.g. oscilloscopes, logic analyzers, servos, PCBs) is very expensive. Feel free to support us and thus fasten up the research activity.

Dev captainchris tcfshcrw gilphilbert
Buy me a coffee
Ko-fi ko-fi ko-fi ko-fi

License

Shield: CC BY-NC-SA 4.0

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

CC BY-NC-SA 4.0

The reason for that license selection is that at some point in time, individuals start

  • to steal the sources and binaries and sell them on the internet
  • mass production of FFB pedals in their living rooms to make money by taking parts from this project and Simucubes design files.

All that, without contributing anything to this project.

Motivation

Originally, I built my DIY FFB pedal from metal parts. After using it some time, I got curious whether I can come up with a mechanical design that can be mostly 3d printed and is still rigid enough to withstand the heavy loads accuring in simracing. Furthermore, I wanted to reduce the weight of the components, hopefully seeing a positive impact in the pedal response time. This repo documents the journey of doing that.

Problem

Usually metal is much stronger than plastic and FDM 3d printed parts are weaker than injection molded counterparts.

Solution

Create a mechanical design, which takes into account the weaknesses of using FDM 3d printed pedal parts and make them strong at weak spots.

Here is a description of the design choices:

To minimize torsional force on the vertical pedal arms arising through pedal activation, the upper loadcell joint is placed at similar height as the pedal face plate centrum. A deeper analysis of the pedal kinematics can be found here.

Since the upper loadcell joint is located rather high, a SFU1610 spindle with 10mm pitch was selected to allow fast pedal movement. Lower pitch spindle could provide more torque and thus axial force but at the cost of reduced movement speed. Also, the SFU1610 spindle typically emmits less noise and feel smother than 1605 spindles.

The linked linear guide was selected, since it has 30mm M4 bold pattern, which works perfectly fine with the SK12 blocks (32mm spacing, 6mm holes). 100mm stroke length is more than needed. 75mm or even 50mm might be sufficient for some users. Alternatively these linear guides are really nice too and even can be ordered with covers, but are more expensive and use 30mm M5 bold pattern which cannot be used out of the box with the SK12 blocks.

The loadcell joints are from off-the-shelf SK12 shaft supports. They are easy to source, reasonably cheap and therefore a good buyout option. Since they are made from matel, they are likely stronger than your bones.

The beefy loadcell was choosen, as it has a M12 thread, which allows easy connection with the M12 ball joint. These loadcells are nice too, but would require adapters or redesign of the loadcell arm.

The pedal arms have a certain width to it, to reduce flex, when pedal force is applied off-centre.

As a base-plate a 2080 aluminium extrusion was chooses as it allows easy screw on of attachments as well as easy and flexible attachment to the simrig.

As a FDM material I choosed PETG-CF, since the carbon fibre particales make the parts supper stiff and the PETG gives good layer bonding while having a better heat resistance than PLA.

Overview

Mechanical design

The mechanical design is depicted below
DiyFfbPedalAssembly v61

image

Electronics

Control PCB

The embedded code of this DIY FFB pedal runs on an ESP32 microcontroller. The PCB design was developed to prove the concept. It holds the ESP32, the ADC, a level shifter, and connectors. Currently, version 3 of this PCB design is used which introduced sensorless homing of the servo. The PCB design and pinout diagram can be found here. When a Simucube wheelbase is used, the D15 accessory port can be used for input. For details see here

Here is an image of the plain PCB:

Here is an image of the assembled PCB:

To order the PCB, follow the instructions.

HINT: The proposed PCB is easy to source, but requires manual soldering. The awesome user gilphilbert designed a PCB assembly of the control board which can be found here. It's currently beeing tested. The current status is published on the discord channel.

Optional but recommended: Power PCB

Depending on the load direction, the servo will act as a generator. It will produce an additional (reverse) current flow from the servo to the PSU which could trigger the over-voltage protection of the PSU and the servo. The iSV57 has a "bleeding/braking resistor" method to dissipate the current flow as heat and thus reduce voltage spikes causing overvoltage protection trigger. The method will be activated when a predefined bus voltage is exceeded (currently 40V). A plot of the voltage fluctuations can be found below:

The trigger voltage was varied in the test (blue: 62V; red: 42V; green: 40V). The horizontal axis shows the time, the vertical axis shows the bus voltage. The pedal was activated a few times, resultig in voltage spikes due to EMF. It can be seen, that the height of the voltage spikes correlate with the trigger voltage. Since the trigger voltage is set to 40V, it is strongly recommended to use a PSU with less than 40V output, otherwise the method will be always active, resulting in an overheating servo.

Although the iSV57s internal braking resistor method is reliably and mostly sufficient, a power PCB was developed to prevent reverse current flow to the PSU and thus prevent triggering the over-voltage protection of the PSU, by adding a Schottky diode to the power line. To prevent the trigger of the over/under-voltage protection of the servo, a small capacitor was added in the power-line.

To hold the components in a small package, a power PCB was developed, which also featured a port to hold XT30 connectors.

Photos of the assembled PCB are depicted below:

A 3d printable housing for the power PCB be found here. It's depicted in the image below.

A deeper analysis of the reverse current flow and investigation of brake circuits can be found here.

Wiring

The wiring is depicted in the image below
Wiring

Warning: The input voltage must not exceed 39V. Recommended voltage is anything between 32V and 37V. When the supplied Voltage exceeda 39V, the servo coils might be energized all the time, resulting in excessive heat.

The Stepperonline documentation suggests to use AWG16 wiring.

BOM

Given prices are just indicators. Sellers regularly offer discounted prices, e.g. I paid for the iSV57 60€, for the linear rail 46€.

Disclosure: Some of the links below are affiliate links, which means we may receive a commission at no cost to you if you make a purchase. By using the provided links, you help me buy tools or hardware for further investigations.

Mechanical parts

Larger parts

Part Info Quantity Price Amazon link Aliexpress link
SK12 4 pieces 4,50€ link link
608zz bearing 2 pieces 5€ link link
Linear guide SFU1610, 100mm stroke 1 piece 60€ link
2080 profile 400mm length 1 piece 15€ link link
M12 ball joint All right handed thread 2 piece 11€ link
M8 threades rod one piece ca. 110mm length 2€ local hardware store link
M12 threades rod two pieces a 45mm + two pieces a 55mm 2€ local hardware store link
M8 self locking nut 2 pieces 0,50€ local hardware store
M5 t-nut 8 pieces 3€ link link
FDM filament ca. 300g 25€ link

Srews/bolds:

Size Info Quantity Price Link
M4x10mm 8 pieces 0,50€
M4x15mm 8 pieces 0,50€
M5x10mm 4 pieces 0,50€
M5x25mm 4 pieces 0,50€
M5x30mm 10 pieces 0,50€
M4 washer 4 pieces 0,50€

Electronics:

Apart from the mechanical parts, more electronical parts have to be ordered. Please conduct the software/electronics repo and the discord for help first, to see if electronic parts are still up to date.

Generic parts:

Part Info Quantity Price Primary link Secondary link
iSV57T-130S shorter version ("130s") is prefered. If the longer version ("130") is cheaper, buy this and cut the motor shaft to appropriate length with a metal handsaw. Alternatively the 180s servo is a bit stronger and not selled out that often. 1 piece 90€ 130s link 180s link
PSU 1 PSU can power multiple pedals (2 at least) 1 piece 25€ link
Loadcell 200kg 1 piece 20€ link link
Servo debug port connector Female, 5P 1 piece 1€ link

Control PCB:

Different connectors are listed below (see option #1 & #2) you'll only need one. The screw terminals are prefered, as (a) they don't require a crimped wire connection and (b) aren't as sensitive to force appied on the wires as JST connectors.

Part Info Quantity Price Amazon link Aliexpress link
Wire (AWG 18 - 26) to connect the control electronics 5€ local hardware store
ADS1256 1 unit per pedal 17€ link link
ESP32 1 unit per pedal 21€ link
Level shifter 1 unit per pedal 7€ link
Option #1: 2.54mm pitch screw terminals 13€ link
Option #2: JST connector box 8€ link
Control PCB Ordered from JLCPCB 1 unit per pedal 5€ https://github.com/ChrGri/DIY-Sim-Racing-FFB-Pedal/blob/develop/Wiring/Esp32_V3/Gerber_PCB_V3.zip

Power PCB:

Component Info Amazon link Aliexpress link
SR5100 Schottky diode 1 diode per pesal link link
80V 1mF capacitor 1 cap per pedal link link
XT30 connector angled 1 male connector per pedal link link
XT30 connector straight For PSU wire, xt30, female link link
1mm2 cable 1m local hardware store

List of printed parts

The print orientation was choosen manually. Support was activated only for the part PedalArmLowerBar.stl.

Part Quantity Required
608zzHolder 2 yes
CncModuleHolder 2 yes
CncModuleHolderLeft 2 yes
Faceplate 1 yes
PedalArmLeft 1 yes
PedalArmRight 1 yes
PedalArmLowerBar 1 yes
PedalArmUpperAdapter 1 yes
PedalSideGuard 1 no

To close the 2080 extrusion front/back, the following part was printed twice:
2080 profile cap

To cover the PSU channels, thr following thing was used (recommended to print at 101% scale, since it was designed with 0% tolerance):
https://www.thingiverse.com/thing:5158578

An adapter to mount the PSU to 4040/4080 aluminium extrusions can be found here:
STL
CAD

It requires the following screws:
4x M4x8mm
2x M5x15mm
2x M5 t-nut for 4040 profile

Parts for JKK rail

Design files for the JKK60 rail can be found here.

Print settings

I printed with 10 perimeters, 10 top/bottom layers, 20% infill. 270°C hotend temperature, 70°C heated bed temperature.

Assembly instructions

Mount CNC guide to 2080 profile with:
4x M4x10mm
4x M5x25mm
2x printed "CncModuleHolder"
2x printed "CncModuleHolderLeft"

Mount pedal plate to pedal arms:
8x M5x30mm
2x SK12

Mount 608zz adapter to 2080 profile:
2x printed "608zzHolder"
2x 608zz bearing
M8x100 rod
4x M5x10mm

Mount SK12 to linear guide:
4x M4x15mm
4x M4 washer
2x SK12

Mount iSV57 to linear guide:
4x M4x15mm

Loadcell:
2x M12x55mm threaded rod
2x M12 nut

Loadcell to SK12:
2x M12x45mm threaded rod

Tips

To reduce any play in the system, I wrapped some layers of teflon wrap around the threaded rods and pushed the 608zz bearings and ball rods over it.

Analysis results

To test the mechanical design, following test were conducted:

Strength test

To be done!

Perhaps FEM analysis

Control loop test

To be done!

Compared to the stainless steel pedal plate, the pedal feels more responsive. Need to verify that by e.g. plotting the closed loop step response here.

Todo:

  1. Weight the parts/pedals.
  2. Draw dimensions
  3. Capture step respose

CAD resources

Linear guide
https://grabcad.com/library/sgx-linear-module-1

608zz
https://grabcad.com/library/608-skate-board-bearing-1

iSV57
https://www.omc-stepperonline.com/de/nema-23-integrierter-easy-servo-motor-130w-3000rpm-0-45nm-63-73oz-in-20-50vdc-buerstenloser-dc-servomotor-kurze-welle-isv57t-130s

SK12
https://grabcad.com/library/sk08-shaft-support-1

2080
https://grabcad.com/library/2080-aluminium-extrusion-european-standard-t6-1

M12 female rod end
https://grabcad.com/library/female-rod-end-m12-1

Loadcell
https://grabcad.com/library/m12-threaded-s-type-tension-compression-load-cell-1000kg-1

Options

Instead of the 608zz bearing, one can also buy two KP08 bearing blocks and take the bearings from there. The benefit is, that they have a screw flange to remove any play between bearing and axis. An example assembly is depicted below:

image.

Simhub plugin config

In the Simhub plugin, you need to parameterize the kinematic properties, for the sake of convencience, here are the measurments captured from CAD image.

OA: 241
OC: 167
CD: 0
CB: 233
AB: 66

Issues

Issue 1: servo slips away

It was observed, that the servo slipped away under braking, see video.

A different PSU was used as the one linked in the BOM. It is assumed that due to heavy braking the PSU wasn't able to deliver the necessary power output and the servo went into undervoltage protection, this slipping away. Its currently beeing tested, whether that is issue is solved by switching the the PSU from the BOM and what software chnages can mitigate the symptoms in the future.

Updates on this issue will be posted here and almost daily on youtube.

A big thank you to Cuttingcorny for reporting the issue and helping to track the issue down.

Status from 8th september 2024:
The PSU from the BOM is now in use. The V3 power PCB as well. With the old software < release 84, the servos overvoltage protection was triggered. After switching to firmware release 85, the pedal seems to work fine. With release 85, new servo parameterization was introduced to reduce EMF of the servo. The problem was thus solved with hardware changes (mainly switch of PSU) and software changes (parameterization of the servos internal braking resistor mode).

Order PCB

  1. Download the control and power PCB, e.g. control PCB V3
  2. Navigate to https://jlcpcb.com/
  3. Upload the gerber files
  4. Leave the standard settings (2 layers, FR-4, 1.6mm, PCB color of your choice, see image below), check which delivery options is the cheapest
    image
  5. Oder the PCB
  6. Wait for the delivery. Typically 10 days to europe.
  7. Solder the electrical compontens onto the PCBs. Refer to the assembled PCB images from above. A good soldering iron makes your life easier. I like TS80 and [TS101]https://s.click.aliexpress.com/e/_DkVMKwN) soldering irons.

Star History

Star History Chart