function [outData] = commBSCTransform(inData)
%commBSCTransform Transform function for Binary Symmetric Channel R2018a to
%R2018b

% Copyright 2018 The MathWorks, Inc.

%#ok<*AGROW>
InstanceData = inData.InstanceData;
oldBlockParams = {InstanceData.Name};

for p=1:length(oldBlockParams)
  switch oldBlockParams{p}
    case 'P'
      newInstanceData(p) = struct( ...
        'Name',  'ErrorProbability', ...
        'Value', InstanceData(p).Value);
    case 's'
      newInstanceData(p) = struct( ...
        'Name',  'Seed', ...
        'Value', InstanceData(p).Value);
    case 'E'
      newInstanceData(p) = struct( ...
        'Name',  'ErrorVectorOutputPort', ...
        'Value', InstanceData(p).Value);
    case 'outDtype'
      newInstanceData(p) = struct( ...
        'Name',  'OutputDataTypeSL', ...
        'Value', InstanceData(p).Value);
    otherwise
      newInstanceData(p) = InstanceData(p);
  end
end

outData.NewBlockPath = '';
outData.NewInstanceData = newInstanceData;
