diff --git a/WiLabV2Xsim.m b/WiLabV2Xsim.m index 737cd65..2decced 100644 --- a/WiLabV2Xsim.m +++ b/WiLabV2Xsim.m @@ -1,4 +1,4 @@ -function WiLabV2Xsim(varargin) +function [outputValues, allParams] = WiLabV2Xsim(varargin) % The function WiLabV2Xsim() is the main function of the simulator % ============== @@ -77,6 +77,13 @@ function WiLabV2Xsim(varargin) % Update PHY structure with the ranges [phyParams] = deriveRanges(phyParams,simParams); +% Save all the params to return later +allParams = struct(); +allParams.simParams = simParams; +allParams.appParams = appParams; +allParams.phyParams = phyParams; +allParams.outParams = outParams; + % Simulator output inizialization outputValues = struct('computationTime',-1,... 'blockingRateCV2X',-1*ones(1,length(phyParams.Raw)),'blockingRate11p',-1*ones(1,length(phyParams.Raw)),'blockingRateTOT',-1*ones(1,length(phyParams.Raw)),...