Merge branch 'dev_ck_v2.1_feature_enhancement#1546#' into 'dev_ck_v2.1'

use the enhancement#1546 delete the cell_setup_simulation's sleep into dev_ck_v2.1

See merge request ucp/driver/ucp4008_platform_arm!45
This commit is contained in:
Xianfeng Du 2024-01-02 07:11:56 +00:00
commit 2ed79140d0
9 changed files with 38 additions and 57 deletions

View File

@ -188,7 +188,7 @@ static inline void msg_transfer_queue_polling(void)
#define CELL_SETUP_TYPE_SIMULATION (0x5a6b7c8d) #define CELL_SETUP_TYPE_SIMULATION (0x5a6b7c8d)
void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core) void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core, uint8_t frame_type)
{ {
uint32_t size = 32; uint32_t size = 32;
char* buf; char* buf;
@ -200,9 +200,6 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core)
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
//usleep(10000);
sleep(1);
int32_t ret = msg_transfer_send_start(handler.value,cu_flag); int32_t ret = msg_transfer_send_start(handler.value,cu_flag);
/************C_PLANE***************/ /************C_PLANE***************/
@ -219,6 +216,7 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core)
*(uint32_t*)(buf + 16) = scs_id; *(uint32_t*)(buf + 16) = scs_id;
*(uint32_t*)(buf + 20) = cell_id; *(uint32_t*)(buf + 20) = cell_id;
*(uint32_t*)(buf + 24) = run_core; *(uint32_t*)(buf + 24) = run_core;
*(uint32_t*)(buf + 28) = frame_type;
ret = msg_transfer_send_msg(handler.value, cu_flag, (uint8_t *)buf, offset, size); ret = msg_transfer_send_msg(handler.value, cu_flag, (uint8_t *)buf, offset, size);
ret = msg_transfer_send_end(handler.value,cu_flag); ret = msg_transfer_send_end(handler.value,cu_flag);
@ -249,11 +247,13 @@ int32_t test_case(uint32_t argc, int32_t* argvp)
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
int32_t ret; int32_t ret;
uint8_t scs_id = 0; // NR 15K uint8_t scs_id = 0; // NR 15K
uint8_t cell_id = 0; uint8_t cell_id = 0;
uint32_t run_ape = 0x3; uint32_t run_ape = 0x3;
cell_setup_simulation(scs_id, cell_id, run_ape); uint8_t frame_type = 1; // tdd
cell_setup_simulation(scs_id, cell_id, run_ape, frame_type);
while(1) { while(1) {
msg_transfer_queue_polling(); msg_transfer_queue_polling();

View File

@ -190,7 +190,7 @@ static inline void msg_transfer_queue_polling(void)
#define CELL_SETUP_TYPE_SIMULATION (0x5a6b7c8d) #define CELL_SETUP_TYPE_SIMULATION (0x5a6b7c8d)
void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core) void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core, uint8_t frame_type)
{ {
uint32_t size = 16; uint32_t size = 16;
char* buf; char* buf;
@ -202,9 +202,6 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core)
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
//usleep(10000);
sleep(1);
int32_t ret = msg_transfer_send_start(handler.value,cu_flag); int32_t ret = msg_transfer_send_start(handler.value,cu_flag);
/************C_PLANE***************/ /************C_PLANE***************/
@ -221,6 +218,7 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core)
*(uint32_t*)(buf + 16) = scs_id; *(uint32_t*)(buf + 16) = scs_id;
*(uint32_t*)(buf + 20) = cell_id; *(uint32_t*)(buf + 20) = cell_id;
*(uint32_t*)(buf + 24) = run_core; *(uint32_t*)(buf + 24) = run_core;
*(uint32_t*)(buf + 28) = frame_type;
ret = msg_transfer_send_msg(handler.value, cu_flag, (uint8_t *)buf, offset, size); ret = msg_transfer_send_msg(handler.value, cu_flag, (uint8_t *)buf, offset, size);
ret = msg_transfer_send_end(handler.value,cu_flag); ret = msg_transfer_send_end(handler.value,cu_flag);
@ -255,8 +253,9 @@ int32_t test_case(uint32_t argc, int32_t* argvp)
uint8_t scs_id = 1; // NR 30K uint8_t scs_id = 1; // NR 30K
uint8_t cell_id = 0; uint8_t cell_id = 0;
uint32_t run_ape = 0xF; uint32_t run_ape = 0xF;
uint8_t frame_type = 1; // tdd
cell_setup_simulation(scs_id, cell_id, run_ape); cell_setup_simulation(scs_id, cell_id, run_ape, frame_type);
while(1) while(1)
{ {

View File

@ -231,8 +231,6 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core, u
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
sleep(1);
int32_t ret = msg_transfer_send_start(handler.value,cu_flag); int32_t ret = msg_transfer_send_start(handler.value,cu_flag);
/************C_PLANE***************/ /************C_PLANE***************/
@ -284,10 +282,10 @@ int32_t test_case(uint32_t argc, int32_t* argvp)
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
int32_t ret; int32_t ret;
uint8_t scs_id = 1; // NR 30K uint8_t scs_id = 1; // NR 30K
uint8_t cell_id = 0; uint8_t cell_id = 0;
uint32_t run_ape = 0xF; uint32_t run_ape = 0xF;
uint8_t frame_type = 1; // tdd uint8_t frame_type = 1; // tdd
cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the first cell */ cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the first cell */
UCP_PRINT_DEBUG("call cell setup(1)"); UCP_PRINT_DEBUG("call cell setup(1)");
@ -297,10 +295,10 @@ int32_t test_case(uint32_t argc, int32_t* argvp)
if ((100000 == gu32_rx_callback_data_cnt) && (0 == u8_cell_flag)) if ((100000 == gu32_rx_callback_data_cnt) && (0 == u8_cell_flag))
{ {
/* 1st cell build ok after 10s */ /* 1st cell build ok after 10s */
scs_id = 1; // NR 30K scs_id = 1; // NR 30K
cell_id = 1; cell_id = 1;
run_ape = 0xF0; run_ape = 0xF0;
uint8_t frame_type = 1; // tdd frame_type = 1; // tdd
cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the second cell */ cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the second cell */
u8_cell_flag = 1; u8_cell_flag = 1;
UCP_PRINT_DEBUG("call cell setup(2)"); UCP_PRINT_DEBUG("call cell setup(2)");

View File

@ -230,8 +230,6 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core, u
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
sleep(1);
int32_t ret = msg_transfer_send_start(handler.value,cu_flag); int32_t ret = msg_transfer_send_start(handler.value,cu_flag);
/************C_PLANE***************/ /************C_PLANE***************/
@ -283,10 +281,10 @@ int32_t test_case(uint32_t argc, int32_t* argvp)
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
int32_t ret; int32_t ret;
uint8_t scs_id = 0; // NR 15K uint8_t scs_id = 0; // NR 15K
uint8_t cell_id = 0; uint8_t cell_id = 0;
uint32_t run_ape = 0xF; uint32_t run_ape = 0xF;
uint8_t frame_type = 1; // tdd uint8_t frame_type = 1; // tdd
cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the first cell */ cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the first cell */
UCP_PRINT_DEBUG("call cell setup(1)"); UCP_PRINT_DEBUG("call cell setup(1)");
@ -296,10 +294,10 @@ int32_t test_case(uint32_t argc, int32_t* argvp)
if ((100000 == gu32_rx_callback_data_cnt) && (0 == u8_cell_flag)) if ((100000 == gu32_rx_callback_data_cnt) && (0 == u8_cell_flag))
{ {
/* 1st cell build ok after 10s */ /* 1st cell build ok after 10s */
scs_id = 0; // NR 15K scs_id = 0; // NR 15K
cell_id = 1; cell_id = 1;
run_ape = 0xF0; run_ape = 0xF0;
uint8_t frame_type = 1; // tdd frame_type = 1; // tdd
cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the second cell */ cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the second cell */
u8_cell_flag = 1; u8_cell_flag = 1;
UCP_PRINT_DEBUG("call cell setup(2)"); UCP_PRINT_DEBUG("call cell setup(2)");

View File

@ -30,7 +30,7 @@
uint32_t slot_ind_flag = 0; uint32_t slot_ind_flag = 0;
uint32_t slot_ind_time_flag = 0; uint32_t slot_ind_time_flag = 0;
uint32_t g_slot_time = 0; uint32_t g_slot_time = 0;
uint32_t gu32_value = 0; uint32_t gu32_value = 0;
uint32_t gu32_tick_receive_ctrl = 0; uint32_t gu32_tick_receive_ctrl = 0;
uint32_t gu32_tick_from_tx_ctrl = 0; uint32_t gu32_tick_from_tx_ctrl = 0;
@ -230,8 +230,6 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core, u
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
sleep(1);
int32_t ret = msg_transfer_send_start(handler.value,cu_flag); int32_t ret = msg_transfer_send_start(handler.value,cu_flag);
/************C_PLANE***************/ /************C_PLANE***************/
@ -283,10 +281,10 @@ int32_t test_case(uint32_t argc, int32_t* argvp)
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
int32_t ret; int32_t ret;
uint8_t scs_id = 1; // NR 30K uint8_t scs_id = 1; // NR 30K
uint8_t cell_id = 0; uint8_t cell_id = 0;
uint32_t run_ape = 0xF; uint32_t run_ape = 0xF;
uint8_t frame_type = 1; // tdd uint8_t frame_type = 1; // tdd
cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the first cell */ cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the first cell */
UCP_PRINT_DEBUG("call cell setup(1)"); UCP_PRINT_DEBUG("call cell setup(1)");
@ -296,10 +294,10 @@ int32_t test_case(uint32_t argc, int32_t* argvp)
if ((100000 == gu32_rx_callback_data_cnt) && (0 == u8_cell_flag)) if ((100000 == gu32_rx_callback_data_cnt) && (0 == u8_cell_flag))
{ {
/* 1st cell build ok after 10s */ /* 1st cell build ok after 10s */
scs_id = 0; // NR 15K scs_id = 0; // NR 15K
cell_id = 1; cell_id = 1;
run_ape = 0xF0; run_ape = 0xF0;
uint8_t frame_type = 1; // tdd frame_type = 1; // tdd
cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the second cell */ cell_setup_simulation(scs_id, cell_id, run_ape, frame_type); /* the second cell */
u8_cell_flag = 1; u8_cell_flag = 1;
UCP_PRINT_DEBUG("call cell setup(2)"); UCP_PRINT_DEBUG("call cell setup(2)");

View File

@ -207,9 +207,6 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core, u
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
//usleep(10000);
sleep(1);
int32_t ret = msg_transfer_send_start(handler.value,cu_flag); int32_t ret = msg_transfer_send_start(handler.value,cu_flag);
/************C_PLANE***************/ /************C_PLANE***************/

View File

@ -207,9 +207,6 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core, u
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
//usleep(10000);
sleep(1);
int32_t ret = msg_transfer_send_start(handler.value,cu_flag); int32_t ret = msg_transfer_send_start(handler.value,cu_flag);
/************C_PLANE***************/ /************C_PLANE***************/

View File

@ -207,9 +207,6 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core, u
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
//usleep(10000);
sleep(1);
int32_t ret = msg_transfer_send_start(handler.value,cu_flag); int32_t ret = msg_transfer_send_start(handler.value,cu_flag);
/************C_PLANE***************/ /************C_PLANE***************/

View File

@ -200,9 +200,6 @@ void cell_setup_simulation(uint8_t scs_id, uint8_t cell_id, uint32_t run_core, u
handler.inst_id = 0; handler.inst_id = 0;
handler.type_id = CU_SPLIT; handler.type_id = CU_SPLIT;
//usleep(10000);
sleep(1);
int32_t ret = msg_transfer_send_start(handler.value,cu_flag); int32_t ret = msg_transfer_send_start(handler.value,cu_flag);
/************C_PLANE***************/ /************C_PLANE***************/