Borrar filtros
Borrar filtros

Can referenced models use frame-based processing?

2 visualizaciones (últimos 30 días)
Paul Nelson
Paul Nelson el 25 de Sept. de 2012
I'd like to create one sub-system (filter) that is copied to several channels, and only need to edit one filter. The most straightforward way that I see to do this is create a model, then reference it using the model block. I'm doing signal processing with frame-based signals. When I don't reference a model (a digital filter) the block diagram works fine. When the model is referenced via a model block, however, I get an error indicating that a block is expecting a sample based signal.
Do model blocks support frame-based processing? Or do I need to use buffer/unbuffer stages? If so, does buffering/unbuffering slow down my simulation substantially? Any guidance would be appreciated!

Respuestas (1)

Ryan G
Ryan G el 25 de Sept. de 2012
I tried this and had no issues, but I think the workflow is causing a hangup for you.
Try this:
1) Create the 'model' as a subsystem inside the main mdl file. Do not use the model block directly.
2) Make the subsystem atomic with -1 sample time. (do this in block parameters)
3) Right-click convert to model block.
This process will create a model block that carries over the parameters, sizes etc of the original model. It will keep thinks simpler, in my opinion. If you want to continue your workflow I believe you need to set the inports and outports of the model file that is being referenced to be frame-based instead of sample based.

Categorías

Más información sobre Component-Based Modeling en Help Center y File Exchange.

Productos

Community Treasure Hunt

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

Start Hunting!

Translated by