I was having intermittent problems with my 16-inch MacBook Pro and LG UltraFine 5K display. It took me a while to come up with a solution. If you’re experiencing the same thing, I’ll tell you what worked for me.
Sometimes when I powered up the laptop, the external display (I mirror the screens) worked fine. However, sometimes the MacBook Pro and LG display flickered when I powered up my laptop. I had to turn the MacBook Pro off, then power up again.
Strangely, the problem didn’t happen all the time. I unplugging and reconnecting the MacBook Pro and external display. I disconnected all external devices and rebooted. I reset the PRAM and SMC of the MacBook Pro. All to no avail.
I THINK, but can’t be sure, that it started when I upgraded to macOS 10.15.6. What finally helped was downloading the free LG Screen Manager from the Mac App Store, which displays all connected LG monitor info. If you’re having the same problem I had, I suggest you do the same.
Go to Settings.
Select Auto Start. This ensures that the UltraFine 5K starts up automatically. WHY this resolved the situation I don’t know.
If that doesn’t work, you can choose Factory Reset. Hopefully, you won’t have to do that, as simply selecting Auto Start worked for me.