sadly UICR area is not writable when softdevice is enabled, so it is not easily possible without flashing custom build of espruino, it needs -DCONFIG_NFCT_PINS_AS_GPIOS in board file - then it is done automatically as part of application startup.
Or you need espruino with patch that can run your javascript to write to UICR as part of NRF.restart() but that is custom build too. Or it can be done via SWD - openocd or other debugger.
Easiest perhaps is to rebuild espruino for MDBT42Q from source with that one line in board file.
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
sadly UICR area is not writable when softdevice is enabled, so it is not easily possible without flashing custom build of espruino, it needs -DCONFIG_NFCT_PINS_AS_GPIOS in board file - then it is done automatically as part of application startup.
Or you need espruino with patch that can run your javascript to write to UICR as part of NRF.restart() but that is custom build too. Or it can be done via SWD - openocd or other debugger.
Easiest perhaps is to rebuild espruino for MDBT42Q from source with that one line in board file.