Using c – Yaskawa MotionWorks IEC User Manual

Page 369

Advertising
background image

PLCopenPlus Function Blocks for Motion Control 2013-04-13

361

Browse to the desired directory, select the cam file, and press the
“Download” button. This places the file /flash/procon/any directory on the
controller. This is the default directory for the Y_CamFileSelect function
block, so any cam file downloaded with this procedure can be selected
simply by using the file name in a string without referencing the directory.

Using C#

Cam files can be downloaded to the controller programmatically using a
C# API that sends a file via an HTTP POST. While programming within C#,
the key steps are:

1. Create a Yaskawa.IEC61131.RMI.Modules.Controller object.

2. Connect to the controller using Controller.Connect()

3. Access Yaskawa.IEC61131.RMI.Modules.IConfigUtility via the
Controller object

4. Call IConfigUtility.UploadFileToUserDirectory()

MotionWorks IEC Programming After Files Have Been Sent

The Y_CamFileSelect function block can access files in the
/flash/user/data/cam and /ramdisk/user/data/cam directories, but the
directory “data/cam/” or “tempData/cam” must be added to the filename
string. For example, if Y_CamFileSelect.Filename =
“data/cam/profile1.csv”, then Y_CamFileSelect loads
/flash/user/data/cam/profile1.csv.

Advertising