How to extract the data from bus Selector in Simulink

15 次查看(过去 30 天)
Hey,
I am working with Gazebo and MATLAB/Simulink for my work. I am tryIng to get the values of Pose(Position and Orientation) using ROS Subscriber. I am trying to use the bus selector to get the values but getting an error mentioned below and in the attached picture as well. Kindly help me asap please.
Error: "Cannot propagate bus signal from 'Output Port 1' of 'untitled/Bus Selector' to 'Input Port 1' of 'untitled/Demux' because this input port requires a non-bus signal.
If the destination block is a bus-capable block, ensure that the block configuration and its input signal(s) meet the requirements for bus support. Please see Simulink documentation for further information on composite (i.e. bus) signals and their proper usage. Alternately, if the input bus signal is virtual; consists only of scalar elements, 1-D elements, or either row or column vectors; and all elements have the same data type, signal type, and sampling mode, consider inserting a Bus to Vector conversion block in the signal path. Otherwise, consider using a Bus Selector block in the signal path.
Component:Simulink | Category:Block error"

回答(1 个)

Jagadeesh Konakalla
Hi Shivam,
Please take a look at examples shipped with ROS Toolbox on how to access the ROS Messages in Simulink.
Thanks,
Jagadeesh K.

类别

Help CenterFile Exchange 中查找有关 ROS 2 Network Access in Simulink 的更多信息

产品


版本

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by