Merge branch 'dev_ck_v2.1_feature#1215#' into 'dev_ck_v2.1'

update New Feature#1215

See merge request ucp/driver/ucp4008_platform_arm!52
This commit is contained in:
Xianfeng Du 2024-02-20 09:30:44 +00:00
commit 422d61d424
2 changed files with 25 additions and 19 deletions

View File

@ -42,6 +42,8 @@ typedef struct ucp_rfic_cfg_info
uint16_t enUcpLog;
uint16_t u16padding;
uint32_t u32padding2;
ucp_rfic_calPara_t st_rfic_calPara;
}ucp_rfic_cfg_info_t;
#if 1
@ -91,6 +93,19 @@ ucp_rfic_cfg_info_t rfic_get_cfg_info()
config = xzJSON_GetObjectItem(item, "enUcpLog");
st_rfic_cfg.enUcpLog = config->valueint;
config = xzJSON_GetObjectItem(item, "calOrxGainIndex");
st_rfic_cfg.st_rfic_calPara.calOrxGainIndex = config->valueint;
item = xzJSON_GetObjectItem(item, "calChAttPara");
config = xzJSON_GetObjectItem(item, "ch1");
st_rfic_cfg.st_rfic_calPara.calChAttPara[0] = config->valueint;
config = xzJSON_GetObjectItem(item, "ch2");
st_rfic_cfg.st_rfic_calPara.calChAttPara[1] = config->valueint;
config = xzJSON_GetObjectItem(item, "ch3");
st_rfic_cfg.st_rfic_calPara.calChAttPara[2] = config->valueint;
config = xzJSON_GetObjectItem(item, "ch4");
st_rfic_cfg.st_rfic_calPara.calChAttPara[3] = config->valueint;
xzJSON_Delete(root);
return st_rfic_cfg;
@ -170,6 +185,14 @@ int32_t main(int32_t argc, char* argvp[])
st_rfic_cfg_info.enOrx,
st_rfic_cfg_info.en204C,
st_rfic_cfg_info.enUcpLog);
printf("GainIndex:%d, calChAttPara.ch1:%d, ch2:%d, ch3:%d, ch4:%d\r\n",
st_rfic_cfg_info.st_rfic_calPara.calOrxGainIndex,
st_rfic_cfg_info.st_rfic_calPara.calChAttPara[0],
st_rfic_cfg_info.st_rfic_calPara.calChAttPara[1],
st_rfic_cfg_info.st_rfic_calPara.calChAttPara[2],
st_rfic_cfg_info.st_rfic_calPara.calChAttPara[3]);
#endif
/* call jesd init function */
UCP_API_RFIC_CellInit(st_rfic_cfg_info.sampleRate,
@ -185,7 +208,8 @@ int32_t main(int32_t argc, char* argvp[])
st_rfic_cfg_info.initAtt,
st_rfic_cfg_info.initGain,
st_rfic_cfg_info.auxLo,
st_rfic_cfg_info.enOrx);
st_rfic_cfg_info.enOrx,
st_rfic_cfg_info.st_rfic_calPara);
//UCP_API_RFIC_CellSetup(2575770000u, 2575770000u, 0);
/* post sem */

View File

@ -1,18 +0,0 @@
{
"common": {
"txLo": 2566890000,
"rxLo": 2566890000,
"auxLo": 0,
"initAtt": 0,
"initGain": 255
},
"para": {
"sampleRate": 122880000,
"bw": 100000000,
"antNumb": 4,
"enFdd": 0,
"enOrx": 0,
"en204C": 0,
"enUcpLog": 0
}
}