Rate Transition block outputs zero on the geenrated code interface despite the input , though it works fine during simulation.

2 ビュー (過去 30 日間)
I am using a Rate Transition block, as shown in the picture below, in my Simulink model. The input to this block represents a request from the user.
During simulation, everything works as expected—the output of the block matches the input correctly.
However, when I generate code for the target device and input the request via the target device's interface, I encounter an issue. I logged the signal before and after the Rate Transition block on the target device interface. Before the Rate Transition block, I observe the correct input value. However, after the Rate Transition block, the output signal always shows zero.
Could you help me understand why this might be happening and how to resolve this issue?
  1 件のコメント
Fangjun Jiang
Fangjun Jiang 2025 年 1 月 10 日
No other info is available to begin with. I suggest finding and showing the generated code for this block or its input and output signal.

サインインしてコメントする。

回答 (0 件)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by