|
|
|
|
@ -224,6 +224,7 @@ int32_t _debug_pkt_factory_cfg_set(char *buf, int len)
|
|
|
|
|
/* 设置报文处理. */
|
|
|
|
|
int32_t _debug_pkt_global_cfg_set(char *pkt, int len)
|
|
|
|
|
{
|
|
|
|
|
dau_t * dau_node = dau[0];
|
|
|
|
|
dbg_global_config_t *config = (dbg_global_config_t *)(pkt + sizeof(csg_pkt_head_t));
|
|
|
|
|
pd_config.config.sample_frequency = config->sample_frequency;
|
|
|
|
|
pd_config.config.trigger_sample_nums = config->trigger_sample_numbers;
|
|
|
|
|
@ -241,12 +242,20 @@ int32_t _debug_pkt_global_cfg_set(char *pkt, int len)
|
|
|
|
|
BITMAP_SET(pd_config.config.pt_B_sync_mode, PD_BIT_PT);
|
|
|
|
|
}
|
|
|
|
|
pd_config.config.pt_internal_period = 1000000000UL / config->pt_internal_period;
|
|
|
|
|
|
|
|
|
|
if(dau_node->is_connect == TRUE)
|
|
|
|
|
{
|
|
|
|
|
dau_node->reg->reg_global.trig_location = pd_config.config.trig_location;
|
|
|
|
|
dau_node->reg->reg_global.trig_threshold = pd_config.config.trig_threshold;
|
|
|
|
|
dau_node->reg->reg_global.trig_gap = pd_config.config.trig_gap;
|
|
|
|
|
dau_node->reg->reg_global.sample_interrupt_intveal_us = pd_config.config.interrupt_interval;
|
|
|
|
|
dau_node->reg->reg_global.pt_B_sync_mode = pd_config.config.pt_B_sync_mode;
|
|
|
|
|
dau_node->reg->reg_global.pt_selfsync_cycle = pd_config.config.pt_internal_period;
|
|
|
|
|
}
|
|
|
|
|
vtysh_config_save();
|
|
|
|
|
return _debug_pkt_common_send(pkt, DEBUG_CONFIG_GLOBAL_SET, 0);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* 查询用户参数查询报文处理. */
|
|
|
|
|
int32_t _debug_pkt_global_cfg_get(char *pkt, int len)
|
|
|
|
|
{
|
|
|
|
|
|