필터 지우기
필터 지우기

How to use the same arduino connection in two different apps?

조회 수: 3 (최근 30일)
Sean Dunkelman
Sean Dunkelman 2021년 8월 11일
답변: Amal Raj 2024년 6월 6일
I have an app that uses several object based connections, arduino being one of them. However, I need to open a second app in a callback of the main app and I need to use the existing object based connections (like arduino) in the newly opened app. Any ideas on how to do this?
I have already tried clearing the existing connections and reconnecting, but each time it tells me that the connection already exists in my workspace (despite the fact I just cleared it). I have also tried sharing data between the apps as output/input variables but am struggling to do so and could use a workaround.

답변 (1개)

Amal Raj
Amal Raj 2024년 6월 6일
Hi Sean,
Unfortunately, directly sharing a serial port connection between multiple MATLAB apps running simultaneously isn't recommended. Serial ports are designed for exclusive access by one application at a time.
You could however try one of the following approces.
  1. Single App with communication
  2. External Communication Server
  3. Multiple Serial Ports
  4. Alternative Communication Protocols
Hope this helps!!

카테고리

Help CenterFile Exchange에서 Develop Apps Using App Designer에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by