Cancel
Showing results for 
Search instead for 
Did you mean: 

Sinumerik 840D Python Parser Scripts

Valued Contributor
Valued Contributor

I am working on a project using Sinumerik 840D and I need to add the ability to parse FS1 as an address.  My plan was to modify the current files for the 840D, but I cannot find them.  In the installed_machines folder I can only find files for Fanuc, Okuma, and TNC.  Do the 840D files exist somewhere in the install or as a download?

 

Thank you,

Jesse

8 REPLIES

Re: Sinumerik 840D Python Parser Scripts

Siemens Phenom Siemens Phenom
Siemens Phenom
Hi Jesse,

the Sinumerik 840D is not (yet) available as Python based parser. The good news are that we are working on that.
Whats your exact requirement? Maybe a workaround could help you

Thomas

Re: Sinumerik 840D Python Parser Scripts

Valued Contributor
Valued Contributor
Hi Thomas,
I just need to be able to parse and control the address "FS1" as a rotary
unlimited axis. Is there a work around for that?

Re: Sinumerik 840D Python Parser Scripts

Solution Partner Phenom Solution Partner Phenom
Solution Partner Phenom

You can add FS1 subroutine and inside subroutine use any unused M or G codes to define command.

Re: Sinumerik 840D Python Parser Scripts

Valued Contributor
Valued Contributor

Hi Yuri!

 

I am not sure how to implement this.  I need to parse the FS1 while also defining the value.  So the G-code will have something like "FS1=600", which should set the milling spindle speed to 600 for the milling axis FS1.

 

I can call a subprogram with just "FS1" and put an unused M or G code in there like you said.  But if I call the "FS1=600" I get the error "left side of an assignment is not defined".

 

If I then create the variable FS1 and run the same code, I can see that the variable gets set to 600, but my subprogram doesn't get called.  Any thoughts here?

 

Thank you,

Jesse

Re: Sinumerik 840D Python Parser Scripts

Siemens Phenom Siemens Phenom
Siemens Phenom

Hi Jesse,

 

ok in this case i suggest to use the Sinumerik command DEFINE xx AS yy. This is a regular Sinumerik command to define alias names for any axis string.

https://support.industry.siemens.com/cs/mdm/109481532?c=70878298123&t=1&s=DEFINE&lc=en-WW

 

In this case it could be:

DEFINE FS1 AS S

 

I recommend to add the DEFINE to the machine ini file. So that the alias for FS1 is available with the initialization of the simulation.

 

Thomas

Re: Sinumerik 840D Python Parser Scripts

Solution Partner Phenom Solution Partner Phenom
Solution Partner Phenom
Thanks, Thomas. I try to solve this problem, I add to ini file DEF NCK REAL FS1 and I see after FS1=900 var FS1 become 900, but listener dont see this var..
A same if I define Siemens Command FS1, or address FS1

Re: Sinumerik 840D Python Parser Scripts

Siemens Phenom Siemens Phenom
Siemens Phenom
Hi Yuri,

you have to decide either you declare the variable in Machine Configurator or within the NC Code but not both. Defining FS1 as adress will not work because the parser creates a variable expression instead of a (needed) metacode expression.
As I already recommended simply use the DEFINE xx AS yy and it will work. Or going the complicated and time consuming way to define your own parser ;-)

Thomas

Re: Sinumerik 840D Python Parser Scripts

Valued Contributor
Valued Contributor

DEFINE, got it!  Thank you both for the help.

 

Cheers,

Jesse

Learn online





Solution Information