Every now and then my monitor goes black for a few seconds. When it comes back, the cursor is near the top left corner (I would guess around 10px from the top and left. I moved my screensaver hotspot to the top right, so I know it's not related to that). It happened yesterday while I was on a video call, and when it came back I got a "new hardware detected" message in the video call program. This leads me to believe the monitor is being briefly disconnected, and when it reconnects the monitor speakers are re-found.
While the monitor is blacked out, I can continue typing and when it comes back what I typed is there, so the MBP is still running and responsive when it happens. The MBP is a 2019 intel on the latest Monterey and it's running in clamshell mode. This started happening sometime after I upgraded to Monterey.
I also noticed that if I don't move the cursor from the top left, the amount of time that the monitor is blacked out is much lower (like <1 second instead of 3 or 4 seconds). That has only happened once so far, so I can't tell if that's consistent behavior. If it is, I guess it would point to a software issue.
It seems to happen more frequently right after rebooting. Sometimes it happens every few minutes, sometimes it goes for hours or days before it happens. I didn't do a reboot for a few weeks at one point and it stopped happening completely after a while (I thought I'd solved it by adding a fan to cool down the hub that the monitor was connected to at the time). Then I rebooted and within a few minutes it started happening every few minutes again.
In my original setup, the monitor is connected with displayport via a hub to the MBP. I then got a new USB-C to HDMI cable and switched to using that directly from MBP to monitor. It still happens, so I know the issue isn't with the hub or the displayport port on the monitor, and I can be pretty confident it's not the cable either (I could be unlucky and have two faulty cables though I guess...)
Aside from replacing my monitor/MBP, what else can I do to try and track down the issue?