Smart Stick Py is an application that allows you to decode DualShock4 input at a low level, freely modify the input, and output it as XINPUT. This application provides granular control over the input modification process, enabling you to customize the behavior of your DualShock4 controller.
- Windows OS
- Python 3.11
- ViGEm (Virtual Gamepad Emulation Framework)
- HidHide (Hides input devices from applications)
-
Install ViGEm:
- Download the latest version of ViGEm from the official website.
- Run the installer and follow the installation instructions.
-
(Optional) Install HidHide:
- Download the latest version of HidHide from the official GitHub repository.
- Run the installer and follow the installation instructions.
-
Clone the repository:
git clone https://github.com/your-username/smart-stick-py.git
-
Create a virtual environment:
python -m venv .venv
-
Activate the virtual environment:
.venv\Scripts\activate
-
Install the required dependencies:
pip install -r requirements.txt
-
Run the application:
python src/main.py
To modify the input behavior, you can edit the src/handler.py
file. This file contains the logic for handling and modifying the input from the DualShock4 controller before it is output as XINPUT.
If you want to adjust the response curve of the joystick, you can modify the normalize_joystick
function in the src/response_curve.py
file. This function determines how the joystick input is mapped to the output values.
To visualize the response curve, run the following command:
python src/response_curve.py
This will display a graphical representation of the current response curve, allowing you to see how the input values are mapped to the output.
Contributions to Smart Stick Py are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request on the GitHub repository.
This project is licensed under the MIT License.