This is clearly a loose connection rather than a software issue, I would say maybe an issue with the USB-C port or the cables on the MacBook. have you tried both..?
Also just create a separate test profile on the MacBook to take away any chance of it being software..
|