Your micro:bit may encounter a situation that prevents it from running your code. When this happens, a frowny face will appear on your micro:bit screen (see picture) followed by an error number.
Below is a list of error numbers and what they mean:
- 10 (MICROBIT_I2C_LOCKUP): the micro:bit's I2C bus is not working
- 20 (MICROBIT_OOM): there is no free memory on the micro:bit
- 42: your micro:bit can't execute your script properly. Flash a different .hex file to it, then try flashing and running your previous script again.