How to group same buses together over a MUX ?

6 ビュー (過去 30 日間)
Prashant Srivastava
Prashant Srivastava 2013 年 3 月 11 日
This is my Bus file :
%my_bus.m
cellarray = { ...
{ ...
'Status_Queue', ... % Bus Name
'status_queue.h', ... % Header File
'Queued Data', ... % Description
'Imported', {... % DataScope
{ 'Data_ID',1,'uint32',-1,'real','Sample','Fixed'} ; ...
{ 'Copy_ID',1,'uint8',-1,'real','Sample','Fixed'} ; ...
{ 'Data_X',1,'uint32',-1,'real','Sample','Fixed'} ; ...
{ 'Data_Y',1,'uint32',-1,'real','Sample','Fixed'} ; ...
} ...
}
{ ...
'Bus_Status_Queue', ... % Bus Name
'status_queue.h', ... % Header File
'Queued Data', ... % Description
'Imported', ... % DataScope
{...
{'Count', 1, 'uint8', -1, 'real', 'Sample', 'Fixed', [], [], sprintf(''), sprintf('Valid Messages.')}; ...
{'Data',5,'Bus: Status_Queue',-1,'real','Sample','Fixed'}; ...
} ...
}
};
Simulink.Bus.cellToObject(cellarray);
evalin('base','Status_unpackPtr = Simulink.Signal;');
evalin('base','Status_unpackPtr.RTWInfo.StorageClass = ''ImportedExternPointer'';');
The problem is, when I'm using MUX to group 5 different Status_Queue (which is a bus) for element 'Data' in Bus_Status_Queue, simulink throws an error stating it cannot group such signals. What is best way to group 5 Status_Queue and pass it to 'Data', using simulink blocks (not api/m-scripting) ?
Also will it be possible to resolve bus names to 5 different xyz_unpackPtr and then group them together ?
Any suggestion/help would be greatly appreciated. Thanks

採用された回答

Guy Rouleau
Guy Rouleau 2013 年 3 月 11 日

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeSources についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by