Merge branch 'Branch_S530' of gitlab.sifar.tech:linux-em-group/s530-ntk into Branch_S530
This commit is contained in:
		
						commit
						ad1ff2a26c
					
				| 
						 | 
				
			
			@ -1 +1 @@
 | 
			
		|||
Subproject commit 16e808c3a97ba4c47dd683f1daa79b4459b20202
 | 
			
		||||
Subproject commit 670d2f3fc39f4803f5a72bf125c0aea7a146a100
 | 
			
		||||
							
								
								
									
										1
									
								
								code/application/source/sf_app/code/include/sf_eg91_gps.h
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							
							
						
						
									
										1
									
								
								code/application/source/sf_app/code/include/sf_eg91_gps.h
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							| 
						 | 
				
			
			@ -62,7 +62,6 @@ SINT32 eg91_gps_search(SF_FN_PARAM_S *pfnParam,SF_PARA_TIME_S *pNowTime,UINT8 au
 | 
			
		|||
 | 
			
		||||
SINT32 eg91_gps_Isupdate(SF_FN_PARAM_S *pfnParam,UINT8 *pIsupdate,SF_PARA_TIME_S *pNowTime,UINT8 u8day);
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#ifdef __cplusplus
 | 
			
		||||
#if __cplusplus
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
							
								
								
									
										2
									
								
								code/application/source/sf_app/code/source/4gMng/sf_4G_auto_operation.c
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							
							
						
						
									
										2
									
								
								code/application/source/sf_app/code/source/4gMng/sf_4G_auto_operation.c
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							| 
						 | 
				
			
			@ -66,7 +66,7 @@ UINT32 sf_auto_operation_adjust(void)
 | 
			
		|||
	}
 | 
			
		||||
	else if((SF_STRNCMP(puiPara->OperatorCode, "46003", 5) == 0) || (SF_STRNCMP(puiPara->OperatorCode, "46005", 5) == 0) || (SF_STRNCMP(puiPara->OperatorCode, "46011", 5) == 0))//china Telecom
 | 
			
		||||
	{
 | 
			
		||||
		SF_STRCPY(puiPara->Sim4gApn, "CTNET");
 | 
			
		||||
		SF_STRCPY(puiPara->Sim4gApn, "vzwinternet");
 | 
			
		||||
		SF_STRCPY(puiPara->Sim4gUsr, "\0");
 | 
			
		||||
		SF_STRCPY(puiPara->Sim4gPwd, "\0");
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
							
								
								
									
										3
									
								
								code/application/source/sf_app/code/source/4gMng/sf_eg91_gps.c
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							
							
						
						
									
										3
									
								
								code/application/source/sf_app/code/source/4gMng/sf_eg91_gps.c
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							| 
						 | 
				
			
			@ -14,6 +14,7 @@
 | 
			
		|||
#include "sf_hal_ttyusb.h"
 | 
			
		||||
#include "sf_eg91_server.h"
 | 
			
		||||
#include "sf_eg91_gps.h"
 | 
			
		||||
#include "sf_eg91_sim.h"
 | 
			
		||||
#include "sf_param_common.h"
 | 
			
		||||
#include "sf_module.h"
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			@ -63,6 +64,7 @@ static void gps_infor_convert(SF_CHAR *str)
 | 
			
		|||
    memcpy(str, strTemp, 4);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
SINT32  eg91_gps_greendate_Get(SF_FN_PARAM_S *pfnParam,SF_PARA_TIME_S *pNowTime)
 | 
			
		||||
 {
 | 
			
		||||
	  SINT32 ttyRet = SF_SUCCESS;
 | 
			
		||||
| 
						 | 
				
			
			@ -311,7 +313,6 @@ SINT32  eg91_gps_greendate_Get(SF_FN_PARAM_S *pfnParam,SF_PARA_TIME_S *pNowTime)
 | 
			
		|||
	  }
 | 
			
		||||
	  return ret;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
SINT32 eg91_gps_Isupdate(SF_FN_PARAM_S *pfnParam,UINT8 *pIsupdate,SF_PARA_TIME_S *pNowTime,UINT8 u8day)
 | 
			
		||||
{
 | 
			
		||||
  
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -3417,7 +3417,13 @@ SINT32 sf_net_regist_manual(void)
 | 
			
		|||
						}
 | 
			
		||||
						else
 | 
			
		||||
						{
 | 
			
		||||
                        	sprintf((char *)gsmPara, "AT+RSTSET\r");
 | 
			
		||||
                        	//sprintf((char *)gsmPara, "AT+RSTSET\r");
 | 
			
		||||
                        	//sprintf((char *)gsmPara, "AT+CGREG?\r");
 | 
			
		||||
                            //eNetRegLocation = QUECTEL_NETREG_CGREG;
 | 
			
		||||
							//callTime = SF_QUECTEL_NET_REG_CALLTIME_MAX; /*4 min*/
 | 
			
		||||
							sprintf((char *)gsmPara, "%s", "AT+CGDCONT=1,\"IPV4V6\",\"\"\r");
 | 
			
		||||
							eNetRegLocation = QUECTEL_NETREG_CGDCONT;
 | 
			
		||||
                        	
 | 
			
		||||
						}
 | 
			
		||||
                    }
 | 
			
		||||
                    else
 | 
			
		||||
