四通道json更美观紧凑

This commit is contained in:
yangshenbo 2026-07-29 10:50:06 +08:00
parent 4d9b923362
commit 18f5c05019
7 changed files with 1623 additions and 1064 deletions

View File

@ -6,11 +6,13 @@
"metadata": {
"collapsed": true,
"ExecuteTime": {
"end_time": "2026-07-28T13:59:14.582505Z",
"start_time": "2026-07-28T13:59:14.575884Z"
"end_time": "2026-07-29T02:47:18.264723Z",
"start_time": "2026-07-29T02:47:18.172357Z"
}
},
"source": [
"%load_ext autoreload\n",
"%autoreload 2\n",
"import sys\n",
"import os\n",
"import numpy as np\n",
@ -27,10 +29,9 @@
"mk = make_case()\n",
"mk_instr = make_inst()\n",
"from pathlib import Path\n",
"def run_case(params, save_json=True, write_hw=False):\n",
"def run_case(params):\n",
" \"\"\"\n",
" 通用执行函数:自动判断模式并按需调用 configure_chip_output, env_config, instruction_config\n",
" :param output_dir: 可选,自定义输出文件和 JSON 保存的目录路径\n",
" \"\"\"\n",
" # 确定最终输出目录\n",
" base_dir = Path('D:/MyDocument/工作/Z芯片的case生成器/Chip_Case_Generator/4ch-Z_Generator/gen_cases') # 在这边选择case目录所在位置\n",
@ -59,11 +60,12 @@
" print(\"执行了 instruction_config\")\n",
" \n",
" \n",
" # 基础硬件寄存器下发\n",
" if write_hw:\n",
" # 保证存储器不用的时候不为空, 防止报错\n",
" channel = params['channel']\n",
" envm_base =addr_base['ENVM0_BASE'] + channel* 0x600000\n",
" itcm_base = addr_base['ITCM0_BASE'] + channel* 0x600000\n",
" envelope_configs = params.get('envelope_configs', None)\n",
" if envelope_configs is None:\n",
" mk.rw_once('w',envm_base , 0, params['config_file'])\n",
" instr_type = params.get('instr_type', None)\n",
" if instr_type is None:\n",
@ -73,14 +75,23 @@
" return None\n",
"\n"
],
"outputs": [],
"execution_count": 41
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"The autoreload extension is already loaded. To reload it, use:\n",
" %reload_ext autoreload\n"
]
}
],
"execution_count": 10
},
{
"metadata": {
"ExecuteTime": {
"end_time": "2026-07-28T14:17:52.745749Z",
"start_time": "2026-07-28T14:17:52.706024Z"
"end_time": "2026-07-29T02:47:24.889706Z",
"start_time": "2026-07-29T02:47:24.774951Z"
}
},
"cell_type": "code",
@ -207,13 +218,13 @@
]
}
],
"execution_count": 62
"execution_count": 11
},
{
"metadata": {
"ExecuteTime": {
"end_time": "2026-07-28T14:03:52.514124Z",
"start_time": "2026-07-28T14:03:52.492729Z"
"end_time": "2026-07-29T02:19:42.215024Z",
"start_time": "2026-07-29T02:19:42.192273Z"
}
},
"cell_type": "code",
@ -240,22 +251,22 @@
"if hex_file.exists():\n",
" hex_file.unlink()\n",
"# ==========================================\n",
"run_case(param_ch0,write_hw = True)\n",
"run_case(param_ch0)\n",
"\n",
"#通道1\n",
"param_ch1 = param_ch0.copy()\n",
"param_ch1['channel'] = 1\n",
"run_case(param_ch1,write_hw = True)\n",
"run_case(param_ch1)\n",
"\n",
"#通道2\n",
"param_ch2 = param_ch0.copy()\n",
"param_ch2['channel'] = 2\n",
"run_case(param_ch2,write_hw = True)\n",
"run_case(param_ch2)\n",
"\n",
"#通道3\n",
"param_ch3 = param_ch0.copy()\n",
"param_ch3['channel'] = 3\n",
"run_case(param_ch3,write_hw = True)\n",
"run_case(param_ch3)\n",
"# ==========================================\n",
"#参数打包到json里面\n",
"out_dir = Path(param_ch0['config_file']).parent \n",
@ -287,7 +298,7 @@
]
}
],
"execution_count": 53
"execution_count": 4
},
{
"metadata": {
@ -322,22 +333,22 @@
"if hex_file.exists():\n",
" hex_file.unlink()\n",
"# ==========================================\n",
"run_case(param_ch0,write_hw = True)\n",
"run_case(param_ch0)\n",
"\n",
"#通道1\n",
"param_ch1 = param_ch0.copy()\n",
"param_ch1['channel'] = 1\n",
"run_case(param_ch1,write_hw = True)\n",
"run_case(param_ch1)\n",
"\n",
"#通道2\n",
"param_ch2 = param_ch0.copy()\n",
"param_ch2['channel'] = 2\n",
"run_case(param_ch2,write_hw = True)\n",
"run_case(param_ch2)\n",
"\n",
"#通道3\n",
"param_ch3 = param_ch0.copy()\n",
"param_ch3['channel'] = 3\n",
"run_case(param_ch3,write_hw = True)\n",
"run_case(param_ch3)\n",
"\n",
"# ==========================================\n",
"#参数打包到json里面\n",
@ -410,22 +421,22 @@
" hex_file.unlink()\n",
"# ==========================================\n",
"\n",
"run_case(param_ch0,write_hw = True)\n",
"run_case(param_ch0)\n",
"\n",
"#通道1\n",
"param_ch1 = param_ch0.copy()\n",
"param_ch1['channel'] = 1\n",
"run_case(param_ch1,write_hw = True)\n",
"run_case(param_ch1)\n",
"\n",
"#通道2\n",
"param_ch2 = param_ch0.copy()\n",
"param_ch2['channel'] = 2\n",
"run_case(param_ch2,write_hw = True)\n",
"run_case(param_ch2)\n",
"\n",
"#通道3\n",
"param_ch3 = param_ch0.copy()\n",
"param_ch3['channel'] = 3\n",
"run_case(param_ch3,write_hw = True)\n",
"run_case(param_ch3)\n",
"# ==========================================\n",
"#参数打包到json里面\n",
"out_dir = Path(param_ch0['config_file']).parent \n",
@ -466,8 +477,8 @@
{
"metadata": {
"ExecuteTime": {
"end_time": "2026-07-28T14:23:00.027209Z",
"start_time": "2026-07-28T14:23:00.001173Z"
"end_time": "2026-07-29T02:47:57.908778Z",
"start_time": "2026-07-29T02:47:57.796222Z"
}
},
"cell_type": "code",
@ -477,8 +488,8 @@
"# 1. 定义你要还原的 Case 信息\n",
"# ==========================================\n",
"base_dir = Path('D:/MyDocument/工作/Z芯片的case生成器/Chip_Case_Generator/4ch-Z_Generator/gen_cases')\n",
"folder_name = 'RAMP' # 填入你要还原的文件夹名\n",
"case_name = 'RAMP_MCU_FIXED' # 填入你要还原的 Case 名字\n",
"folder_name = 'General' # 填入你要还原的文件夹名\n",
"case_name = 'env2' # 填入你要还原的 Case 名字\n",
"out_dir = base_dir / folder_name\n",
"\n",
"# ==========================================\n",
@ -506,7 +517,7 @@
" \n",
" # 将读取到的参数直接塞进 run_case。\n",
" # 此时不需要再保存 json (save_json=False),但需要写入硬件文本 (write_hw=True)\n",
" run_case(ch_param, save_json=False, write_hw=True)\n",
" run_case(ch_param)\n",
"\n",
"print(\"Case 还原完成!\")"
],
@ -517,22 +528,26 @@
"output_type": "stream",
"text": [
"执行 config_chip_reg\n",
"执行了 env_config\n",
"执行了 instruction_config\n",
"生成文件路径D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_MCU_FIXED_HEX.txt\n",
"生成文件路径D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\General\\env2_HEX.txt\n",
"执行 config_chip_reg\n",
"执行了 env_config\n",
"执行了 instruction_config\n",
"生成文件路径D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_MCU_FIXED_HEX.txt\n",
"生成文件路径D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\General\\env2_HEX.txt\n",
"执行 config_chip_reg\n",
"执行了 env_config\n",
"执行了 instruction_config\n",
"生成文件路径D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_MCU_FIXED_HEX.txt\n",
"生成文件路径D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\General\\env2_HEX.txt\n",
"执行 config_chip_reg\n",
"执行了 env_config\n",
"执行了 instruction_config\n",
"生成文件路径D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_MCU_FIXED_HEX.txt\n",
"🎉 Case 还原完成!\n"
"生成文件路径D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\General\\env2_HEX.txt\n",
"Case 还原完成!\n"
]
}
],
"execution_count": 63
"execution_count": 12
}
],
"metadata": {

View File

@ -13,16 +13,47 @@ class ParamsManager:
def _ensure_dir_exists(self):
Path(self.params_dir).mkdir(parents=True, exist_ok=True)
# def save(self, params, filename):
# if not filename.endswith('.json'):
# filename = filename + '.json'
#
# filepath = os.path.join(self.params_dir, filename)
#
# with open(filepath, 'w', encoding='utf-8') as f:
# json.dump(params, f, indent=2, separators=(',', ':'), ensure_ascii=False)
def save(self, params, filename):
if not filename.endswith('.json'):
filename = filename + '.json'
if not filename.endswith(".json"):
filename = filename + ".json"
filepath = os.path.join(self.params_dir, filename)
with open(filepath, 'w', encoding='utf-8') as f:
json.dump(params, f, indent=None, separators=(',', ':'), ensure_ascii=False)
# 1. 正常生成带有标准缩进的 JSON 字符串
raw_json = json.dumps(params, indent=2, ensure_ascii=False)
# 2. 正则1将简单的纯数值/字符串列表压缩成单行 [100, 200, 300]
def _flatten_array(match):
content = match.group(1)
if "{" in content: # 如果包含字典对象,不在这里处理
return match.group(0)
items = [item.strip() for item in content.split(",") if item.strip()]
return "[" + ", ".join(items) + "]"
compact_json = re.sub(r"\[([\s\S]*?)\]", _flatten_array, raw_json)
# 3. 正则2将列表里的单层字典对象压缩成单行 {"a": 1, "b": 2}
def _flatten_object(match):
content = match.group(1)
if "{" in content or "[" in content: # 包含嵌套对象的字典不压缩
return match.group(0)
# 清理换行和多余空格,格式化为单行
lines = [line.strip() for line in content.split("\n") if line.strip()]
return "{ " + " ".join(lines) + " }"
final_json = re.sub(r"\{([^{}\[\]]*?)\}", _flatten_object, compact_json)
with open(filepath, "w", encoding="utf-8") as f:
f.write(final_json)
@ -51,3 +82,5 @@ class ParamsManager:
# # 加载单个参数
# params = pm.load('AWG_NCO')

View File

@ -9,141 +9,38 @@
"amp_mod_enable": true,
"freq_mod_enable": true,
"bias_enable": true,
"fcw": [
100,
200,
300,
400
],
"fcw": [100, 200, 300, 400],
"mcu_reg_clr": true,
"pcw": [
0,
30,
45,
90,
120,
135,
150,
180
],
"pcw": [0, 30, 45, 90, 120, 135, 150, 180],
"rz_ff_pha": 0,
"rz_fm_pha": 45,
"ff_amp": [
32767,
32767,
32767,
32767
],
"fm_amp": [
32767,
32767,
32767,
32767
],
"bias": [
1,
2,
3,
4
],
"ff_amp": [32767, 32767, 32767, 32767],
"fm_amp": [32767, 32767, 32767, 32767],
"bias": [1, 2, 3, 4],
"fm_en": false,
"instr_type": "general_send_wait",
"send_interval": [
100,
150,
200,
250,
300,
350,
400,
450,
500
],
"send_interval": [100, 150, 200, 250, 300, 350, 400, 450, 500],
"cycle_num": 1,
"codeword_configs": [
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 4
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 5
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 6
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 7
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 8
}
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 4 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 5 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 6 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 7 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 8 }
],
"sweep_config": {
"sweep_num": 0,
"offsets": [
120,
64
],
"steps": [
3000,
143165576
]
"offsets": [120, 64],
"steps": [3000, 143165576]
},
"envelope_configs": [
{
"envelope_type": "rect_hold",
"amp": 32767
},
{
"envelope_type": "flattop_hold",
"amp": 32767,
"edge_time": 3.5,
"wave_time": 30
},
{
"envelope_type": "acz",
"amp": 32767,
"wave_time": 48
},
{
"envelope_type": "accz",
"wave_time": 48
},
{
"envelope_type": "cosine",
"amp": 32767,
"wave_time": 300
},
{
"envelope_type": "rect",
"amp": 32767,
"wave_time": 12
},
{
"envelope_type": "flattop",
"amp": 32767,
"edge_time": 2,
"wave_time": 22
}
{ "envelope_type": "rect_hold", "amp": 32767 },
{ "envelope_type": "flattop_hold", "amp": 32767, "edge_time": 3.5, "wave_time": 30 },
{ "envelope_type": "acz", "amp": 32767, "wave_time": 48 },
{ "envelope_type": "accz", "wave_time": 48 },
{ "envelope_type": "cosine", "amp": 32767, "wave_time": 300 },
{ "envelope_type": "rect", "amp": 32767, "wave_time": 12 },
{ "envelope_type": "flattop", "amp": 32767, "edge_time": 2, "wave_time": 22 }
],
"FolderName": "General",
"CaseName": "env2",
@ -159,141 +56,38 @@
"amp_mod_enable": true,
"freq_mod_enable": true,
"bias_enable": true,
"fcw": [
200,
200,
300,
400
],
"fcw": [200, 200, 300, 400],
"mcu_reg_clr": true,
"pcw": [
0,
30,
45,
90,
120,
135,
150,
180
],
"pcw": [0, 30, 45, 90, 120, 135, 150, 180],
"rz_ff_pha": 0,
"rz_fm_pha": 45,
"ff_amp": [
32767,
32767,
32767,
32767
],
"fm_amp": [
32767,
32767,
32767,
32767
],
"bias": [
1,
2,
3,
4
],
"ff_amp": [32767, 32767, 32767, 32767],
"fm_amp": [32767, 32767, 32767, 32767],
"bias": [1, 2, 3, 4],
"fm_en": false,
"instr_type": "general_send_wait",
"send_interval": [
100,
150,
200,
250,
300,
350,
400,
450,
500
],
"send_interval": [100, 150, 200, 250, 300, 350, 400, 450, 500],
"cycle_num": 1,
"codeword_configs": [
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 4
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 5
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 6
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 7
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 8
}
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 4 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 5 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 6 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 7 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 8 }
],
"sweep_config": {
"sweep_num": 0,
"offsets": [
120,
64
],
"steps": [
3000,
143165576
]
"offsets": [120, 64],
"steps": [3000, 143165576]
},
"envelope_configs": [
{
"envelope_type": "rect_hold",
"amp": 32767
},
{
"envelope_type": "flattop_hold",
"amp": 32767,
"edge_time": 3.5,
"wave_time": 30
},
{
"envelope_type": "acz",
"amp": 32767,
"wave_time": 48
},
{
"envelope_type": "accz",
"wave_time": 48
},
{
"envelope_type": "cosine",
"amp": 32767,
"wave_time": 300
},
{
"envelope_type": "rect",
"amp": 32767,
"wave_time": 12
},
{
"envelope_type": "flattop",
"amp": 32767,
"edge_time": 2,
"wave_time": 22
}
{ "envelope_type": "rect_hold", "amp": 32767 },
{ "envelope_type": "flattop_hold", "amp": 32767, "edge_time": 3.5, "wave_time": 30 },
{ "envelope_type": "acz", "amp": 32767, "wave_time": 48 },
{ "envelope_type": "accz", "wave_time": 48 },
{ "envelope_type": "cosine", "amp": 32767, "wave_time": 300 },
{ "envelope_type": "rect", "amp": 32767, "wave_time": 12 },
{ "envelope_type": "flattop", "amp": 32767, "edge_time": 2, "wave_time": 22 }
],
"FolderName": "General",
"CaseName": "env2",
@ -309,141 +103,38 @@
"amp_mod_enable": true,
"freq_mod_enable": true,
"bias_enable": true,
"fcw": [
300,
200,
300,
400
],
"fcw": [300, 200, 300, 400],
"mcu_reg_clr": true,
"pcw": [
0,
30,
45,
90,
120,
135,
150,
180
],
"pcw": [0, 30, 45, 90, 120, 135, 150, 180],
"rz_ff_pha": 0,
"rz_fm_pha": 45,
"ff_amp": [
32767,
32767,
32767,
32767
],
"fm_amp": [
32767,
32767,
32767,
32767
],
"bias": [
1,
2,
3,
4
],
"ff_amp": [32767, 32767, 32767, 32767],
"fm_amp": [32767, 32767, 32767, 32767],
"bias": [1, 2, 3, 4],
"fm_en": false,
"instr_type": "general_send_wait",
"send_interval": [
100,
150,
200,
250,
300,
350,
400,
450,
500
],
"send_interval": [100, 150, 200, 250, 300, 350, 400, 450, 500],
"cycle_num": 1,
"codeword_configs": [
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 4
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 5
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 6
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 7
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 8
}
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 4 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 5 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 6 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 7 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 8 }
],
"sweep_config": {
"sweep_num": 0,
"offsets": [
120,
64
],
"steps": [
3000,
143165576
]
"offsets": [120, 64],
"steps": [3000, 143165576]
},
"envelope_configs": [
{
"envelope_type": "rect_hold",
"amp": 32767
},
{
"envelope_type": "flattop_hold",
"amp": 32767,
"edge_time": 3.5,
"wave_time": 30
},
{
"envelope_type": "acz",
"amp": 32767,
"wave_time": 48
},
{
"envelope_type": "accz",
"wave_time": 48
},
{
"envelope_type": "cosine",
"amp": 32767,
"wave_time": 300
},
{
"envelope_type": "rect",
"amp": 32767,
"wave_time": 12
},
{
"envelope_type": "flattop",
"amp": 32767,
"edge_time": 2,
"wave_time": 22
}
{ "envelope_type": "rect_hold", "amp": 32767 },
{ "envelope_type": "flattop_hold", "amp": 32767, "edge_time": 3.5, "wave_time": 30 },
{ "envelope_type": "acz", "amp": 32767, "wave_time": 48 },
{ "envelope_type": "accz", "wave_time": 48 },
{ "envelope_type": "cosine", "amp": 32767, "wave_time": 300 },
{ "envelope_type": "rect", "amp": 32767, "wave_time": 12 },
{ "envelope_type": "flattop", "amp": 32767, "edge_time": 2, "wave_time": 22 }
],
"FolderName": "General",
"CaseName": "env2",
@ -459,141 +150,38 @@
"amp_mod_enable": true,
"freq_mod_enable": true,
"bias_enable": true,
"fcw": [
400,
200,
300,
400
],
"fcw": [400, 200, 300, 400],
"mcu_reg_clr": true,
"pcw": [
0,
30,
45,
90,
120,
135,
150,
180
],
"pcw": [0, 30, 45, 90, 120, 135, 150, 180],
"rz_ff_pha": 0,
"rz_fm_pha": 45,
"ff_amp": [
32767,
32767,
32767,
32767
],
"fm_amp": [
32767,
32767,
32767,
32767
],
"bias": [
1,
2,
3,
4
],
"ff_amp": [32767, 32767, 32767, 32767],
"fm_amp": [32767, 32767, 32767, 32767],
"bias": [1, 2, 3, 4],
"fm_en": false,
"instr_type": "general_send_wait",
"send_interval": [
100,
150,
200,
250,
300,
350,
400,
450,
500
],
"send_interval": [100, 150, 200, 250, 300, 350, 400, 450, 500],
"cycle_num": 1,
"codeword_configs": [
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 4
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 5
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 6
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 7
},
{
"wave_hold": 0,
"fcw_index": 0,
"pcw_index": 0,
"code_clr": 1,
"env_index": 8
}
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 4 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 5 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 6 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 7 },
{ "wave_hold": 0, "fcw_index": 0, "pcw_index": 0, "code_clr": 1, "env_index": 8 }
],
"sweep_config": {
"sweep_num": 0,
"offsets": [
120,
64
],
"steps": [
3000,
143165576
]
"offsets": [120, 64],
"steps": [3000, 143165576]
},
"envelope_configs": [
{
"envelope_type": "rect_hold",
"amp": 32767
},
{
"envelope_type": "flattop_hold",
"amp": 32767,
"edge_time": 3.5,
"wave_time": 30
},
{
"envelope_type": "acz",
"amp": 32767,
"wave_time": 48
},
{
"envelope_type": "accz",
"wave_time": 48
},
{
"envelope_type": "cosine",
"amp": 32767,
"wave_time": 300
},
{
"envelope_type": "rect",
"amp": 32767,
"wave_time": 12
},
{
"envelope_type": "flattop",
"amp": 32767,
"edge_time": 2,
"wave_time": 22
}
{ "envelope_type": "rect_hold", "amp": 32767 },
{ "envelope_type": "flattop_hold", "amp": 32767, "edge_time": 3.5, "wave_time": 30 },
{ "envelope_type": "acz", "amp": 32767, "wave_time": 48 },
{ "envelope_type": "accz", "wave_time": 48 },
{ "envelope_type": "cosine", "amp": 32767, "wave_time": 300 },
{ "envelope_type": "rect", "amp": 32767, "wave_time": 12 },
{ "envelope_type": "flattop", "amp": 32767, "edge_time": 2, "wave_time": 22 }
],
"FolderName": "General",
"CaseName": "env2",

