I have an Arduino MKR NB 1500, which randomly enters bootloader mode (similar to pressing the reset button twice) for no apparent reason. I have more or less the same code running on 5 different boards, but this is only happening on 1 of them.
It seems that this issue has been brought up before here Board enters bootloader mode randomly, unfortunately with no solution.