DSP System Toolbox™ provides algorithms, apps, and scopes for designing, simulating, and analyzing signal processing systems in MATLAB® and Simulink®. You can model real-time DSP systems for communications, radar, audio, medical devices, IoT, and other applications.
With DSP System Toolbox you can design and analyze FIR, IIR, multirate, multistage, and adaptive filters. You can stream signals from variables, data files, and network devices for system development and verification. The Time Scope, Spectrum Analyzer, and Logic Analyzer let you dynamically visualize and measure streaming signals. For desktop prototyping and deployment to embedded processors, including ARM® Cortex® architectures, the system toolbox supports C/C++ code generation. It also supports bit-accurate fixed-point modeling and HDL code generation from filters and other algorithms.
Algorithms are available as MATLAB functions, System objects™, and Simulink blocks.
Get Started:
- Signal Processing and Linear Algebra Blocks for Simulink
- Streaming Signal Processing in MATLAB
- Single-Rate and Multirate FIR and IIR Filter Design, and Adaptive Filters
- Signal Scopes, Analyzers, and Measurements
- Fixed-Point Modeling and Simulation
- C and C++ Code Generation for Desktop and Embedded Workflows
- HDL Code Generation for FPGA and ASIC Development
In Simulink, DSP System Toolbox™ offers a library of signal processing algorithm blocks for filters, transforms, and linear algebra. These blocks process streaming input signals as individual samples or as collections of samples called frames. Sample-based processing enables low-latency processes and applications that require scalar processing. Frame-based processing enables higher throughput in exchange for latency. The system toolbox supports both sample-based and frame-based processing modes.
MATLAB programs that use System objects can be incorporated into Simulink models through either the MATLAB Function block or the MATLAB System block. Most of the System objects have corresponding Simulink blocks with the same capabilities.
Signal Processing Blocks for DSP System Design, Implementation, and Validation
Simulink blocks for signal processing support double-precision and single-precision floating-point data types and integer data types. They also support fixed-point data types when used with Fixed-Point Designer.
The signal processing blocks in DSP System Toolbox include:
- Signal transforms such as fast Fourier transform (FFT), discrete cosine transform (DCT) short-time Fourier transform (STFT), and discrete wavelet transform (DWT)
- Filter design and implementation of FIR, IIR, and analog filters
- Multirate and multistage filters for sample-rate conversion such as CIC, Halfband, Polyphase, and Farrow
- Statistical and adaptive signal processing techniques for spectral estimation, equalization, and noise suppression
- Signal operations and measurement such as convolution, windowing, padding, delays, peak finding, and zero-crossing
- Streaming signal visualization and measurements with Time Scope, Spectrum Analyzer, and more
- Signal management methods such as buffering, indexing, switching, stacking, and queuing
- Sinks and sources such as chirp and colored noise generators, NCO, UDP receiver and transmitter, and more
- Numerical linear algebra routines, including linear system solvers, matrix factorizations, and matrix inverses
Modeling Multirate Systems
In MATLAB, DSP System Toolbox supports multirate processing for sample-rate conversion and the modeling of systems in which different sample rates or clock rates need to be interfaced. Multirate functionality includes multistage and multirate filters such as FIR and IIR halfband, Polyphase filters, CIC filters, and Farrow filters. It also includes signal operations such as interpolation, decimation, and arbitrary sample-rate conversion.
DSP System Toolbox provides a framework for processing streaming signals in MATLAB. The system toolbox includes a library of signal processing algorithms optimized for processing streaming signals such as single-rate and multirate filters, adaptive filtering, and FFTs. The system toolbox is ideal for designing, simulating, and deploying signal processing solutions for applications including audio, biomedical, communications, control, seismic, sensors, and speech.
Streaming signal processing techniques enable processing of continuously flowing data streams, which can often accelerate simulations by dividing input data into frames and processing each frame as it is acquired. For example, streaming signal processing in MATLAB enables real-time processing of multichannel audio.
Streaming signal processing is enabled using a library of DSP algorithm components called System objects™ to represent data-driven algorithms, sources, and sinks. System objects enable you to create streaming applications by automating tasks such as data indexing, buffering, and algorithm state management. You can mix MATLAB System objects with standard MATLAB functions and operators.
You can use the Time Scope and Spectrum Analyzer to visualize and measure streaming signals.
You can apply single-rate, multirate, and adaptive filters to streaming data using algorithms optimized for streaming signals and data.
Algorithm Library for DSP System Design, Implementation, and Testing
DSP System Toolbox provides more than 350 algorithms optimized for design, implementation, and validation of streaming systems—whether implemented as MATLAB functions or as MATLAB System objects. The algorithms support double-precision and single-precision floating-point data types. Most of the algorithms also support integer data types, as well as fixed-point data types that require Fixed-Point Designer™.
In MATLAB, the system toolbox algorithm categories include:
- Signal transforms such as fast Fourier transform (FFT) and discrete cosine transform (DCT)
- Design and implementation techniques for digital FIR and IIR filters
- Multirate and multistage filters for sample-rate conversion such as FIR and IIR halfband, Polyphase filters, CIC filters, and Farrow filters
- Statistical and adaptive signal processing techniques for spectral estimation, equalization, and noise suppression
- Signal operations and measurement such as convolution, windowing, padding, modeling delays, peak finding, and variable fractional delays
- Signal visualization at run time with Time Scope, Spectrum Analyzer, and Logic Analyzer
Multirate Systems
In MATLAB, DSP System Toolbox supports multirate processing for sample-rate conversion and the modeling of systems in which different sample rates or clock rates need to be interfaced. Multirate functionality includes multistage and multirate filters such as FIR and IIR halfband, Polyphase filters, CIC filters, and Farrow filters. It also includes signal operations such as interpolation, decimation, and arbitrary sample-rate conversion.
DSP System Toolbox provides extensive filter design and implementation algorithms for FIR, IIR, multistage, multirate, and adaptive filters. You can design filters with lowpass, highpass, bandpass, bandstop, and other response types. You can realize them using filter structures such as direct-form FIR, overlap-add FIR, IIR second-order sections (Biquad), cascade allpass, and lattice structures.
You can design filters using the Filterbuilder app, MATLAB code, or Simulink blocks. Also, you can analyze fixed-point quantization effects for FIR and IIR filters and determine the optimal word length for the filter coefficients.
You can also design tunable filters where you can tune key filter parameters, such as bandwidth and gain, at run time.
The digital filters you design with DSP System Toolbox in MATLAB can also be used in system-level models in Simulink. There is a ready-to-use library of filter blocks in the system toolbox for designing, simulating, and implementing lowpass, highpass, and other filters directly in Simulink.
In addition to conventional FIR and IIR filter design algorithms, DSP System Toolbox supports specialized filters and design methods such as:
- Advanced equiripple FIR filters including minimum-order, constrained-ripple, and minimum-phase designs
- Nyquist, FIR halfband, and IIR polyphase filters, providing linear phase, minimum-phase, and quasi-linear phase halfband designs, as well as equiripple, sloped-stopband, and window methods
- CIC interpolator and decimator filters for multiplier-less implementation in software-defined-radio and sigma-delta converters
- Optimized multistage designs, enabling you to optimize the number of cascaded stages to achieve the lowest computational complexity
- Fractional-delay filters, including implementation using Farrow filter structures well suited for tunable filtering applications
- Allpass IIR filters with arbitrary group delay, enabling you to compensate for the group delays of other IIR filters to obtain an approximate linear phase passband response
- Lattice wave digital IIR filters for robust implementation
- Arbitrary magnitude and phase FIR and IIR filters, enabling design of any filter specification
Adaptive Filters
DSP System Toolbox provides several techniques for adaptive filtering in MATLAB and Simulink. These techniques are widely used for applications such as system identification, spectral estimation, equalization, and noise suppression. Such adaptive filters include LMS-based, RLS-based, affine projection, fast transversal, frequency-domain, lattice-based, and Kalman. The system toolbox includes algorithms for the analysis of these adaptive filters, including tracking of coefficients, learning curves, and convergence.
Multirate and Multistage Filters and Analysis
DSP System Toolbox provides design and implementation of multirate filters, including Polyphase interpolators, decimators, sample-rate converters, FIR halfband and IIR halfband, Farrow filters, and CIC filters and compensators, as well as support for multistage design methods. The system toolbox also provides specialized analysis functions to estimate the computational complexity of multirate and multistage filters.
DSP System Toolbox provides scopes and data logging for time-domain or frequency-domain visualization, measurements, and analysis of streaming signals in MATLAB and Simulink. The scopes come with measurements and statistics familiar to users of industry-standard oscilloscopes and spectrum analyzers.
The system toolbox also provides the Logic Analyzer for displaying the transitions in time-domain signals, which is helpful in debugging models targeted toward HDL implementation.
You can also create an arbitrary plot for visualizing data vectors, such as the evolution of filter coefficients over time.
Time Scope displays signals in the time domain and supports a variety of signals—continuous, discrete, fixed-size, variable-size, floating-point data, fixed-point data, and N-dimensional signals for multichannel I/O system. Time Scope lets you display multiple signals either on the same axis where each input signal has different dimensions, sample rates, and data types, or on multiple channels of data on different displays in the scope window. Time Scope performs analysis, measurement, and statistics including root-mean-square (RMS), peak-to-peak, mean, and median.
Spectrum Analyzer computes the frequency spectrum of a variety of input signals and displays its frequency spectrum on either a linear scale or a log scale. Spectrum Analyzer performs measurements and analysis such as harmonic distortion measurements (THD, SNR, SINAD, SFDR), third-order intermodulation distortion measurements (TOI), adjacent channel power ratio measurements (ACPR), complementary cumulative distribution function (CCDF), and peak-to-average power ratio (PAPR). The spectrogram mode view of Spectrum Analyzer shows how to view time-varying spectra and allows automatic peak detection.
DSP System Toolbox provides an additional family of visualization tools you can use to display and measure a variety of signals or data, including real-valued or complex-valued data, vectors, arrays, and frames of any data type including fixed-point, double-precision, or user-defined data input sequence. Some of the visualization tools can show a 3D display of your streaming data or signals so that you can analyze your data over time until your simulation stops.
You can use DSP System Toolbox with Fixed-Point Designer to model fixed-point signal processing algorithms, as well as to analyze the effects of quantization on system behavior and performance. You can also generate fixed-point C code from your MATLAB code or Simulink model.
You can configure MATLAB System objects and Simulink blocks in the system toolbox for fixed-point modes of operation, enabling you to perform design tradeoff analyses and optimization by running simulations with different word lengths, scaling, overflow handling, and rounding method choices before you commit to hardware.
Fixed-point modes are supported for many DSP algorithms, including FFT, filters, statistics, and linear algebra. DSP System Toolbox automates the configuration of System objects and blocks for fixed-point operation.
Fixed-Point Filter Design
In DSP System Toolbox, filter design functions and the Filterbuilder app enable you to design floating-point filters that can be converted to fixed-point data types with Fixed-Point Designer. This design flow simplifies the design and optimization of fixed-point filters and lets you analyze quantization effects.
Using DSP System Toolbox with MATLAB Coder™ and Simulink Coder™, you can generate C and C++ source code or a MEX function tuned for performance from your signal processing algorithms and system models in MATLAB and Simulink, respectively.
The generated code can be used for acceleration, rapid prototyping, implementation and deployment, or for the integration of your system during the product development process.
Desktop Acceleration
You can generate efficient and compact executable code, a MEX function, tuned for performance to speed up computation-intensive algorithms in your simulation. You can accelerate your floating-point and fixed-point algorithms including filters, FFTs, statistics, and linear algebra in MATLAB and Simulink.
To accelerate frame-based streaming simulations, dspunfold uses DSP unfolding to distribute the computational load in the generated MEX function across multiple threads.
Standalone Execution and Integration with Other Environments
With DSP System Toolbox, you can also use the generated C code from your MATLAB code or Simulink model for deployment and prototyping on the desktop by generating a standalone executable of your algorithm. This standalone executable can still be tuned directly from within MATLAB or Simulink in real time by using the UDP components. Because this standalone executable runs on a different thread than the MATLAB code or Simulink model, it improves the real-time performance of your algorithm.
The generated C code of your signal processing algorithms can be integrated as a compiled library component into other software, such as a custom simulator, or standard modeling software such as SystemC.
Optimized C Code Generation for ARM Cortext Processors
Using DSP System Toolbox with the hardware support add-on for ARM Cortex-A or ARM Cortex-M and Embedded Coder® you can generate optimized C code from MATLAB System objects or Simulink blocks for key DSP algorithms, such as FFT, FIR, and Biquad filters. The generated code provides calls to optimized routines for either the ARM Cortex-A Ne10 library or the ARM Cortex-M CMSIS library. A key benefit is an immediate increase in performance when compared to standard C code. You can also perform code verification and profiling using processor-in-the-loop (PIL) testing.
Using DSP System Toolbox with Filter Design HDL Coder™ in MATLAB, you can design digital filters and generate efficient, synthesizable, and portable VHDL® and Verilog® code for implementation in FPGAs or ASICs. You can also automatically create VHDL and Verilog test benches for simulating, testing, and verifying generated code.
Using DSP System Toolbox with HDL Coder™ provides synthesizable and readable VHDL and Verilog code generation for your system design. For optimized FPGA/ASIC resource usage and performance, consider using blocks from DSP HDL Toolbox.