diff --git a/app/lib/a_process/pd_csg.c b/app/lib/a_process/pd_csg.c index 2113651..eba7018 100755 --- a/app/lib/a_process/pd_csg.c +++ b/app/lib/a_process/pd_csg.c @@ -339,8 +339,8 @@ int32_t _csg_connect_send(void) pinfo->deployment_date = device_info.deployment_date; strncpy((char *)pinfo->app_version, host.version, sizeof(pinfo->app_version)-1); strncpy((char *)pinfo->app_compile_time, host.compile, sizeof(pinfo->app_compile_time)-1); - //strncpy((char *)pinfo->hardware_version, host.hardversion, 31); - //strncpy((char *)pinfo->FPGA_version, host.FPGAversion, 31); + strncpy((char *)pinfo->hardware_version, host.hardversion, 31); + strncpy((char *)pinfo->FPGA_version, host.FPGAversion, 31); strncpy((char *)pinfo->hardware_version, "RFSOC_V1.0", 31); strncpy((char *)pinfo->FPGA_version, "20250730", 31); pinfo->ip = device_info.ip; @@ -1002,8 +1002,8 @@ int32_t _csg_dev_info_get_recv(char *pkt) pinfo->deployment_date = device_info.deployment_date; strncpy((char *)pinfo->app_compile_time, host.compile, 31); strncpy((char *)pinfo->app_version, host.version, 31); - //strncpy((char *)pinfo->hardware_version, host.hardversion, 31); - //strncpy((char *)pinfo->FPGA_version, host.FPGAversion, 31); + strncpy((char *)pinfo->hardware_version, host.hardversion, 31); + strncpy((char *)pinfo->FPGA_version, host.FPGAversion, 31); strncpy((char *)pinfo->hardware_version, "RFSOC_V1.0", 31); strncpy((char *)pinfo->FPGA_version, "20250730", 31); pinfo->ip = device_info.ip; diff --git a/app/lib/a_process/pd_dbg.c b/app/lib/a_process/pd_dbg.c index cfb4abd..501c482 100755 --- a/app/lib/a_process/pd_dbg.c +++ b/app/lib/a_process/pd_dbg.c @@ -131,8 +131,8 @@ int32_t _debug_pkt_factory_cfg_get(char *buf, int len) strncpy((char*)info->app_version, host.version, 32); strncpy((char*)info->app_compile_time, host.compile, 32); - //strncpy((char*)info->hardware_version, host.hardversion, 32); - // 赋值 FPGA_version + strncpy((char*)info->hardware_version, host.hardversion, 32); + strncpy((char*)info->FPGA_version, host.FPGAversion, 32); info->csg_port = csg.server_port; info->csg_ipv4 = csg.server_ip; diff --git a/app/lib/m_management/cmd.c b/app/lib/m_management/cmd.c index 1da95bd..4a248ca 100755 --- a/app/lib/m_management/cmd.c +++ b/app/lib/m_management/cmd.c @@ -2886,7 +2886,11 @@ void vtysh_device_init(void) device_info.gw = server.sin_addr.s_addr; device_info.factory_date = 1749168000; device_info.deployment_date = 1749168000; - device_info.dev_id = 1; + strncpy((char *)device_info.app_version, host.version, 31); + strncpy((char *)device_info.app_compile_time, host.compile, 31); + strncpy((char *)device_info.hardware_version, host.hardversion, 31); + strncpy((char *)device_info.FPGA_version, host.FPGAversion, 31); + device_info.dev_id = 0x6010FFFF; strncpy(device_info.hostname, "LandPower", FILE_NAME_LEN); mac_generate_from_ip(device_info.ip, device_info.mac);