pycom / pycom-micropython-sigfox

A fork of MicroPython with the ESP32 port customized to run on Pycom's IoT multi-network modules.
MIT License
199 stars 167 forks source link

LTE modem becomes unresponsive - even after machine.reset() #225

Open stanleypa opened 5 years ago

stanleypa commented 5 years ago

I'm using the latest sequans modem firmware: - NB1-38729.dup

The issue happens sporadically maybe 1 in 50 or 1 in 100 times when trying to get a network connection.

It seems to happen when sending and AT command - 'AT+COPS=1,2,"27201". This will often respond with "ERROR" and my code will try again. It will sometimes take quite a while to respond at all (the send_at_cmd method will timeout and return an empty string). In this case also I retry. Most of the time it eventually responds - the send_at_cmd returns the output from multiple AT+COPS commands and the connection is made. However sometimes this doesn't happen even after 5 minutes. At this point a watchdog kicks in to try to recover via a machine.reset() but the code then hangs on reboot at LTE object creation (lte=LTE())

Only a hard power reset will recover the system - not an option for normal deployed battery backed up systems! A machine.reset() should completely reset the modem also.

dmartauz commented 5 years ago

I am experiencing the same issue with FiPy running Pycom FW 1.18.1.r2 and Sequans FW NB1-38729.

dmartauz commented 5 years ago

@stanleypa Did you find any workaround for this issue in the meantime? Just to be sure - is your G01 powered properly? I am thinking of possibility that Monarch chip cannot perform brownout reset correctly. However in our case the FiPy is powered from 2A power adapter and these hangs happen from time to time. I am thinking to connect oscilloscope to 3.3V pin of FiPy and find out what are minimal voltage levels during LTE transmissions.