Dim MacBook Pro screen following replacement

I have had a dead MacBook Pro (13-inch, 2016, Four Thunderbolt 3 Ports) sitting on my shelf for three years. I replaced it with a MacBook Pro (13-inch, 2019, Four Thunderbolt 3 Ports) which worked well but I sold it to a friend when I bought my current M1 MacBook Air. Unfortunately, the 2019 machine quickly developed a screen fault, which looked suspiciously like the fault that Apple recalled the 2016 model for. It means the screen just shows flickering purple squares and is apparently caused by the ribbon cable to the screen going faulty. My friend took it to a genius bar and was told it would cost over £500 to replace the screen. I was obviously embarrassed about this, so my friend and I hatched a plan to transfer the screen from my dead 2016 model to the 2019 one (the specs appeared to identical). We followed the instructions on iFixIt and were delighted when the computer appeared to work OK (after one initial kernel panic). However, our joy was short-lived when we realised that the screen was not very bright but worked perfectly in all other ways. After resetting the NVRAM, during the first part of start-up, the Apple logo was at full brightness but when the progress bar got to about 50%, the screen went dim again and stayed that way. We tried doing an SMC reset but that didn’t work and no amount of fiddling with settings helped.

Then the mystery deepened. He had Windows 10 installed via Boot Camp and when we restarted in that, the screen worked perfectly at full brightness. After much head scratching, the only thing I can think of is that the 2019 model supported TrueTone but the 2016 one didn’t. This would explain why Boot Camp works OK.

So my feeling is this could be sorted in software (possibly using Terminal?). We tried reinstalling Big Sur but that didn’t help. Does anybody have any ideas, please?

You probably have considered it, but is the screen brightness set properly in macOS?

Try pressing the “F2” key (without any other keys down) repeatedly to increase brightness. “F1” decreases it.

It is a Touch Bar Mac, so doesn’t have F1 and F2 keys. It is on max screen brightness. It is like the auto dimming feature isn’t working properly but the checkbox to turn it off in System Preferences/Display is missing.

Sort of a digression, perhaps, because for the most part–over my head
In terms of software: what software drives the display
I imagine it is firmware, … would a 2019 device’s firmware know how to communicate
to/with a 2016 display … even if the displays were essentially “the same”

I think you are quite possibly correct but how come it works OK in Boot Camp and, apart from being dim, it works perfectly in MacOS?