Getting Load Cell G27 pedals to work with MMOS STM32F4-Discovery board

After working out how to connect the G27 shifter to my STM32F4 Discovery running the MMOS OpenSimWheel firmware, I moved onto connecting the pedals.  My Logitech G27 pedals are modified, and I’m using a load cell for the brake pedal.  The gas/clutch are using the original potentiometers.

If you have standard G27/G25 pedals, with the original potentiometers, then this workaround doesn’t apply to you.  If your load cell brake outputs 5V at rest, and 0V when depressed, then this workaround isn’t required.

Anyway, back to an issue I found with my specific load cell brake setup.  When I connected my modified G27 pedals to the Disco board, only the brake was working.  I used DIView and DXTweak to watch the raw signals were for the pedals, coming from the Discovery board.  The gas and clutch pedals were just jumping around at one end of their axis, and not working. In the end I figured out that it was caused by the load cell output being the inverse direction of the gas and clutch pedals.

Logitech G27/G25 pedals output 5V when they are at rest, and 0V when you press the pedal fully down.  My load cell brake pedal outputs 0V at rest, and 5V when fully depressed.  The MMOS 0.99 firmware doesn’t seem to like the brake axis being the reverse of the clutch/gas.  The solution for me was to open the pedals up, and swap the Vcc and Gnd wires where they connect to the potentiometers on the gas and clutch pedal (the outside two pins – red and black).

You can see the pins I’m talking about in this photo on chillicoke.

Update: I’ve built a completely custom set of hydraulic + load cell pedals, and they’re brilliant.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s