Forum

Welcome Guest 

Show/Hide Header

Welcome Guest, posting in this forum requires registration.





Pages: [1]
Author Topic: Unable to select serial port from list on Linux
sarah
Newbie
Posts: 2
Permalink
Post Unable to select serial port from list on Linux
on: January 8, 2016, 01:49
Quote

Is there a way to manually input which serial port to use?
In the serial port box under the setup tab I have a huge list of ports. (/dev/ttys0 - ttys31 and ttyUSB0) I can only select the first 10 or so, clicking on any port after that simply does not result in a checked box. The port I need (ttyUSB0) is at the bottom of the list. It's beyond me why there are so many ports listed when I only have 3 USB ports.
Cheers.

sandy
Administrator
Posts: 1203
Permalink
sandy
Post Re: Unable to select serial port from list on Linux
on: January 8, 2016, 08:58
Quote

Some machines have a lot of virtual devices installed - bluetooth is often a culprit here. Doesn't do any harm, but it's a bit confusing. And as you've seen the dialog box doesn't cope very well with it. I'm not sure why though. I'll try to have a look at that over the weekend. There's one other fix I want release soon too.

There's a file called default.properties.txt that appears in your polagraphcontroller folder, and you can open that in a text editor and find the line that starts with

controller.machine.serialport=

The value that it's set to controls which serial port to connect to, but the number is actually that port's position in the list, rather than being the name of the port. So if you have 15 serial ports, and you want the last one, then you could manually enter

controller.machine.serialport=14

(14 rather than 15 because it's a zero-indexed list, that is, the first serial port is port number 0, the second is port number 1 etc). Save the file and restart the controller.

good luck,
sn

sarah
Newbie
Posts: 2
Permalink
Post Re: Unable to select serial port from list on Linux
on: January 8, 2016, 10:03
Quote

This combined with disabling Bluetooth at startup worked perfectly.
Thanks for the detailed and speedy reply, much appreciated.

mskogly
Beginner
Posts: 26
Permalink
Post Re: Unable to select serial port from list on Linux
on: March 10, 2017, 18:42
Quote

I've been knocking my head against this one as well, will test disabling bluetooth to see if it solves it.

mnom
Newbie
Posts: 1
Permalink
Post Re: Unable to select serial port from list on Linux
on: April 16, 2017, 23:04
Quote

Editing default settings does not help:

About to connect to serial port in slot 32
Get serial port no: 32
Successfully connected to port /dev/ttyUSB0
Error, disabling serialEvent() for /dev/ttyUSB0

null

There is still "No serial connection" in the controller GUI.

However, there is a hacky solution!

Before running Polargraphcontroller from source, edit file SerialPortWindow.pde

for (int i = 28; i < ports.length; i++) {
println("Adding " + ports[i]);
r.addItem(ports[i], i);
}

This 28 instead of 0 just skips first 28 serial ports of my Linux, so I can choose ttyUSB0.

https://github.com/euphy/polargraphcontroller/issues/14

Pages: [1]
Mingle Forum by cartpauj
Version: 1.0.34 ; Page loaded in: 0.1 seconds.