File diff suppressed because it is too large Load Diff

View File

@ -1,50 +1 @@
{
"ch0": {
"channel": 0,
"chip_mode": "RAMP",
"ramp_ctrl": "SPI",
"fixed_enable": true,
"fixed_value": 22767,
"height": 512,
"step_time": 34,
"FolderName": "RAMP",
"CaseName": "RAMP_SPI",
"config_file": "D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_SPI_HEX.txt"
},
"ch1": {
"channel": 1,
"chip_mode": "RAMP",
"ramp_ctrl": "SPI",
"fixed_enable": true,
"fixed_value": 22767,
"height": 512,
"step_time": 34,
"FolderName": "RAMP",
"CaseName": "RAMP_SPI",
"config_file": "D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_SPI_HEX.txt"
},
"ch2": {
"channel": 2,
"chip_mode": "RAMP",
"ramp_ctrl": "SPI",
"fixed_enable": true,
"fixed_value": 22767,
"height": 512,
"step_time": 34,
"FolderName": "RAMP",
"CaseName": "RAMP_SPI",
"config_file": "D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_SPI_HEX.txt"
},
"ch3": {
"channel": 3,
"chip_mode": "RAMP",
"ramp_ctrl": "SPI",
"fixed_enable": true,
"fixed_value": 22767,
"height": 512,
"step_time": 34,
"FolderName": "RAMP",
"CaseName": "RAMP_SPI",
"config_file": "D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_SPI_HEX.txt"
}
}
{"ch0":{"channel":0,"chip_mode":"RAMP","ramp_ctrl":"SPI","fixed_enable":true,"fixed_value":22767,"height":512,"step_time":34,"FolderName":"RAMP","CaseName":"RAMP_SPI","config_file":"D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_SPI_HEX.txt"},"ch1":{"channel":1,"chip_mode":"RAMP","ramp_ctrl":"SPI","fixed_enable":true,"fixed_value":22767,"height":512,"step_time":34,"FolderName":"RAMP","CaseName":"RAMP_SPI","config_file":"D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_SPI_HEX.txt"},"ch2":{"channel":2,"chip_mode":"RAMP","ramp_ctrl":"SPI","fixed_enable":true,"fixed_value":22767,"height":512,"step_time":34,"FolderName":"RAMP","CaseName":"RAMP_SPI","config_file":"D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_SPI_HEX.txt"},"ch3":{"channel":3,"chip_mode":"RAMP","ramp_ctrl":"SPI","fixed_enable":true,"fixed_value":22767,"height":512,"step_time":34,"FolderName":"RAMP","CaseName":"RAMP_SPI","config_file":"D:\\MyDocument\\工作\\Z芯片的case生成器\\Chip_Case_Generator\\4ch-Z_Generator\\gen_cases\\RAMP\\RAMP_SPI_HEX.txt"}}