| 
						 | 
				
			
			@ -3477,6 +3483,9 @@ SINT32 sf_net_regist_manual(void)
 | 
			
		|||
                if(ret == SF_SUCCESS)
 | 
			
		||||
                {
 | 
			
		||||
                    eNetRegLocation = QUECTEL_NETREG_FRIST;
 | 
			
		||||
					//sprintf((char *)gsmPara, "AT+CGREG?\r");
 | 
			
		||||
                    //eNetRegLocation = QUECTEL_NETREG_CGREG;
 | 
			
		||||
					//callTime = SF_QUECTEL_NET_REG_CALLTIME_MAX;
 | 
			
		||||
                }
 | 
			
		||||
                else
 | 
			
		||||
                {
 | 
			
		||||
| 
						 | 
				
			
			@ -3513,7 +3522,7 @@ SINT32 sf_net_regist_manual(void)
 | 
			
		|||
                #if SF_TEST_ERROR_CODE
 | 
			
		||||
                sf_test_code_err(eNetRegLocation, "+CGREG: 0,2");
 | 
			
		||||
                #endif
 | 
			
		||||
 | 
			
		||||
				SF_DEBUG("Sim4gApn=%s", puiPara->Sim4gApn);
 | 
			
		||||
                if((strstr((const char *)gsmPara, "+CGREG: 2,1") != NULL) || (strstr((const char *)gsmPara, "+CGREG: 0,1") != NULL) || (strstr((const char *)gsmPara, "+CGREG: 0,5") != NULL))
 | 
			
		||||
                {
 | 
			
		||||
                    if(PWR_ON_TIME_SYNC == sf_poweron_type_get())
 | 
			
		||||
| 
						 | 
				
			
			@ -4789,6 +4798,7 @@ SINT32 sf_get_ntp(SINT32 value, SF_PARA_TIME_S *current_time)
 | 
			
		|||
	UIMenuStoreInfo *pPara = sf_app_ui_para_get();
 | 
			
		||||
	SF_TTY_DATA_TYPE_S ttyData = { .waitMs = 2000, .len = 3, .lenMax = (GPRS_INFO_LINE_MAX-1), .cmp = "OK", .cmperr = "ERROR", .data = gsmPara};
 | 
			
		||||
 | 
			
		||||
	SF_DEBUG("Sim4gApn=%s", pPara->Sim4gApn);
 | 
			
		||||
    sf_gsm_para_buff_clear();
 | 
			
		||||
 | 
			
		||||
    pdpIndex = sf_get_pdp_index();
 | 
			
		||||
| 
						 | 
				
			
			@ -4996,7 +5006,8 @@ UINT8 sf_get_pdp_index(void)
 | 
			
		|||
    UINT8 pdpIndex = 0;
 | 
			
		||||
 | 
			
		||||
	UIMenuStoreInfo *pPara = sf_app_ui_para_get();
 | 
			
		||||
 | 
			
		||||
	
 | 
			
		||||
	SF_DEBUG("Sim4gApn=%s", pPara->Sim4gApn);
 | 
			
		||||
    if(strstr((const char *)pPara->Sim4gApn, APN_4G_VERIZON))
 | 
			
		||||
    {
 | 
			
		||||
        pdpIndex = V_PDP_INDEX;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
							
								
								
									
										2
									
								
								code/application/source/sf_app/code/source/4gMng/sf_opera_adapt.c
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							
							
						
						
									
										2
									
								
								code/application/source/sf_app/code/source/4gMng/sf_opera_adapt.c
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							| 
						 | 
				
			
			@ -75,7 +75,7 @@ SINT32 sf_auto_operation_adaptation(SF_CHAR *operatorName, UIMenuStoreInfo *sim_
 | 
			
		|||
	}
 | 
			
		||||
	else if((strncmp(operatorName, "46003", 5) == 0) || (strncmp(operatorName, "46005", 5) == 0) || (strncmp(operatorName, "46011", 5) == 0))//china telcom
 | 
			
		||||
	{
 | 
			
		||||
		strcpy(sim_info_t->Sim4gApn, "CTNET"); 
 | 
			
		||||
		strcpy(sim_info_t->Sim4gApn, "vzwinternet"); 
 | 
			
		||||
		strcpy(sim_info_t->Sim4gUsr, "\0");
 | 
			
		||||
		strcpy(sim_info_t->Sim4gPwd, "\0");
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -103,7 +103,7 @@ int main(int argc, char *argv[])
 | 
			
		|||
{
 | 
			
		||||
    printf("*********************************************\n");
 | 
			
		||||
	printf("*                                           *\n");
 | 
			
		||||
	printf("*                 sf_app-v3                 *\n");
 | 
			
		||||
	printf("*                 sf_app-v5-0912            *\n");
 | 
			
		||||
	printf("*                                           *\n");
 | 
			
		||||
	printf("*********************************************\n");
 | 
			
		||||
	//gpio_direction_input(C_GPIO(10));
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue
	
	Block a user