How to force MultiWiiConf read from certain serial?

This forum is dedicated to all issues and questions related to your individual setups and configurations
Post Reply
cossack
Posts: 36
Joined: Tue Jul 22, 2014 5:17 pm

How to force MultiWiiConf read from certain serial?

Post by cossack »

I create serial link with following script

Code: Select all

#!/bin/bash

uid=`id -u $USERNAME`
if [ "$USER" = "root" ]
then
   USER2=$SUDO_USER
   socat PTY,link=/dev/ttyVirtual1 PTY,link=/dev/ttyVirtual2&
   sleep 1
   chown $USER2:dialout /dev/ttyVirtual1
   chown $USER2:dialout /dev/ttyVirtual2
   echo "Created ports, set ownership to user $USER2"
   echo "Connect to /dev/ttyVirtual1 and /dev/ttyVirtual2"
else
   echo "RUN WITH SUDO!"
fi



ls -l /dev/tty*

Code: Select all

crw-rw---- 1 root dialout   4, 72 Mar 21 10:38 /dev/ttyS8
crw-rw---- 1 root dialout   4, 73 Mar 21 10:38 /dev/ttyS9
crw-rw---- 1 root dialout 188,  0 Mar 21 12:59 /dev/ttyUSB0
lrwxrwxrwx 1 root root         11 Mar 21 12:56 /dev/ttyVirtual1 -> /dev/pts/34
lrwxrwxrwx 1 root root         11 Mar 21 12:56 /dev/ttyVirtual2 -> /dev/pts/35


Code: Select all

ls -l /dev/pts/34
crw--w---- 1 user dialout 136, 34 Mar 21 12:56 /dev/pts/34



I set /dev/ttyVirtual1 or /dev/pts/34 in SerialPort.txt but MultiWiiConf does not see it. I also tried to run MultiWiiConf as root.

anyway I am in dialout group and should be able to read that port.

User avatar
stronnag
Posts: 114
Joined: Thu Oct 24, 2013 9:32 pm
Location: New Forest, England
Contact:

Re: How to force MultiWiiConf read from certain serial?

Post by stronnag »

You can try setting the java gnu.io.rxtx.SerialPorts variable, e.g.

Code: Select all

$ java -Dgnu.io.rxtx.SerialPorts="/dev/ttyACM0:/dev/ttyUSB0:/dev/rfcomm1:/dev/rfcomm2" ... rest of command line ...

only with your specific ports.

cossack
Posts: 36
Joined: Tue Jul 22, 2014 5:17 pm

Re: How to force MultiWiiConf read from certain serial?

Post by cossack »

Thank You! It worked

Post Reply