View File

@ -78,483 +78,3 @@
00100004
0000002b
00300108
00100004
00000008
00300118
00100004
58ef8000
00300124
00100004
80000000
00500000
00100004
00000000
00100000
00100004
0000002b
00900108
00100004
00000008
00900118
00100004
58ef8000
00900124
00100004
80000000
00b00000
00100004
00000000
00700000
00100004
0000002b
00f00108
00100004
00000008
00f00118
00100004
58ef8000
00f00124
00100004
80000000
01100000
00100004
00000000
00d00000
00100004
0000002b
01500108
00100004
00000008
01500118
00100004
58ef8000
01500124
00100004
80000000
01700000
00100004
00000000
01300000
00100004
0000002b
00300108
00100004
00000008
00300118
00100004
58ef8000
00300124
00100004
80000000
00500000
00100004
00000000
00100000
00100004
0000002b
00900108
00100004
00000008
00900118
00100004
58ef8000
00900124
00100004
80000000
00b00000
00100004
00000000
00700000
00100004
0000002b
00f00108
00100004
00000008
00f00118
00100004
58ef8000
00f00124
00100004
80000000
01100000
00100004
00000000
00d00000
00100004
0000002b
01500108
00100004
00000008
01500118
00100004
58ef8000
01500124
00100004
80000000
01700000
00100004
00000000
01300000
00100004
0000002b
00300108
00100004
00000008
00300118
00100004
58ef8000
00300124
00100004
80000000
00500000
00100004
00000000
00100000
00100004
0000002b
00900108
00100004
00000008
00900118
00100004
58ef8000
00900124
00100004
80000000
00b00000
00100004
00000000
00700000
00100004
0000002b
00f00108
00100004
00000008
00f00118
00100004
58ef8000
00f00124
00100004
80000000
01100000
00100004
00000000
00d00000
00100004
0000002b
01500108
00100004
00000008
01500118
00100004
58ef8000
01500124
00100004
80000000
01700000
00100004
00000000
01300000
00100004
0000002b
00300108
00100004
00000008
00300118
00100004
58ef8000
00300124
00100004
80000000
00500000
00100004
00000000
00100000
00100004
0000002b
00900108
00100004
00000008
00900118
00100004
58ef8000
00900124
00100004
80000000
00b00000
00100004
00000000
00700000
00100004
0000002b
00f00108
00100004
00000008
00f00118
00100004
58ef8000
00f00124
00100004
80000000
01100000
00100004
00000000
00d00000
00100004
0000002b
01500108
00100004
00000008
01500118
00100004
58ef8000
01500124
00100004
80000000
01700000
00100004
00000000
01300000
00100004
0000002b
00300108
00100004
00000008
00300118
00100004
58ef8000
00300124
00100004
80000000
00500000
00100004
00000000
00100000
00100004
0000002b
00900108
00100004
00000008
00900118
00100004
58ef8000
00900124
00100004
80000000
00b00000
00100004
00000000
00700000
00100004
0000002b
00f00108
00100004
00000008
00f00118
00100004
58ef8000
00f00124
00100004
80000000
01100000
00100004
00000000
00d00000
00100004
0000002b
01500108
00100004
00000008
01500118
00100004
58ef8000
01500124
00100004
80000000
01700000
00100004
00000000
01300000
00100004
0000002b
00300108
00100004
00000008
00300118
00100004
58ef8000
00300124
00100004
80000000
00500000
00100004
00000000
00100000
00100004
0000002b
00900108
00100004
00000008
00900118
00100004
58ef8000
00900124
00100004
80000000
00b00000
00100004
00000000
00700000
00100004
0000002b
00f00108
00100004
00000008
00f00118
00100004
58ef8000
00f00124
00100004
80000000
01100000
00100004
00000000
00d00000
00100004
0000002b
01500108
00100004
00000008
01500118
00100004
58ef8000
01500124
00100004
80000000
01700000
00100004
00000000
01300000
00100004
0000002b