Jump to content

Welcome to eMastercam

Register now to participate in the forums, access the download area, buy Mastercam training materials, post processors and more. This message will be removed once you have signed in.

Use your display name or email address to sign in:

cncgotoguy

Verified Members
  • Posts

    31
  • Joined

  • Last visited

Everything posted by cncgotoguy

  1. I set up my Misc Values to have an entry for bubble number. (mi4$) When there is a value in there, I want to write it and other tool and operational values to the buffer file and output as txt file. I've gotten it to output farely well, but I put the pbufferfile post block I created right after psof$, ptlchg0$, ptlchg$. It doesn't put the correct operational info for the first operation and the depths are off by a count of 1. Could someone help me get on the right direction to getting this data to output correctly? This is what I have so far: size8 : 0 rc8 : 1 wc8 : 1 str8 : "" #Empty string to be input for buffer write fbuf 8 1 256 0 1 pbufferfile size8 = rbuf(8, 0) #Reading record zero initializes buffer str8 = drs_str(2, mi5$) + " | " + drs_str(2,g_wcs) + " | " drs_str(2, mi4$) + " | " + drs_str(2, t$) + " | " + strtool$ + " | " + drs_str(2, speed) + " | " + drs_str(2, feed) + " | " + drs_str(2,depth$) + " | " + snamenc$ + " | " + drs_str(2,g_wcs) + " | " + drs_str(2,zabs) + " | " + drs_str(2,zinc) + " | " + drs_str(2,depth$) + " | " + drs_str(2,tool_op$) + " | " + drs_str(2,op_id$) + " | " str8 = wbuf(8, wc8) Which gives me: OP#_100 | G0 | | T1 | 5/16 CARBIDE DRILL | S1000 | F0. | depth$ -3. | MASTERCAM DATA FOR IPIR PULL | G0 | Z0. | Z0. | depth$ -3. | tool_op$ 2. | op_id$ 1. | OP#_200 | G56 | | T2 | 1/2 CARBIDE DRILL | S7500 | F1. | depth$ -1. | MASTERCAM DATA FOR IPIR PULL | G56 | Z1. | Z-1.1 | depth$ -1. | tool_op$ 2. | op_id$ 2. | OP#_210 | G56 | | T2 | 1/2 CARBIDE DRILL | S7500 | F112.5 | depth$ -2. | MASTERCAM DATA FOR IPIR PULL | G56 | Z1. | Z-2.1 | depth$ -2. | tool_op$ 2. | op_id$ 3. | OP#_300 | G56 | | T3 | 2.2 MM DRILL | S4000 | F112.5 | depth$ -2.1 | MASTERCAM DATA FOR IPIR PULL | G56 | Z1. | Z-2.2 | depth$ -2.1 | tool_op$ 2. | op_id$ 4. |
  2. Thank you very much for the help. That solved my problem.
  3. I'm trying to output data into .txt file for use in our intranet system. I can pull most variables just fine, but some won't work. This is my code that works: size8 : 0 rc8 : 1 wc8 : 1 str8 : "" #empty string to be input for buffer write fbuf 8 1 256 0 0 size8 = rbuf(8,0) #reading record zero initializes buffer str8 = drs_str(2, mi4$) + " | " + drs_str(2, mi4$) + " | " + drs_str(2, Tool_var2) + " | " + drs_str(2, t$) + " | " + drs_str(2, speed) + " | " + drs_str(2, feed) + " | " str8 = wbuf(8, wc8) When I try to add drs_str(2, snamenc$) I get the error: (21 May 2015 09:47:11 AM - <2> - PST LINE (1007) - The arguments for this operator/function are not the same type (var/string)[9]) Could someone steer me towards getting the tool description to output to my buffer text file?
  4. Thanks so much, it got us started, but we were a little confused on what the following means: drs_str(2, t$) Also, how do you get the file name to automatically be named either the mastercam file name or some other variable of our choice? We try to put a variable in where the t$ is and it doesn't work. Is that just for integers, or can we put a string or variable in there? Each tool is going to have a description. How and where do we put the logic in the post to get this to capture and add lines in the buffer file?
  5. I have been trying to create a buffer file, but I haven't gotten it to work. The info in the MP post guide doesn't do a great job of explaining it. Do you have an example of the code to get it to work (create a text file)? In the text file, I want to output a miscellaneous integer and some other data along with the toolpath. End product is a text file that can be brought into a database to show us in our own form what toolpath parameters are for what feature on a part. The miscellaneous integer will correspond to the bubble number on the drawing. This way, we can tell what features are done with what tool, cycle, feed and speed, etc...
  6. I would like to create two files at the same time when posting. I want the .nc and I want a .txt file. The .txt file would have different information than the .nc file.

Join us!

eMastercam - your online source for all things Mastercam.

Together, we are the strongest Mastercam community on the web with over 56,000 members, and our online store offers a wide selection of training materials for all applications and skill levels.

Follow us

×
×
  • Create New...