sc-controller
sc-controller copied to clipboard
sc-controller not passing gyro info to yuzu emulator
All mappings work correctly, the menu is fantastic (no longer need to bring up steam for these things!), however no gyro is being passed from the steam controller to yuzu. The hardware works since I can use it for mouse control, and yuzu does detect the UDP server and receives data correctly. however when attaching a device to motion, it requires a shake and that data isn't getting passed, I guess?
the button labeled as "shake!" sits at "[not set]", clicking it brings up the shake text that lasts a few seconds, and after that it goes back, regardless of motion on the controller.
I know that https://github.com/FrogTheFrog/steam-gyro-for-cemuhook exists, but it is no longer under development as the owner no longer has a steam controller. see here.
frogthefrog did add a PR into yuzu for fixing the fact the shake values are higher than shat steam controller outputs, but with his cemuhook app, it never sent any input to the emu, rendering the controller useless until the daemon was stopped, and so I'm unsure if that will be helpful or not, since I don't know much about the topics.
Set the log filters to *:Debug and perform a few motion mapping tries. Upload the log file afterwards. I would like to see if data is sended
How do I set log filters? do I have to run it from terminal? where is the log file? there is no reference to this in the readme or wiki that I've found. I've enabled Input Test Mode in settings, but it doesn't show gyro when the controller is moved, although it does display every other input. for reference I've installed it from AUR, 0.4.8.5-1
Are you on discord? I'm able to explain better there
I'm having the same issue using an old DS4 controller
Edit: v1993/evdevhook works, maybe taking a look at how they do things could help
Looking at the Yuzu logs here, it seems like sc-controller is providing some very wrong readings:
[ 103.945265] Input <Debug> input_common/udp/client.cpp:UpdateYuzuSettings:337: UDP Controller 0: gyro=(0.39711976, 0.07159893, -0.23690248), accel=(0, -0, 0)
[ 103.957269] Input <Debug> input_common/udp/client.cpp:UpdateYuzuSettings:337: UDP Controller 0: gyro=(0.39711976, 0.07159893, -0.23690248), accel=(0, -0, 0)
[ 103.965261] Input <Debug> input_common/udp/client.cpp:UpdateYuzuSettings:337: UDP Controller 0: gyro=(0.23181622, 0.18584423, -0.28130946), accel=(0, -0, 0)
[ 103.973261] Input <Debug> input_common/udp/client.cpp:UpdateYuzuSettings:337: UDP Controller 0: gyro=(0.23181622, 0.18584423, -0.28130946), accel=(0, -0, 0)
[ 103.981305] Input <Debug> input_common/udp/client.cpp:UpdateYuzuSettings:337: UDP Controller 0: gyro=(0.23181622, 0.18584423, -0.28130946), accel=(0, -0, 0)
[ 103.993307] Input <Debug> input_common/udp/client.cpp:UpdateYuzuSettings:337: UDP Controller 0: gyro=(0.12754783, 0.15865228, 0.044406988), accel=(0, -0, 0)
[ 104.001281] Input <Debug> input_common/udp/client.cpp:UpdateYuzuSettings:337: UDP Controller 0: gyro=(0.12754783, 0.15865228, 0.044406988), accel=(0, -0, 0)
According to the spec, gyro should be in degrees per second, which this absolutely does not look like (the readings are from me shaking the controller violently).
Actually, looks like these values are somehow scaled by Yuzu already before being logged: https://github.com/yuzu-emu/yuzu/blob/5edc96f4a47bff64cfd97f0c91e42b56ab58b2d7/src/input_common/udp/client.cpp#L285
I think this is related to sc-controller not handling accelerometer data. Yuzu might be requiring acceleration info for selecting the active gyro provider. See attached screenshots
sc-controller:

steam-gyro-for-cemuhook (working):

Yuzu can work with just one sensor. The giro might not trigger the minimum threshold of 5.0 in any direction. If this is true let me know to lower the trigger value.
I've noticed that I am not using this codebase, but instead a fork. https://aur.archlinux.org/packages/sc-controller/
https://github.com/Ryochan7/sc-controller/
@german77 how would you have me check those values? I'd like to get this working for me and everyone else, and am willing to be guinea pig for code and testing builds for both scc and yuzu forks.
Modify the source and find the correct value. Right now it's at 5. Try with 3 or 2. From the logs posted above the data is fine is just a mapping issue
https://github.com/yuzu-emu/yuzu/blob/5edc96f4a47bff64cfd97f0c91e42b56ab58b2d7/src/input_common/udp/client.cpp#L346
Got a test branch up with some changes for CemuHook. SC Controller was not grabbing the accel data from the input report. Just to note, the BT driver was not changed so a Bluetooth connection with the Steam Controller still does not pull the accel data. Make sure to use a USB or SC Dongle connection.
https://github.com/Ryochan7/sc-controller/tree/cemuhook_test_changes