T word question (v2.117)

If you have a question about the software please ask it here.

T word question (v2.117)

Postby CNC22369 » Wed Nov 13, 2024 2:58 pm

I'm updating my M6 error checking code and have a question about how T word / newtool = exec.Getnewtool() work. After some experimenting, I found that if you start UCCNC and load a program without a T word (or without an integer with the T) prior to or on the same line as a M6, and start execution, newtool = -1 (that I believe indicates an error). If you start UCCNC and load a program with a valid T word like T2, and start execution, newtool = 2 just as expected. Now if you leave UCCNC running and load a new program without a T word, and start execution, newtool = 2 rather than -1. It seems UCCNC holds the prior program's T number when a new program is loaded and thus does not recognize that a needed T word is missing when the newly loaded program runs. So, my question is, shouldn't UCCNC reset its internal newtool value when a new program loads?

I realize this is probably an unusual situation, but for error checking purposes I'm looking for consistent results when a T word is missing from a program for some reason. And there are various issues that can come up during the M6 process if the missing T word is not caught at the outset.

Running 2.117 in demo mode. I haven't tested any other version.

Thank you, Frank
CNC22369
 
Posts: 35
Joined: Mon Sep 19, 2016 4:05 pm

Re: T word question (v2.117)

Postby sebba » Wed Nov 13, 2024 4:58 pm

IMHO, the best way is to have a good post processor, and not only for M6 Tx commands.
- YQWQ
User avatar
sebba
 
Posts: 52
Joined: Mon Dec 21, 2020 9:56 am
Location: Bucharest, ROMANIA


Return to Ask a question from support here

Who is online

Users browsing this forum: No registered users and 11 guests