Hi PJ,
Thanks for trying.
I have tried with your sketch. I am able to measure the battery voltage without any problem. I don’t know why it differs from your numbers. But the variants files seems to be working fine.
Thanks.
08:32:10.736 -> Power ON
08:32:10.736 ->
08:32:10.736 -> Test program compiled on Feb 15 2023 at 08:26:12
08:32:10.736 ->
08:32:10.736 -> Processor came out of reset.
08:32:14.207 -> PIN_VBAT=4041 P0_31=4041
08:32:17.794 -> PIN_VBAT=4012 P0_31=4021
08:32:21.364 -> PIN_VBAT=4012 P0_31=4041
08:32:24.971 -> PIN_VBAT=4021 P0_31=4021
08:32:28.547 -> PIN_VBAT=4021 P0_31=4041
08:32:32.129 -> PIN_VBAT=4041 P0_31=4050