Failing to open serial port in gps_demo

When I run gps_demo on a ConnectPort LTS 32 MEI, the program exits with the error:

#> python
Traceback (most recent call last):
  File "/usr2/pyscripts/", line 154, in 
    serialfd =, os.O_RDWR | os.O_NONBLOCK)
OSError: [Errno 2] No such file or directory: '/com/0'

The port is configured to use the RealPort profile.
What can be the problem?

Yes, I’m overwhelmed with all the responses.
What I’ve figured out (so far) is that I had to use /dev/ttyC0 for the first serial port name to get it working. I don’t know why and it isn’t documented anywhere.
I hope it helps!

I think you cannot open the serial port directly. I am pretty sure the LTS32 has 32 tasks which ALREADY own those ports. So you may need to use a TCP/IP socket on localhost (“”) to TCP port 2101 to 2132.

This doesn’t give you access to the control signals, but you can read/write the serial port via this.

(I haven’t written Python on the LTS, but I did have to port a Linux C++ program to it, and I was told to change all of the serial port access to TCP on localhost).