Author Topic: t2x Error  (Read 25132 times)

avsfan92

  • Newbie
  • *
  • Posts: 6
  • Karma: +0/-0
t2x Error
« on: June 18, 2025, 05:04:46 PM »
Hello,

I have come across an error and I am not sure if anybody else has experienced it. When I try to use t2x -c, I get the error message "Sorry, there is no coord- or control-file!". Despite there being both a coord file and control file in the working directory. I am doing this after an aoforce calculation timed out, so I am wondering if that could be why it does not work? I have had no issues with t2x -c in the past, nor with t2x, and neither are working currently.
What files does t2x read from?

Thank you.

uwe

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 612
  • Karma: +0/-0
Re: t2x Error
« Reply #1 on: June 19, 2025, 12:13:24 AM »
t2x -c uses the coordinates from the $coord section of control and in most cases this is a reference to the coord file, so actually the coord file itself is used:

$coord file=coord

If control and coord look OK, then my guess is that your control file stems from a Windows machine while t2x is running under Linux or WSL or cygwin. If the control file has DOS format, the Linux script sees:

$coord file=coord^M

with the ^M as the carriage-return character which Windows adds for each line break - and Linux not. So Linux looks for a file named coord^M and does not find it, as the name is just coord without the carriage-return.

Most editors under Linux recognize DOS format and will not show ^M. But file shows what format it is:

>file control
control: ASCII text, with CRLF line terminators


run dos2unix * to get rid of the Windows text file format, then you should get:

>file control
control: ASCII text


Afterwards t2x should work as expected.



avsfan92

  • Newbie
  • *
  • Posts: 6
  • Karma: +0/-0
Re: t2x Error
« Reply #2 on: June 23, 2025, 05:01:52 PM »
Thank you, Uwe!