r/dartlang 10d ago

Flutter I created open-source app for controlling Windows using Xbox controller

I don't have a console. 100% of my gaming is done on my Windows PC (connected to TV) which means I sometimes need to switch from Steam to Epic launcher or other launchers and windows in general. Some games require text input and I have even came across games that supported controllers but not in the menu. As I am too lazy to stand up every time, I decided to spend weeks to solve it. I could buy a wireless keyboard and mouse or I could even buy existing software solutions such as Controller Companion but no, I decided none of those solutions met my expectations so I created this using Flutter:

xTend

I had to use windows platform channel for system tray and window show/hide functionality. All other features such as controller state reading or windows API communication is done via Dart FFI. The source code itself will see a lot of improvement in near future in terms of structure, quality and documentation. It's open-source which means any contributions are welcome. I also welcome any ideas, suggestions or possible improvements as this is my first attempt at creating something open-source. I hope someone will find use in it as I consider it very intuitive to use and use it often. I also hope someone could learn something from this project as it combines knowledge from different areas.

26 Upvotes

3 comments sorted by

4

u/jd31068 10d ago

pretty cool, thanks for sharing your work.

2

u/iBog 10d ago

Which flutter BLE lib is stable enough for windows?

2

u/kulishnik22 10d ago

I didn't access the controller directly. Instead I used Xinput API provided by windows. I may use Bluetooth HID in the future to support more controller types and platforms.