我是 Simulink 测试的新手,我需要一些帮助。
我有一个模型,我正在尝试使用测试评估块进行测试。该模型旨在执行以下操作:
- 当按下按钮 >= 70ms 时,模型将在输出上断言 62.5 脉冲。
- 如果按钮被按下 < 70ms, the model will not do anything (output remains 0).
The model works fine. I have 2 test sequences. The first presses the button for < 70ms, and we get no output. I can write the assessment for that test case without issue.
However, detecting the output pulse, with a conditional of >= 70ms 证明是困难的。我正在尝试在测试管理器中完成所有这些工作,因此我可以在最后运行一份报告,显示开关去抖动模型的工作情况。
有人有什么想法吗?
我已经尝试了很多不同的验证语句与时间混合(haschanged、elapsed、if、else 等)。