File tree Expand file tree Collapse file tree 1 file changed +8
-7
lines changed
features/netsocket/cellular/generic_modem_driver Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -558,18 +558,12 @@ nsapi_error_t PPPCellularInterface::connect()
558
558
nsapi_error_t retcode;
559
559
bool success;
560
560
bool did_init = false ;
561
+ const char *apn_config = NULL ;
561
562
562
563
if (dev_info.ppp_connection_up ) {
563
564
return NSAPI_ERROR_IS_CONNECTED;
564
565
}
565
566
566
- const char *apn_config = NULL ;
567
- #if MBED_CONF_PPP_CELL_IFACE_APN_LOOKUP
568
- if (!set_credentials_api_used) {
569
- apn_config = apnconfig (dev_info.imsi );
570
- }
571
- #endif
572
-
573
567
do {
574
568
retry_init:
575
569
@@ -604,6 +598,12 @@ nsapi_error_t PPPCellularInterface::connect()
604
598
return NSAPI_ERROR_NO_CONNECTION;
605
599
}
606
600
601
+ #if MBED_CONF_PPP_CELL_IFACE_APN_LOOKUP
602
+ if (!apn_config) {
603
+ apn_config = apnconfig (dev_info.imsi );
604
+ }
605
+ #endif
606
+
607
607
/* Check if user want skip SIM pin checking on boot up */
608
608
if (set_sim_pin_check_request) {
609
609
retcode = do_sim_pin_check (_at, _pin);
@@ -629,6 +629,7 @@ nsapi_error_t PPPCellularInterface::connect()
629
629
_apn = _APN_GET (apn_config);
630
630
_uname = _APN_GET (apn_config);
631
631
_pwd = _APN_GET (apn_config);
632
+ tr_info (" Looked up APN %s." , _apn);
632
633
}
633
634
#endif
634
635
You can’t perform that action at this time.
0 commit comments