Cores crash on startup, and port shifting with PS4 controller

I have my PS4 controller wired into my Pixel 2 and I’ve been experiencing two weird issues. If I start Retroarch up with a ps4 controller everything works fine in menus, but if I select a core, once it initially launches and the overlay appears, the core freezes. If I unplug the controller the core will instantly start to function normally. However, when I plug my controller back into my phone, it sets it in port 1, rather than port 0 (then port 3, and so on, if I try reconnecting my controller again, or moving away and back to Retroarch.

Right now I’ve been connecting my controller after launching the core and it works fine, but Id like to be able to swap between games or answer a text without needing to relaunch the whole app to reconnect my controller.

Has anyone else had these issues, and/or know a fix? Thanks!