Asynchronous GSM connection on Arduino GSM MKR 1400

when I work with GSM kind of stuffs for serious projects, I'd build my own functions that issue AT command directly than depend on them libraries

especially those functions that run in the loop()

when you peep at the functions into MKRGSM lib, you will find bunch of while()s looping around, waiting for some GMS/GPRS status/flag to be set true before breaking out of it, thus causing blocking issues

I can see lots of irritating delay()s and for()s in your custom code