DEFINE <Program> Text Aliases questions

All things related to Centroid Oak, Allin1DC, MPU11 and Legacy products

Moderator: cnckeith

Post Reply
rjtechserv
Posts: 78
Joined: Sun Nov 18, 2018 7:22 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: Yes
Oak CNC controller: No
CNC Control System Serial Number: CNC12-m39-104028
DC3IOB: No
CNC12: Yes
CNC11: Yes
CPU10 or CPU7: No
Location: Western NY

DEFINE <Program> Text Aliases questions

Post by rjtechserv »

We've converted one of our production CNC machines from Siemens to Centroid and would like to see if we can figure out this Aliases feature.

Our production machine has several fixtures that we have a 3 proximity switch "bit" array we use to detect which fixture is in the machine and it runs the appropriate "Subprogram". If no sensor pickup the pattern file we want to run we run a "No_Program" routine to display a message and turn off off and open the doors etc..

I can likely change some logic around and will have to since there is no FOR function but, I'm trying to compare strings that should be contained within the Text Aliases. I get a "undefined variable" error on this. Tried lots of formats to compare these Strings; () [] == EQ

IF [<Subprogram>] == [<No_Program>] THEN GOTO 100 ELSE GOTO 9000

Thanks,

RobJ
Attachments
Undefined Variable.png
Text Aliases.txt
(5.35 KiB) Downloaded 1 time
Text Aliases.png
Rob Jackson

RJ Technical Services


cncsnw
Community Expert
Posts: 4541
Joined: Wed Mar 24, 2010 5:48 pm

Re: DEFINE <Program> Text Aliases questions

Post by cncsnw »

I think the comparison operators (such as ==) only work with numeric variables, not with string variables.

Can you restructure your code to use program numbers instead of names?

For example:

Code: Select all

M98 P1234
will run the program file O1234.cnc as a subprogram.


Post Reply