@@ -31,49 +31,72 @@ adi_ip_files axi_ltc2387 [list \
31
31
32
32
adi_ip_properties axi_ltc2387
33
33
34
- set cc [ipx::current_core]
35
- set page0 [ipgui::get_pagespec -name " Page 0" -component $cc ]
34
+ ipx::infer_bus_interface ref_clk xilinx.com:signal:clock_rtl:1.0 [ipx::current_core]
35
+ ipx::infer_bus_interface dco_p xilinx.com:signal:clock_rtl:1.0 [ipx::current_core]
36
+ ipx::infer_bus_interface dco_n xilinx.com:signal:clock_rtl:1.0 [ipx::current_core]
36
37
37
- ipx::infer_bus_interface ref_clk xilinx.com:signal:clock_rtl:1.0 $cc
38
- ipx::infer_bus_interface dco_p xilinx.com:signal:clock_rtl:1.0 $cc
39
- ipx::infer_bus_interface dco_n xilinx.com:signal:clock_rtl:1.0 $cc
38
+ set cc [ipx::current_core]
40
39
41
- ipgui::add_static_text -name {Warning} -component $cc -parent $page0 -text {In one-lane mode, only 18-bit resolution is supported!}
40
+ set page0 [ ipgui::get_pagespec -name " Page 0 " -component $cc ]
42
41
43
42
ipx::add_user_parameter ADC_RES $cc
44
43
set_property value_resolve_type user [ipx::get_user_parameters ADC_RES -of_objects $cc ]
45
44
ipgui::add_param -name " ADC_RES" -component $cc -parent $page0
46
45
set_property -dict [list \
47
- " display_name" " ADC_RES" \
48
- " layout" " horizontal" \
49
- " tooltip" " ADC resolution" \
46
+ " display_name" " ADC resolution" \
47
+ " tooltip" " ADC_RES" \
50
48
" widget" " radioGroup" \
49
+ " layout" " horizontal" \
51
50
] [ipgui::get_guiparamspec -name " ADC_RES" -component $cc ]
52
51
53
52
set_property -dict [list \
54
- " value" " 18" \
55
53
" value_format" " long" \
56
54
" value_validation_type" " list" \
57
- " value_validation_list" " 18 16 " \
55
+ " value_validation_list" " 16 18 " \
58
56
] [ipx::get_user_parameters ADC_RES -of_objects $cc ]
59
57
58
+ ipx::add_user_parameter OUT_RES $cc
59
+ set_property value_resolve_type user [ipx::get_user_parameters OUT_RES -of_objects $cc ]
60
+ ipgui::add_param -name " OUT_RES" -component $cc -parent $page0
61
+ set_property -dict [list \
62
+ " display_name" " Output data width" \
63
+ " tooltip" " OUT_RES" \
64
+ " widget" " radioGroup" \
65
+ " layout" " horizontal" \
66
+ ] [ipgui::get_guiparamspec -name " OUT_RES" -component $cc ]
67
+
68
+ set_property -dict [list \
69
+ " value_format" " long" \
70
+ " value_validation_type" " list" \
71
+ " value_validation_list" " 16 32" \
72
+ ] [ipx::get_user_parameters OUT_RES -of_objects $cc ]
73
+
60
74
ipx::add_user_parameter TWOLANES $cc
61
75
set_property value_resolve_type user [ipx::get_user_parameters TWOLANES -of_objects $cc ]
62
76
ipgui::add_param -name " TWOLANES" -component $cc -parent $page0
63
77
set_property -dict [list \
64
- " display_name" " TWOLANES" \
65
- " layout" " horizontal" \
66
- " tooltip" " Two-lane mode (1) or one-lane mode (0)" \
78
+ " display_name" " Lane mode" \
79
+ " tooltip" " TWOLANES" \
67
80
" widget" " radioGroup" \
81
+ " layout" " horizontal" \
68
82
] [ipgui::get_guiparamspec -name " TWOLANES" -component $cc ]
69
83
70
84
set_property -dict [list \
71
- " value" " 1" \
72
85
" value_format" " long" \
73
86
" value_validation_type" " list" \
74
- " value_validation_list" " 1 0 " \
87
+ " value_validation_list" " 0 1 " \
75
88
] [ipx::get_user_parameters TWOLANES -of_objects $cc ]
76
89
90
+ # if TWOLANES=0, disable and tie to GND, ports db_p, db_n
91
+ adi_set_ports_dependency " db_p" \
92
+ " (spirit:decode(id('MODELPARAM_VALUE.TWOLANES')) == 1)"
93
+ adi_set_ports_dependency " db_n" \
94
+ " (spirit:decode(id('MODELPARAM_VALUE.TWOLANES')) == 1)"
95
+
96
+ set_property driver_value 0 [ipx::get_ports -filter " direction==in" -of_objects $cc ]
97
+
98
+ # adi_add_auto_fpga_spec_params
99
+
77
100
ipx::create_xgui_files $cc
78
101
ipx::update_checksums $cc
79
102
ipx::save_core $cc
0 commit comments