I have been seeing some issues lately with my application tripping the WatchDog while trying to bring up GPRS (I am sure it has happened before, just never noticed it). It is happening prior to accessing the WIP library and opening the bearer service.
I bring up GPRS as follows:
-subscribe to WIND: 4
-In my WIND: 4 Handler:
—setup my GPRS settings adl_gprsSetup() - (Not sure this is needed)
—subscribe to the gprs service events
—execute the command “AT+CGATT=1”
-In my gprs handler, I get the following events and unsolicited responses in order:
—ADL_GPRS_EVENT_SETUP_OK
—+CGREG: 2
—ADL_GPRS_EVENT_ME_UNREG_SEARCHING
—+CGREG: 2
—+CGATT=1 (Sent to terminal by application)
—+CGREG: 0 (I found this odd)
—ADL_GPRS_EVENT_ME_UNREG (based on the last +CGREG unsolicited response this makes sense)
—+CGREG: 0
—+CGREG: 1,“blah”, “blah”
—ADL_GPRS_EVENT_ME_ATTACH
I then proceed to open the bearer which almost always fails at first with the error:
WIP_BERR_OK_INPROGRESS
which is fine except that it hangs here for a while, proceeded by:
ADL_GPRS_EVENT_SETUP_OK
ADL_GPRS_EVENT_ACTIVATE_OK
That is the typical start-up process for the application. I use UDP to communicate to and from my server app. Occasionally the WatchDog will trip before I receive the ADL_GPRS_EVENT_ME_ATTACH event and open the bearer service. Any ideas why this happens or a better pseudo-code to bring up GPRS and open the WIP bearer service would be appreciated.
Thanks,
Scott