- Have you tried this example before? Are you able to see the same output as shown on the example?
- What is the ErrorCode it returned from the block output port?
- If you create and start a ros2svcserver in MATLAB, are you able to get the result in Simulink?
- Does the domain id matches with the domain id the service server in? You can check the ROS 2 Domain ID for your model under SIMULATION->PREPARE->ROS Network.
Questions about ros2 call service blocks in simulink
    조회 수: 4 (최근 30일)
  
       이전 댓글 표시
    
Hello!
I'm using a ros2 call service block to call a service named "load_track". While debugging I can't receive anything from the server.
But if I use matlab function(.m file) and follow the instructions in the https://www.mathworks.com/help/ros/ref/ros2serviceserver.html, the server can normally receive the srvice request.
Could you please have a look, and see where could be the problem?
Thanks a lot! 
The simulink screenshot is in the appendix.


댓글 수: 0
답변 (1개)
  Josh Chen
    
 2022년 4월 28일
        Hello Xiaochen,
It is difficult to figure out the culprit from the screenshot of the model. However, I do have some troubleshooting suggestions that you may want to give it a try:
If the above ideas still can't resolve this issue, I would recommend you to reach out to MathWorks Technical Support and share a sample model/workflow for a closer look.
Hope this helps,
Thanks,
Josh
댓글 수: 0
참고 항목
카테고리
				Help Center 및 File Exchange에서 Network Connection and Exploration에 대해 자세히 알아보기
			
	제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

