1. We have a few rules which you need to read and accept before posting anything here! Following these rules will keep the forum clean and your stay pleasant. Do not follow these rules can lead to permanent exclusion from this website: Read the forum rules.
    Are you a company? Read our company rules
  2. Do not share user accounts! Any account that is shared by another person will be blocked and closed. This means: we will close not only the account that is shared, but also the main account of the user who uses another person's account. We have the ability to detect account sharing, so please do not try to cheat the system. This action will take place on 04/18/2023. Read all forum rules.
    Dismiss Notice
  3. For downloading SimTools plugins you need a Download Package. Get it with virtual coins that you receive for forum activity or Buy Download Package - We have a zero Spam tolerance so read our forum rules first.

    Buy Now a Download Plan!
  4. Do not try to cheat our system and do not post an unnecessary amount of useless posts only to earn credits here. We have a zero spam tolerance policy and this will cause a ban of your user account. Otherwise we wish you a pleasant stay here! Read the forum rules
  5. We have a few rules which you need to read and accept before posting anything here! Following these rules will keep the forum clean and your stay pleasant. Do not follow these rules can lead to permanent exclusion from this website: Read the forum rules.
    Are you a company? Read our company rules
  6. Do not share user accounts! Any account that is shared by another person will be blocked and closed. This means: we will close not only the account that is shared, but also the main account of the user who uses another person's account. We have the ability to detect account sharing, so please do not try to cheat the system. This action will take place on 04/18/2023. Read all forum rules.
    Dismiss Notice

DIY Pedals & Buttons Controller

