Agreed with
@lx200inAR that water ingress is the likely cause of your CDL issue.
The breather hose for the transfer case (not the diff breathers) has been known to wear/crack and come off. Being at the top, water and moisture ingress becomes a problem.
Corrosion on this particular switch is likely the source of your issue. If you catch this early enough and go in there to clean the corrosion, as well as address the breather hose, you can likely resolve the light issue, but also save the functionality of the center diff lock as over time, the wiper switches and motor all becomes compromised.
The reason why battery voltage can contribute is exactly as
@radman says, that corrosion adds added resistance to the contacts and lower voltage may not be able to properly signal across contacts.
View attachment 3090240
More detailed info here
Transfer case actuator issues are not uncommon on the 200-series. Not much documented solutions other than exercising the mechanisms regularly. Here's my attempt to provide more information on where and what the actuator is, how to service the transfer case actuator motor, and potentially...
forum.ih8mud.com