sorry if I was unclear. You can not use GPIO 16 and GPIO 17 with M5Stack Fire. Those two GPIOs are internally used for the PSRAM. Please see here.
You need to use a different pair, for instance GPIO 5 and GPIO 13, adapt the sketch and change the dip switches on the COM.GSM module accordingly.