Real-Time Filter
This example shows a real-time filter built using DSP System Toolbox™ and Simulink® Desktop Real-Time™. The unfiltered signal is acquired by the analog input, passed through a filter designed by DSP System Toolbox and finally sent to analog output. Both the unfiltered and filtered signals are shown in real-time using the Scope block.
Note: To run this model, you must have a data acquisition board connected to your computer. This model requires DSP System Toolbox.
Run Model in Connected IO Mode
Open the Analog Input and Analog Output blocks and select your data acquisition board. If there is no board installed, install it by clicking the Install new board button.
To switch to Connected IO mode if needed, on the Desktop Real-Time tab, select Mode > Connected IO.
To start the real-time execution, click Run in Real-Time.
Run Model in Run in Kernel Mode
Open the Analog Input and Analog Output blocks and select your data acquisition board. If there is no board installed, install it by clicking the Install new board button.
To switch to Run in Kernel mode if needed, on the Desktop Real-Time tab, select Mode > Run in Kernel.
To start the real-time execution, click Run in Real Time.
The model builds, connects to Simulink in Run in Kernel mode, and starts.
Open the Model
open_system('sldrtex_filter');
Close Open Scopes
close_system(find_system(gcs ,'BlockType', 'Scope'));
Clean Up Model
clear close all bdclose all