Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5

Program Event or Function Call for 3D Printing Extruder Control

#1
亲爱的社区,

I'm trying to use RoboDK and a Kuka with KRC4 controller for 3D printing and I'm hoping to control both the Robot and the Extruder through RoboDK using the "Run on Robot" function.

My idea is to have three very similar function calls "SetRPM", "Extruder" and "MCode". SetRPM giving the F Value, Extruder the E Value of the G1 commands and MCode all the M commands of the G Code. The functions would then use TCP/IP over Ethernet to send these values as text string to a controller board for the extruder before sending the corresponding move to the robot and then continuing with the program.

I'm hoping that this way the error between the moves and extrusions is limited to one move at a time and therefore very small to avoid either the robot or extruder running faster than the other.
So far I have modified the post processor so it adds the lines SetRPM(ExtruderSpeed) and Extruder(PRINT_E_New) with the parameters in the brackets being the values for F and E. When I generate a program for the functions are being passed on to the robot program as you can see in the code example below at the end of the post.

My question is now, if I run this program through RoboDK on the robot can I use these lines to call functions or program events that will then send the corresponding code through a ethernet connection to the controlboard of the extruder? If so, do you know of any similar code snippets I could adapt the code from?

I have seen a lot of posts in the forum regarding 3D printing but none with this issue, is there perhaps a easier solution that I'm not aware of?

Best regards
Patrick


Code:
LIN {X 301.500,Y 498.500,Z 15.000,A 180.000,B 0.000,C -180.000} C_DIS
MCode(83)()
MCode(83)
$VEL.CP = 0.02500
SetRPM(0.000)
Extruder(-6.500)
LIN {X 301.500,Y 498.500,Z 15.000,A 180.000,B 0.000,C -180.000} C_DIS
MCode(107)()
MCode(107)
$VEL.CP = 0.06000
LIN {X 301.500,Y 498.500,Z 0.300,A 180.000,B 0.000,C 180.000} C_DIS
$VEL.CP = 0.02500
LIN {X 301.500,Y 498.500,Z 0.300,A 180.000,B 0.000,C 180.000} C_DIS
$VEL.CP = 0.03000
SetRPM(6000.000)
Extruder(73.713)
LIN {X 301.500,Y 301.500,Z 0.300,A 180.000,B 0.000,C -180.000} C_DIS


Messages In This Thread
Program Event or Function Call for 3D Printing Extruder Control - byPatrickC- 01-07-2020, 12:28 PM



Users browsing this thread:
2 Guest(s)