Загрузка страницы

PC-DMIS Variables and the Print Command | CMM Tech Tips - CMMXYZ

This Tech Tip Video from Canadian Measurement – Metrology shows how to generate multiple reports from a single program execution. This is useful when inspecting moulds with multiple cavities, or when 2 different reports are required: one for your customer and one for internal purposes.

Hello, and welcome back to my PC-DMIS tech tip tutorial series.

In this tutorial, I wanted to share an interesting programming challenge I faced back in the days when I made my living as a mold maker. I was asked if I was able to write one CMM program that could create and save individual reports for each cavity on a multi-cavity mold and, also, to have them stored in such a way as to identify both the mold number and the cavity number and the file name.

Well, I love a challenge. So after much trial and error, I was able to come up with a solution that I hope you find both interesting and useful.

To achieve this, we need to employ three different PC-DMIS tools, assigning variables, the input comments, and the print command. Okay. So let's get started.

So I'll keep this folder open on the side, showing the file names for reference. And I'll just start programming.

So let's do our first assignment. So assign a variable, the letter M, and in quotations, MOLD_.

Next, I'll do an input comment, prompting the operator to enter the mold number.

Another assignment, we can also use the menu bar, Insert, Assignment. So the Assign To, I will make the letter C. Assign From, this is the value, _CAVITY_"". So again, I'll explain all of this when I'm done.

Another assignment, we'll just type it in, hit the tab key. So CM. We'll assign a value of 1. And this will be the cavity number.

The final assignment is REPORT NAME.

Okay, excellent, so we're done. Let's break it down.

The key to all of this is that last variable, which I called report name. So within those quotations, we have both a file path, where we will store these files, which folder, C:USERS\INSPECTION REPORTS. I've decided that ahead of time. And then I have the double backslash. That's important here because it proceeds another quotation and another string value. So each one of those names are the name of a variable that I've specified what I want to put in there, and that is the value. For example, MOLD_ will be placed where the M is. The names are constant, but the values can change, which I'll show you later with CN, cavity number. So I'll change that later as I do my programming.

Okay, so let's go on to the next step. The next step is just our regular programming. So I'll just simulate programming each one of the six cavities. And I'll just do any type of feature, like an auto circle. Give it a name, CAVITY 1, and Create, and Close.

So we'll need a dimension as well, so I'll just do a simple location dimension on that.

Okay, so the next tool we need to use is the print command. I think you'll find this a very useful and powerful tool, as you'll see in a minute. Print command is found in the menu bar, under Insert, Report Command, and Print Command. There it is. Let's give it a click.

Okay, so let's start editing our print command. You can do that all within the edit window. I'll put my cursor here at the beginning, hit the Tab key. And we don't want print TO_FILE=OFF, we want that ON. So we'll just take the word ON, so we're now print to file. I don't want AUTO. What I want is OVERWRITE. Just start typing that. Hit the Tab key again. And you can see this path is the default path where our prior program is stored. So let's change that. And here, I want to plug in my variable called REPORT NAME. And hit the Tab key.

About Canadian Measurement-Metrology Inc.
CMM is North America's foremost independent measurement solutions provider. We sell new and used coordinate measuring machines, provide measuring services, upgrade and repair your systems.

Canadian Measurement Metrology - Coordinate Measuring Machines - http://www.cmmxyz.com/
Follow us on Facebook - https://www.facebook.com/pages/CMM-Equipment-and-Measurement-Services/186252594728224
Get the latest on Twitter - https://twitter.com/CMMxyz
Follow CMM Inc. on LinkedIn - http://www.linkedin.com/company/canadian-measurement---metrology-inc.
Learn more about CMM on our blog - http://www.cmmxyz.com/new-reviews
Subscribe to our Youtube Channel - https://www.youtube.com/user/CMMXYZvideo/

Видео PC-DMIS Variables and the Print Command | CMM Tech Tips - CMMXYZ канала CMMXYZ
Показать
Комментарии отсутствуют
Введите заголовок:

Введите адрес ссылки:

Введите адрес видео с YouTube:

Зарегистрируйтесь или войдите с
Информация о видео
18 сентября 2015 г. 18:19:28
00:07:20
Яндекс.Метрика