Sometimes it happens when I shake it, even lightly. And sometimes it happens when I flip the display screen at a certain angle and then it happens, just because.
@ttt6457 has anything else happened to it? my 2ds xl used to freeze a bit after i got it waterdamaged but a month latr it stopped freezing. maybe its a temporary problem for you??
Make sure that your system is on the latest firmware (11.16.0-48). If it is on 11.16, hold the power button for 10 seconds to force the system to shut off.