Cannot connect to serial [Linux]

2 visualizaciones (últimos 30 días)
igng
igng el 27 de Jul. de 2017
Respondida: Saurabh Gupta el 31 de Jul. de 2017
Hi, I cannot open any serial port to comunicate with my Arduino Micro.
instrhwinfo('serial')
ans =
HardwareInfo with properties:
AvailableSerialPorts: {0×1 cell}
JarFileVersion: 'Version 3.11'
ObjectConstructorName: {0×1 cell}
SerialPorts: {0×1 cell}
Access to your hardware may be provided by a support package. Go to the Support Package Installer to learn more.
I already tried using the java.opts file
-Dgnu.io.rxtx.SerialPorts=/dev/ttyS0:/dev/ttyS1:/dev/USB0:/dev/ttyACM0
I'm both in the uucp, dialout and lock group. Permissions on serial ports are
crw-rw---- 1 root uucp 166, 0 Jul 27 18:42 /dev/ttyACM0
crw-rw-rw- 1 root uucp 4, 64 Jul 27 14:26 /dev/ttyS0
crw-rw-rw- 1 root uucp 4, 65 Jul 27 14:26 /dev/ttyS1
crw-rw-rw- 1 root uucp 4, 66 Jul 27 14:26 /dev/ttyS2
crw-rw-rw- 1 root uucp 4, 67 Jul 27 14:26 /dev/ttyS3
crw-rw-rw- 1 root uucp 188, 0 Jul 27 18:40 /dev/ttyUSB0
Arduino is already plugged when MATLAB starts. If I click on the Support Package Installer link it does nothing. If I try to type the
supportPackageInstaller
command, it does nothing. I tried using all other answer provided here, but no one is working.
Am I missing something? Is there a way to fix this?
Of course, I can read data if I use
cat /dev/ttyUSB0
or using the Arduino IDE or Processing.
--------------
OS: Arch Linux (64 bit)

Respuestas (1)

Saurabh Gupta
Saurabh Gupta el 31 de Jul. de 2017
It looks like you are not able to launch Add-Ons Manager that is used to install and setup Support Packages. MATLAB needs the support package to be able to communicate with Arduino. I have included below the corresponding links so that you could try to manually download it.
Another point I want to mention is that MATLAB/Simulink is qualified with a limited number of Linux distributions, and unfortunately, Arch Linux is not one of them. So you may encounter some unexpected issues like these with MATLAB on Arch Linux.

Categorías

Más información sobre Setup and Configuration en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by