Discussion in 'DIY peripherals' started by TOPMO3, Jul 30, 2016.

  1. bhavesh-jadav

    bhavesh-jadav New Member

    Joined:
    Dec 2, 2017
    Messages:
    1
    Location:
    India
    Balance:
    117Coins
    Ratings:
    +0 / 0 / -0
    My Motion Simulator:
    Arduino
    Hi there,
    This is a very nice and cool project that you have built.
    I have one question regarding encoders. Can I use encoder as steering axis in video game?
    For example initial position of encoder will determine initial position of steering wheel . If I move encoder left then steering axis should also move left and vice versa.
    In my previous project I read encoder value through arduino and mapped that value between -32768 to 32768 then send that value to the PC as axis value.
  2. Grizus

    Grizus Member Gold Contributor

    Joined:
    May 6, 2017
    Messages:
    72
    Location:
    Warsaw PL
    Balance:
    349Coins
    Ratings:
    +98 / 2 / -0
    My Motion Simulator:
    6DOF
    Hello @TOPMO3 !!!

    great project, very intuitive, thank you for sharing it !!!

    please tell me is there any possibility that I would be able to choose the voltage of sensor supply ? I mean I have pressure sensors that need to be powered by 5V and your software works well with 3.3V power. When it gives a signal from a 5V powered sensor, it uses only about 65% of range :(

    I have very expensive sensors that I wanted to use for the hydraulic brake pedal and handbrake. Is it possible that they work in the full range??? unfortunately they do not work when I connect them to 3.3V :/

    Thanks !!
    Last edited: Dec 4, 2017
  3. TOPMO3

    TOPMO3 Active Member

    Joined:
    May 12, 2015
    Messages:
    133
    Location:
    Russia
    Balance:
    894Coins
    Ratings:
    +201 / 0 / -0
    Sorry, no good news for you guys

    I see what you mean, but currentlly its not possible to map encoder's value to an axis. Maybe later I can do this.


    The STM32F103 chip's ADC upper limit is 3.6V, so we can do nothing with your problem. Is it possible to tune your sensor output to 3.6V? Some sensors have separate Power and Reference Voltage pins
  4. Grizus

    Grizus Member Gold Contributor

    Joined:
    May 6, 2017
    Messages:
    72
    Location:
    Warsaw PL
    Balance:
    349Coins
    Ratings:
    +98 / 2 / -0
    My Motion Simulator:
    6DOF
    My sensor do not have separate Power and Reference Voltage pins :( but I found the password "Voltage Divider" , it looked simple so I tried it :) and that solved my problem, I use resistors like on this scheme and changed 0-5V to 0-3.4V

    voltage divider.jpg

    Is this a good solution ??
    • Like Like x 2
  5. TOPMO3

    TOPMO3 Active Member

    Joined:
    May 12, 2015
    Messages:
    133
    Location:
    Russia
    Balance:
    894Coins
    Ratings:
    +201 / 0 / -0
    You know, I think yes, its good - simple and effective :)
    • Like Like x 1
  6. xiatian

    xiatian Member

    Joined:
    Sep 5, 2017
    Messages:
    78
    Location:
    Xi'an, China
    Balance:
    262Coins
    Ratings:
    +28 / 0 / -0
    My Motion Simulator:
    2DOF
    I'm going to make one such control board too, that is to weld and I still practice.
  7. Giustino

    Giustino New Member

    Joined:
    Jul 17, 2017
    Messages:
    9
    Location:
    Italy
    Balance:
    247Coins
    Ratings:
    +5 / 1 / -0
    Hi @TOPMO3 , Of sure I'm still going OT, but I want to show you the result of your work thanks to which I managed to make this jewel. Thanks again and merry Christmas

    Attached Files:

    • Like Like x 3
    • Winner Winner x 2
    • Optimistic Optimistic x 1
  8. TOPMO3

    TOPMO3 Active Member

    Joined:
    May 12, 2015
    Messages:
    133
    Location:
    Russia
    Balance:
    894Coins
    Ratings:
    +201 / 0 / -0
    Wow, very nice looking rim, @Giustino ! I really like it
    Merry Chrismas you too, mate! :cheers
  9. razzor13bt

    razzor13bt Member

    Joined:
    Jan 10, 2017
    Messages:
    32
    Occupation:
    automotive technician, sales manager.
    Location:
    Durban, South Africa
    Balance:
    393Coins
    Ratings:
    +8 / 0 / -0
    awesome job there Giustino.
    All of the best for the new year guys.
  10. Quail85

    Quail85 New Member

    Joined:
    Dec 7, 2017
    Messages:
    7
    Occupation:
    Copywriter
    Location:
    Whitby, Porirua, New Zealand
    Balance:
    172Coins
    Ratings:
    +9 / 0 / -0
    Thanks for this tutorial and program @TOPMO3 !

    I ordered some bits and bobs which finally arrived so now I started on my button box for Euro Truck sim 2 / American Truck sim :)

    Can't wait to get it all rigged up. It's my first time doing any of this so should be an interesting experiment.

    Will keep you updated with progress!

    Thanks again!
    • Like Like x 2
  11. BS21

    BS21 Sim Tutorial: www.youtube.com/BSGamingSimulator

    Joined:
    Jan 10, 2018
    Messages:
    16
    Location:
    Indonesia
    Balance:
    193Coins
    Ratings:
    +16 / 0 / -0
    My Motion Simulator:
    DC motor
    Hello man, i want to try your software but i cant, any idea why the software always error when i connecting the board? Even i have 2 board to try..

    Attached Files:

  12. TOPMO3

    TOPMO3 Active Member

    Joined:
    May 12, 2015
    Messages:
    133
    Location:
    Russia
    Balance:
    894Coins
    Ratings:
    +201 / 0 / -0
    Hi @BS21

    In a case of such errors the most possible cause is bad config. At first, please be sure you are using fw and app of the same version - I.e. 0.14
    Can you please make these steps:
    - make full chip erase
    - reflash fw
    At this point your board should be identified as joystick (with default config) in windows.
    - launch OSH Studio. Once again ensure you are using the same versions of the app and few
    - click get config from device. Default config should be loaded and be shown in the app
    - make new config you needed and click save config to device.

    Try to make these steps and let me know if you have any error
  13. BS21

    BS21 Sim Tutorial: www.youtube.com/BSGamingSimulator

    Joined:
    Jan 10, 2018
    Messages:
    16
    Location:
    Indonesia
    Balance:
    193Coins
    Ratings:
    +16 / 0 / -0
    My Motion Simulator:
    DC motor
    Yesterday i got problem when reflashing it brother. Board getting lost connection and dont want to reconnect when i start pushing reset button and clicking "ok" in st link software. But i'll try again tonight. Will let u know for the next..
  14. TOPMO3

    TOPMO3 Active Member

    Joined:
    May 12, 2015
    Messages:
    133
    Location:
    Russia
    Balance:
    894Coins
    Ratings:
    +201 / 0 / -0
    insteed of making connect under reset you can just switch both jumpers - then stlink utility should connect to board without any issues. After reflashing dont forget to switch jumpers back
  15. xavi_trd

    xavi_trd New Member

    Joined:
    Jan 10, 2018
    Messages:
    3
    Location:
    Barcelona
    Balance:
    178Coins
    Ratings:
    +2 / 0 / -0
    Hi all!!

    First of all thanks for that amazing work TOPMO3.

    I'm getting the same problem when I connect the usb in the computer with the OSHStudio running, or when I run the programm with the usb connected. I reflashed too many times and tried versions 0.14 and 0.13 and the result is the same.
    I'm using windows 7 64bits and it get me this error description (sorry because it's in spanish with my own translation):
    Nombre del evento de problema("Problem event name"): APPCRASH
    Nombre de la aplicación("App name"): OSHStudio.exe
    Versión de la aplicación("App version"): 0.0.0.0
    Marca de tiempo de la aplicación("App time mark"): 5a0dbec6
    Nombre del módulo con errores(" Error module name"): OSHStudio.exe
    Versión del módulo con errores("Error module version"): 0.0.0.0
    Marca de tiempo del módulo con errores ("Error module time mark"): 5a0dbec6
    Código de excepción ("Exception code"): c0000005
    Desplazamiento de excepción ("Exception slide"): 000019f6
    Versión del sistema operativo("S.O version"): 6.1.7601.2.1.0.256.48
    Id. de configuración regional ("Regional ID config"): 3082
    Información adicional 1 ("additional info"): 0a9e
    Información adicional 2: 0a9e372d3b4ad19135b953a78882e789
    Información adicional 3: 0a9e
    Información adicional 4: 0a9e372d3b4ad19135b953a78882e789
  16. TOPMO3

    TOPMO3 Active Member

    Joined:
    May 12, 2015
    Messages:
    133
    Location:
    Russia
    Balance:
    894Coins
    Ratings:
    +201 / 0 / -0
    Hi @xavi_trd

    You mean the app crashs even if you don't click any buttons? Hmm
    It seems like some local PC issue, hard to diagnose such errors
    Do you use USB-hub? If yes please try to connect right into MB USB port
    if you use USB3.0 port try to use USB2.0
    Try just to change USB port, for example from front to rear
    Do you have an option to try a different PC? as last resort
  17. xavi_trd

    xavi_trd New Member

    Joined:
    Jan 10, 2018
    Messages:
    3
    Location:
    Barcelona
    Balance:
    178Coins
    Ratings:
    +2 / 0 / -0
    Thanks for the response @TOPMO3.

    1. Yes, as soon as I connect the usb the app crashs. Sometimes I can see that the board is linked with the app, but can't do anything before it crash.
    2. I'm not using a USB-Hub.
    3. I Used front/rear and 2.0/3.0 USB
    4. I tried to use it in my computer and in my laptop
    And the result is always the same....

    Someone have tested the app with a BlackPill board????

    If I can, tomorrow I will test it in my workplace computer to discard that it's Norton trying to kill me :confused:, because it's warning me about a infected file the first time I execute the app.

    Thanks!
  18. xavi_trd

    xavi_trd New Member

    Joined:
    Jan 10, 2018
    Messages:
    3
    Location:
    Barcelona
    Balance:
    178Coins
    Ratings:
    +2 / 0 / -0
    Hi,

    Today I have tried in my workplace computer with W7 and it didn't work, but I tried in my GF laptop with W10 and it's WORKING!!! :cheers
    I don't know if it's the O.S or Antivirus who was crashing the app, but now I can start my little project. :D

    Again, thanks TOPMO3 for this great work.
    • Like Like x 1
    • Informative Informative x 1
  19. BS21

    BS21 Sim Tutorial: www.youtube.com/BSGamingSimulator

    Joined:
    Jan 10, 2018
    Messages:
    16
    Location:
    Indonesia
    Balance:
    193Coins
    Ratings:
    +16 / 0 / -0
    My Motion Simulator:
    DC motor
  20. BS21

    BS21 Sim Tutorial: www.youtube.com/BSGamingSimulator

    Joined:
    Jan 10, 2018
    Messages:
    16
    Location:
    Indonesia
    Balance:
    193Coins
    Ratings:
    +16 / 0 / -0
    My Motion Simulator:
    DC motor
    osh error.PNG osh error2.PNG


    Hello..
    What u mean to switch the jumper is SWDIO and SWCLK? I've done to switch them but still no connection after reset. Or please can you post step by step how to reflashing or downgrade the firmware? Currently used 0.14 FW and OSH. Thank you