Change light level to percentage.
Change analog input level to percentage.
Add 'power voltage' block.
Build module as a loadable extension for Xcratch (https://github.com/yokobond/xcratch)
Download the corresponding firmware in your micro:bit.
MakeCode Project: pxt-scratch-microbit-more-v050 https://makecode.microbit.org/_iXhFjt5b3gdJ