- Hi, I'm new to this website and found some usefull informations regarding kuka programming.
- I'm using the robot kuka with krc2 6 axis + 2 external for deburring multiple workpices with 2 external rotary tables. At the present I have start button with loop and end loop to make my work easy when I have multiple same pieces.
- When I have other workpiece to deburr I need to get to the teachpendant to quit current program and get the other one and this takes some seconds.
- I have: Wait for start input (ex:1) green button next the command is run spindle and fan (out ex: 2:3) then run program lines (ex : prog ) when program ends spindle and fan (ex: out false) and then it enters in loop-endloop when the program stops at waits start input again.
- * I want to put one green button as input (ex: 1) next to the workpiece device and when it is ready to cut just that workpiece press the button once and robot chose program designated to that input and run it. Same for other 9 workpieces left in robot area. Is it possible?.
Kuka signal input assigned program lines
- smc
- Thread is Unresolved
-
-
smc
Changed the title of the thread from “Kuka signal assigned program lines” to “Kuka signal input assigned program lines”. -
you can use button to latch a bit.
in your program loop you can check if that bit is set. if so display dialog asking to "continue" or "end" program (or run one of other programs).
-
Hmm. Can you elaborate a little more?. A pure example of code?.
I have individual programs to deburr a workpiece that has integrated commands like: tool, base, home, loop, wait input (start), start spindle, start fan, program movements. stop spindle, stop fan, home, end loop.
I want to make a master primgram like a desired one would be like this kuka example for switch:
DEF MAIN()
…
SIGNAL PROG_NR $IN[1] TO $IN[4]
;The desired program number is now stored in the
…
;INT variable PROG_NO by the PLC
SWITCH PROG_NO
CASE 1
;if PROG_NO=1
PART_1()
CASE 2
;if PROG_NO=2
PART_2()
PART_2A()
CASE 3,4,5
;if PROG_NO=3, 4 or 5
$OUT[3]=TRUE
PART_345()
DEFAULT
;if PROG_NO<>1,2,3,4,5
ERROR_UP()
ENDSWITCH
…
END
I want to check input like a cycle (for example: 1-10) if 1 is meet then run program 1-10. If none of signals is meet (loop-endloop like command)
I have green button for momentary push in order to activat the signal so it will be set with pulse. Reffering to the kuka example. How can I make the already make programs that have names to integrat into code?.
-
For example, if you had a switch connected to physical input 0 the following code might be used.
IF $IN[33]==TRUE THEN
(I can use a call for a program but the problem is that when that program ends how can I get back here to check for input again?.)
the code written here would execute when the switch was on.
ELSE
the code written here would execute when the switch was off.
ENDIF
-
sorry but this is not clear. my guess is that you are using BCD switch and have following
input_0 : KUKA does not have this, inputs are numbered 1,2,3.... etc.input_1 to input_4 : 4-bit code from switches to select program to run
input_33 : another input to select program?? maybe need several inputs to specify number of cycles to run?
Code
Display MoreDEF MAIN() DECL INT Cycle SIGNAL PROG_CHOICE $IN[1] TO $IN[4] ; 4-bit code SIGNAL PROG_CYCLES $IN[5] TO $IN[8] ; 4-bit code SIGNAL START_BUTTON $IN[33] LOOP ; run forever WAIT FOR NOT START_BUTTON ; check if button is stuck WAIT FOR START_BUTTON ; wait for button press FOR Cycle = 1 TO PROG_CYCLES ; do 1-15 cycles as selected SWITCH PROG_CHOICE CASE 1 ;if PROG_NO=1 PART_1() CASE 2 ;if PROG_NO=2 PART_2() PART_2A() CASE 3,4,5 ;if PROG_NO=3, 4 or 5 $OUT[3]=TRUE PART_345() DEFAULT ;if PROG_NO<>1,2,3,4,5 ERROR_UP() ENDSWITCH ENDFOR ENDLOOP END
-
Hi, I'm using a kuka robot with phoenix interbus for signal input and output 24V version. Regarding program. I only wanna cycle a program once for each part.
What I want to achieve here with buttons is to not put a sensor underneath the device that holds the workpiece that needs to be deburr. There is too much dust and I want to press a button to each corresponding devices in the robot workspace to initiate the program. The program runs only once for each workpiece (multiple presses=multiple runs!).
The stupid simple commands that i want to achive are:
---
LOOP
IF $IN[6]==TRUE THEN;
PROG_NO=1; program_1 is executed
IF $IN[7]==TRUE THEN;
PROG_NO=2; program 2 is executed
ENDLOOP
END
---
I have another 10 inputs free from the robot to make this test. For the moment I want to try a simple 2 inputs for 2 workpieces that already have a green button.
My problem is with the code!. These signals I have just like the real thing
DEF MAIN()
DECL INT Cycle
SIGNAL PROG_CYCLES $IN[6] TO $IN[7] ; 4-bit code (6-7 to be used for test)
SIGNAL START_BUTTON $IN[2] ;
LOOP ; run forever
WAIT FOR $IN[6] ; workpiece 1, buttom press
WAIT FOR START_BUTTON ; wait for button press
FOR Cycle = 1 TO PROG_CYCLES ; do 1-15 cycles as selected
SWITCH PROG_CHOICE
CASE 1 ;if PROG_NO=1
PART_1A()
CASE 2 ;if PROG_NO=2
PART_2A()
PART_2B()
ENDSWITCH
ENDFOR
ENDLOOP
END
Create an account or sign in to comment
You need to be a member in order to leave a comment