フィルターのクリア

FIFO push all values as vector

5 ビュー (過去 30 日間)
Tamar
Tamar 2023 年 7 月 11 日
コメント済み: Jon 2023 年 7 月 18 日
Hi, I want to pop the fifo every step time (1 sec) and push all the values as vector every 5 steps (5 sec). I didn’t find way to push more then one value every step time

採用された回答

Jon
Jon 2023 年 7 月 11 日
I assume you are using the Queue block in the DSP System Toolbox in Simulink.
If so you should supply the In port with a 5 element vector input, then supply the Push port with the output of Pulse Generator with 5 second period, and the Pop port with the output of a Pulse Generator with a 1 second period.
You may want to delay the start of popping until the buffer is full.
See my attached example
  20 件のコメント
Tamar
Tamar 2023 年 7 月 18 日
I tried to not use buffer. I did something and I think it worked. Thank you anyway, you help me a lot!!
Jon
Jon 2023 年 7 月 18 日
Hi Glad you found a solution. I and maybe others would be interested to see your approach without a buffer. Could you attach a simple model that demonstrates the idea.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeBuffers, Switches, and Counters についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by