Verilog® 或 SystemVerilog timescale 设定
指定在生成的 Verilog 或 SystemVerilog 代码中使用的时间刻度
模型配置窗格: 全局设置 / 编码风格
描述
指定您要在生成的 Verilog 或 SystemVerilog 代码中使用的时间刻度。
依赖关系
当满足以下条件时,此选项启用:
目标语言(由语言选项指定)为 Verilog 或 SystemVerilog。
使用 Verilog 或 SystemVerilog 的 `timescale 指令选项启用。
设置
`timescale 1 ns/1 ns (默认) | 字符向量默认值: `timescale 1 ns/1 ns
HDL Coder™ 将此选项应用于生成的 Verilog 或 SystemVerilog 代码中的时间刻度指令。您可以自定义默认时间刻度,并指定有效且可编译的时间刻度指令。Verilog 和 SystemVerilog 语言使用此指令来确定用于计算延迟值的时间单位和精度。
默认情况下,时间单位和精度均为 1ns。例如,如果您将时间刻度自定义为 `timescale 1 ns/1 ps,则延迟单位变为 1ns,并且该值精确到最接近的 1 ps。
推荐设置
无推荐设置。
编程用法
参数:Timescale |
| 类型:字符向量 |
| 值:字符向量,指定为有效时间刻度值 |
默认值: `timescale 1 ns/1 ns |
版本历史记录
在 R2012a 中推出