Simulink DSP Simulations with Noise: Looking for best practices
2 views (last 30 days)
I have a nice task at hand to be implemented with matlab and simulink and i am looking for some tipps and best practices to make my live a little more easy, and avoid ending up with a messy set of code and models. (In fact, thats what I did first, now I want to make it cleaner, in order to get rid of the headaches this gives me.)
I want to simulate different DSP components to test their useability in a given system.
Lets start with the input generation, I have a signal that is paramterized and a parameter set on which to evaluate it.
Picture Amplitudes ranging from 0 to 500 and widths ranging from 1ns to 100 us. So I need to pick from these ranges a set of values, like 10 to 100 values of each and simulate all combinations of those.
Then I have noise with different possible RMS values, where I would need to also use 5 to 50 test cases.
And then my models also have a set of parameters to be tested, typical is always the ADC sampling used and the ADC Bit resolution, but it might also be thresholds or correction parameters.
And then, as the simulations involve random noise, we need to repeat each combination of parameters at least 100 times.
The load of simulations could be reduced by reducing the set of input parametersm eg it makes no sense simulating, when the signal width is smaller than the ADC sampling time.
In my first development approach I realized that having a set of pregenerated signals for all parameters is not feasible due to limited RAM.
I opted for nested loops where I just loop over all Model Parameters, all Signal Parameters and all Noise values and in every loop itteration setup a single simulation and run it. This has the benefit that I can alsodirectly reduce the simulation output, to save more RAM there.
Simulation outputs are usualy estimators for the input parameters of my signal (Amplitude, Time Width) and come with an acompanying VALID signal, so that I do not need to store the whole output time series.
In the end I want to see how the different parameters influence the performance of my DSP blocks, eg how many bits resolution do I need to achieve a certain amplitude resolution.
So storing the outputs in a usefull manner is also important.
The end goal is to convert the best approaches to HDL.
If you cam down here without screaming, thank you very much already. Do you maybe have tipps for me?
I am glad for every help, be it usefull links for stuff i could read on this, or direct advise.