Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Atmosphere crash when DS4 Controller battery reach 100% while charging in the switch dock. #18

Closed
LinkAran opened this issue Aug 28, 2020 · 8 comments
Labels
bug Something isn't working

Comments

@LinkAran
Copy link

LinkAran commented Aug 28, 2020

When the DS4 battery reach 100% while plugged in the nintendo switch dock with micro-usb cable, atmosphere crashes and it retrurns an Error Code: 2011-0301 (0x25a0b).
Firmware: 10.1.0 (Atmosphère 0.14.1-master-ee5a095c).
Controller: Dualshock 4 - CUH-ZCT2U

@NSWRyan
Copy link

NSWRyan commented Aug 28, 2020

The DS4 battery data max is 11 while the joycon (dunno about pro controller) is 4. Maybe this causes the issue?
If that is true, then this code does not fix it.
m_battery = src->input0x11.battery_level & 0xe;
dualshock4_controller.cpp

@gazba
Copy link

gazba commented Aug 28, 2020

I'd like to add: I tried to pair it with a fully charged DS4 controller, and it instantly crashes atmosphere. It wasn't docked, or charging at the moment. Thank you for looking into it, and sorry if i posted in the wrong place, but seemed unnecessary to open a new issue ticket.

@ndeadly ndeadly added the bug Something isn't working label Aug 28, 2020
@BobRoss05
Copy link

BobRoss05 commented Aug 28, 2020

I have the same issue where it crashes atmosphere while pairing a DS4 controller and I actually had the controller working with the system when it had a lower battery percentage.
More specifically i got the DS4 controller to start working when it had around 80% battery, any more and it crashes atmosphere. And at 80% battery the DS4 is seen as full battery by the switch.

@ndeadly
Copy link
Owner

ndeadly commented Sep 1, 2020

I made some changes to the DS4 battery handling code that should (hopefully) fix the invalid values causing the crashes. Try this build out and report back if it fixes the issues you guys are having

MissionControl-0.1.0-ds4-battery-fix.zip

@BobRoss05
Copy link

I just tested by plugging in the DS4 controller which crashed the system on the release build but this custom build allowed it to pair and work while plugged in to power. I'll let the controller charge to full then unplug it and try pairing it with a full battery but this seems to work so far but i'll let you know what the battery does later which I don't think should change because it seems that the DS4 registers itself as 100% charged on its end while plugged in even if it isn't.

@ndeadly
Copy link
Owner

ndeadly commented Sep 1, 2020

@BobRoss05 sounds promising. Looking forward to hearing your findings.

@BobRoss05
Copy link

I just finished charging up my controller and with a full battery it works just fine when paired. I actually wen to the old version first to test to see if it crashed, which it did, then I put it back on this build and it works perfectly. Thanks for the quick fix!

@ndeadly
Copy link
Owner

ndeadly commented Sep 12, 2020

This is now fixed in the latest release.

@ndeadly ndeadly closed this as completed Sep 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants