78
SGNETX Ver. 2.0.0

SGNETX Software Manual

Embed Size (px)

Citation preview

Page 1: SGNETX Software Manual

SGNETX Ver. 2.0.0

Page 2: SGNETX Software Manual

Introduction

This user’s manual describes the specifications and operations of SGNETX.

Please read this manual thoroughly to understand the specifications and fully employ the functions.

Precautions for Use

These precautions must be observed when using this manual and the software introduced herein:

♦ Sigma Koki Co., Ltd. retains all rights to this guide and the software introduced in the manual. ※Microsoft, Windows, VisualBasic and etc. are trademarks and registered trademarks of Microsoft in the U.S. The

copyright about these belongs to Microsoft. Moreover, software, a company name, etc. which are related in addition to these are each trademark or registered trademark of an owner, and copyright etc. belongs to each owner.

♦ Unauthorized reproduction or duplication of this manual, whether in whole or in part, is strictly

prohibited.

♦ Due to improvements or other reasons, the specifications of software and hardware introduced in

this manual are subject to change without prior notice.

♦ Sigma Koki Co., Ltd. assumes no responsibility for the results obtained when operating the

software introduced in this manual.

♦ While Sigma Koki Co., Ltd. has thoroughly inspected the contents of this manual and the software

introduced herein, unforeseen problems may still arise. Please contact us if there are any concerns.

Applicable Software and hardware

The following software and hardware are referred to in this manual:

♦ Software

- Operating System: Windows XP/Vista/7 32/64bit version (95/98/Me are not supported.)

- Development environment: VisualBasic.NET 2008 or more(Operates by .NET Framework3.5)

(This product checked operation by VisualBasic.NET 2008/2010.) ※The compatibility with SGACTX for VB6.0, SGSFSX, and SGPATX does not have this product, and methods

for use etc. differ. ※This product cannot be used on an Excel macro (please use it in VB.NET environment).

♦ Hardware

- The personal computers which can operate WindowsXP/Vista/7 and VisulaBasic.NET2008

normally.

※GPIB is only supported for interface board/card from National Instruments.

※USB is only supported for stage controller from Sigma Koki which supports USB.

Page 3: SGNETX Software Manual

Table of Contents

1. Overview ・・・・・・・・・・・・ 1

1.1 Main features ・・・・・・・・・・・・ 2

1.2 The procedure of use ・・・・・・・・・・・・ 3

2. Installation ・・・・・・・・・・・・ 5

2.1 Installing SGNETX ・・・・・・・・・・・・ 5

2.2 Uninstalling SGNETX ・・・・・・・・・・・・ 11

2.3 Registration of SGNETX ・・・・・・・・・・・・ 12

3. Functions (properties and methods) ・・・・・・・・・・・・ 15

3.1 SGNETX properties ・・・・・・・・・・・・ 19

3.2 Communication (RS232C) properties ・・・・・・・・・・・・ 20

3.3 Communication (GPIB) properties ・・・・・・・・・・・・ 24

3.4 Communication (USB) properties ・・・・・・・・・・・・ 27

3.5 Communication (TCP/IP) properties ・・・・・・・・・・・・ 27

3.6 SGNETX methods ・・・・・・・・・・・・ 30

3.7 Communication methods ・・・・・・・・・・・・ 36

3.8 Communication (GPIB) methods ・・・・・・・・・・・・ 39

3.9 Communication (USB) methods ・・・・・・・・・・・・ 43

3.10 Axis control properties ・・・・・・・・・・・・ 44

3.11 Axis control methods ・・・・・・・・・・・・ 45

3.12 SGNETX events ・・・・・・・・・・・・ 63

4. Programming ・・・・・・・・・・・・ 64

4.1 Programming using a fixed form function ・・・・・・・・・・・・ 64

4.2 Programming which uses RS232C ・・・・・・・・・・・・ 68

4.3 Programming which uses GPIB ・・・・・・・・・・・・ 70

4.4 Programming which uses USB ・・・・・・・・・・・・ 71

4.5 Programming which controls two or more

axes and two or more controllers ・・・・・・・・・・・・ 72

Page 4: SGNETX Software Manual

1. Overview

"SGNETX" is the component software which was adapted for the .NET Framework environment

of Microsoft. When building the measurement and the controlling system which connected

automatic positioning device, a measuring instrument, a controller, etc., especially a

programmer's burden is eased and he can program efficiently.

In "SGNETX", since application can be created combining the component standardized for

measurement / control, the time which programming takes is shortened and the application

stabilized more can be created.

Especially it carries broadly the control and the function which are needed when using automatic

positioning equipment. Therefore, a programmer can use them easily, without being conscious of

the difficult processing method etc.

At "SGNETX", “move instruction”, "stop instruction", and "a speed setting instruction" etc. can

be used as a control function of the stage controller of our company. Furthermore, as

general-purpose communication facility, variegated functions, such as "a communication setup"

and "transmission and reception of a command" of RS232C and GPIB, can be easily used from

application. Furthermore, stage controller SHOT-20/30 series and FINE-50 series of our company

are possible also for control by a USB interface.

By including SGNETX in application, control can be arranged in form like standard control, and

can be used for it.

It is possible to use a required function one by one according to the purpose and use of

application. Therefore, construction of the application which can respond to the broad

measurement environment which uses the stage controller of our company flexibly is possible.

Measurement / control application according to measurement environment is simply created by "SGNETX."

Measuring instrument

Stage controller Motorized Stage

Personal compute

1

Page 5: SGNETX Software Manual

1.1 Main Features

♦ Control of a Motorized stage, a measuring instrument, a controller, etc. is easily

programmable.

♦ Connection of device supports RS-232C*1, GPIB*2 and USB*3 interfaces.

♦ Since almost all the stage controller*4 made from Sigma Koki is supported, it can respond to

a broad user's use.

♦ Since many functions with which the stage controller*4 made from Sigma Koki is equipped

are supported, also in programming, those functions can be used easily.

♦ By use of a fixed form screen, various kinds of setup, communication connection, etc. can be

easily displayed and set as a screen.

♦ A stage can be easily operated without programming by use of operation screen form.

♦ SGNETX allows you to send/receive commands through interfaces directly with open

terminal windows. This enables you to check operational status during command entries.

*1: RS232C is based on the specification of MSComm of Microsoft.

*2: Only National Instruments’ card/board can support the GPIB interface.

If you want to use GPIB, be sure to install driver software (supplied with GPIB board/card) in

advance.

*3: Only Sigma Koki’s stage controller can support USB I/F.

If you want to use USB interface, be sure to install the driver software (recorded in CD-ROM) in

advance. A USB driver differs from the driver of the old version (since it is not compatible, control

which used the driver of the old version cannot be performed).

*4: SGNETX supports SHOT-202, 204MS, 202AM, 102, 602, 302GS, 304GS, PAT-001,GSC-01,02 FINE-01r,

502, 503,HIT-M(SHOT Mode).

It supports also old Mark-202, 204, 102 series and CSG602R. Please choose the product of the

same number.

(Mark-202→SHOT-202, Mark-204→SHOT-204MS, Mark-102→SHOT-102, CSG602R→SHOT-602)

HIT corresponds only to SHOT mode (it does not correspond to HIT mode).

2

Page 6: SGNETX Software Manual

1.2 The procedure of use

This section explains the outline about the procedure of use of "SGNETX."

1. A procedure until you use SGNETX ①Install SGNETX in a personal computer

Install SGNETX in a personal computer from CD-ROM.

⇒ See “2.1 Installing SGNETX.”

※If you want to use USB interface, be sure to install the driver software

②Register a license (when a license is required)

Register a license to be able to use SGNETX by VB.NET.

⇒ See the attached sheet "About a license of SGNETX."

③Register a component Register SGNETX into toolbox to be able to use SGNETX by VB.NET.

⇒ See “2.3 Registration of SGNETX.”

④Place control Place control on the form in order to use SGNETX by an actual program.

⇒See “2.3 Registration of SGNETX.”

2. A procedure of use of "SGNETX"

①Set up the conditions of device Set up the model of controller to be used, and the property of conditions (response mode,

time-out time, etc.) of operation.

When using a controller, a setup of ControllerType, AnswerMode (when using except

SHOT-102), and ControllerMode (when using SHOT-102) is necessity at worst.

If Controller_SettingForm is used, a display and setup of a required item can be performed

simply.

⇒See “3.1 SGNETX properties.”

3

Page 7: SGNETX Software Manual

②Set up communication conditions

Set up a communication type, communication conditions, etc. of a controller or device to be

used.

InterfaceType and a condition setup with each interface are required.

※To use USB, load processing of a USB driver is also required.

If Interface_SettingForm is used, a display and setup of a required item can be performed

simply.

⇒See “3.2 Communication (RS232C)properties ~ 3.4 Communication (USB)properties.”

③Connect communication

Connect communication of the controller and device to be used.

Open the controller and device which are a connection partner by Interface_Connect, and

change into the state which can be used.

If Interface_ConnectForm is used, communicative connection and a communicative check

can be performed simply.

⇒See “3.6 Communication methods ~ 3.8 Communication (USB) methods.”

④Control device

Control operation of a controller or device by using the property and method of SGNETX.

If Axis_ControlForm is used, operation of a stage can be performed simply.

If Interface_TerminalForm is used, between the devices of a connection place, transmission

and reception of a command can be performed simply.

⇒See mainly “3.9 Axis control properties ~ 3.10 Axis control methods.”

Please check about the details of a method for use on the page of each property and method of

Chapter 3, or the page of programming of Chapter 4.

4

Page 8: SGNETX Software Manual

2. Installation

To use SGNETX, SGNETX needs to be installed.

The Installation procedure is described below.

To install SGNETX, follow the steps ①~⑩ described below. ※"Administrator" authority may be required in order to install according to the personal computer environment

of use. In that case, please install after logging in by a user with authority.

2.1 Installing SGNETX

①Running Setup.exe

Insert the CD-ROM into the CD-ROM drive. The installer runs automatically.

If it does not run automatically, double click Setup.exe in the CD-ROM to start.

②Starting Setup Process

On starting Setup.exe, the SGNETX installation dialog appears.

To continue the installation, click the “Next” button. To cancel, click the “Cancel” button.

Fig. 2-1 Installation wizard

5

Page 9: SGNETX Software Manual

③Consent of software use

The contents of the license agreement in the case of using this software are displayed. Click the

“Next” button, when you consent and continue installation. Click "Cancel” button, when you

stop without consenting.

Fig. 2-2 License agreement dialog

④The check of the system requirements of software The information of the system requirements in the case of using this software is displayed.

Check the contents and click the “Next” button to continue the installation. To cancel, click the

“Cancel” button.

Fig. 2-3 Information dialog

6

Page 10: SGNETX Software Manual

⑤Setting User Information

Type in your name, organization and the serial number of the product. To continue the setup,

click the “Next” button. To cancel, click the “Cancel” button.

Fig. 2-4 Customer Information dialog

⑥Selecting Destination Folder Select the installation folder. To install to the default folder, click the “Next” button. To install

to a different folder, click the “Change” button and select a desired destination on the displayed

dialog.

Fig. 2-5 Destination Folder dialog

7

Page 11: SGNETX Software Manual

⑦Selecting Setup Type

Choose a setup type. To continue, click the “Next” button. To cancel, click the “Cancel” button.

(“Typical” is recommended for normal use).

*This dialog is not displayed in version2.0 or more.

Fig. 2-6 Setup Type dialog

⑧Start Copying Files

Check the summary of installation information. To continue installation, click the “Install”

button. To cancel, click the “Cancel” button.

Clicking the “Install” button begins the installation of SGNETX.

Fig. 2-7 Ready to Install the Program dialog

8

Page 12: SGNETX Software Manual

An on-going screen is displayed during installation.

Fig. 2-8 An installation on-going dialog

⑨Completion of Installation

Click the “Finish” button after the installation is completed.

Fig. 2-9 Completion of Installation

Installation of "SGNETX" is an end now. Installation of "SGINFO" of the software for license

registration is started continuously.

9

Page 13: SGNETX Software Manual

⑩Installation of "SGINFO" of the software for license registration Install software according to the display of an installation dialog.

Fig. 2-10 Installation start dialog

⑪Menu

After completion of installation, "SGNETX" is registered into a program menu.

Click "SGNETX_Sample", then the sample program of SGNETX will start.

※If neither .NET Franework nor LanguagePack is installed, it does not operate normally.

Click “Sample”, then the sample folder of SGNETX is displayed.

※SGNETX is not added although the project file and the source file are contained in the sample folder.

Click “Registration of license”, then the license registration window of SGNETX is displayed.

※Please use it, when registration of a license is required.

Fig. 2-11 Menu

10

Page 14: SGNETX Software Manual

2.2 Uninstalling SGNETX

Select a "Add or Remove Programs" of a "Control Panel".

The "Add or Remove Programs" window is displayed. Select "SGNETX" on the window and

click "Remove" button. (Delete "SGINFO" similarly.)

Click

Delete both.

Fig. 2-12 The "Add or Remove Programs" window

Please select "yes", if a check message is displayed.

Fig. 2-13 "Check message" window

An on-going window is displayed during deletion.

Fig. 2-14 The window "in deletion"

Deletion is completion when a message disappears.

11

Page 15: SGNETX Software Manual

2.3 Registration of SGNETX

To actually use SGNETX in VB.NET, it needs to be registered in tool box.

Here, a registration method is explained.

Choose “Choose Toolbox Items” with the "Tool" menu of VB.NET. ※Please understand that windows composition differs from the text in part by the version (2003/2005) of

VB.NET.

“Choose Toolbox Items” window is displayed.

Fig. 2-15

Click

Fig. 2-16

Choose “SGNETXctl” from the displayed list and click “OK”.

Click a "Browse" button, when there is not "SGNETXctl" in the displayed list.

12

Page 16: SGNETX Software Manual

Click the "Browse" button, then "Open" window is displayed. And choose “SGNETX.dll” from

the folder (usually C:/Program Files/SIGMA-KOKI/SGNETX) which installed SGNETX. And

Click the “Open” button.

Check the "SGNETXctl" is chosen in a list and click "OK."

Fig. 2-17

Fig.2-18

13

Page 17: SGNETX Software Manual

If SGNETX is chosen on "Choose Toolbox Items" window, "SGNETXctl" will appear in a tool

box.

If "SGNETXctl" of a tool box is chosen and it is attached on form, SGNETX can be used from a

program.

(SGNETX is added into References of solution Explorer.)

Fig.2-19

Fig.2-20

14

Page 18: SGNETX Software Manual

3. Functions (properties and methods)

There are properties and methods in the function of SGNETX and it can control by those

operations.

Table 3-1 Properties and methods of SGNETX

Category Name Function description MessageShow Displays or does not display message ControllerType Specifies controller type to be used InterfaceType Specifies communication interface AnswerMode Specifies response mode

Common properties

ControllerMode Specifies communication mode of SHOT-102 RS232C_CommPort Specifies communication port used by RS232C RS232C_DTREnable Specifies DTR line RS232CEOFEnable Specifies EOF detection RS232C_Handshaking Specifies handshaking RS232C_InputLen Specifies read byte number RS232C_InputMode Specifies type of receive data RS232C_NullDiscard Specifies Null character transfer RS232C_OutBufferSize Specifies transfer buffer size RS232C_ParityReplace Specifies parity character RS232C_RThreshold Specifies inside receive buffer byte number RS232C_RTSEnable Specifies RTS line RS232C_Settings Specifies baudrate, parity, data bit, and stop bit RS232C_Baudrate Specifies baudrate RS232C_DataBit Specifies data bit RS232C_StopBit Specifies stop bit RS232C_Parity Specifies parity RS232C_SThreshold Specifies transmit byte number needed for OnComm event

generation RS232C_PortOpen Opens or closes port RS232C_OutPut Transmits data RS232C_Input Receives data RS232C_Dilimiter Specifies delimiter

Communication (RS232C) properties

RS232C_TimeOut Specifies time-out time GPIB_Address Specifies address GPIB_Index Specifies index number GPIB_EOI Specifies EOI GPIB_EOS Specifies EOS GPIB_Delimiter Specifies delimiter GPIB_Timeout Specifies time-out time GPIB_Descriptor Gets device descriptor

Communication (GPIB) properties

GPIB_NIInterface Refers interface of GPIB USB_ID Specifies ID USB_Delimiter Gets delimiter

Communication (USB) properties USB_Timeout Specifies time-out time

TCPIP_HostName Host name to connect TCPIP_PortNumber Port number to connect TCPIP_Available The number of bytes which was acquired from the network

and which can be read TCPIP_Socket Specification and acquisition of a socket object TCPIP_Connected Acquisition of the connection situation to a host

Communication (TCP/IP) properties

15

Page 19: SGNETX Software Manual

TCPIP_ExclusiveAddressUse

Specification and acquisition of use of only one client

TCPIP_LingerState Specification and acquisition of the standby time information on a socket

TCPIP_NoDelay Specification and acquisition of delay TCPIP_ReceiveBufferSize

Specification and acquisition of receive buffer size

TCPIP_ReceiveTimeout Specification and acquisition of receive timeout TCPIP_SendBufferSize Specification and acquisition of send buffer size TCPIP_SendTimeout Specification and acquisition of send timeout

Communication (TCP/IP) properties

TCPIP_Delimiter Specifies delimiter

Controller_SettingForm Displays setting window of conditions of operation Interface_SettingForm Displays communications setting window Interface_ConnectForm Displays communications connection window Interface_TerminalForm Displays terminal window

Common methods

Axis_ControllForm Displays window of stage control Interface_Connect Checks communication connection Interface_Disconnect Disconnects communication SG_Open Opens device SG_Close Close device SG_Write Transmits data to device

Communication methods

SG_Read Receives data from device GPIB_NIibask Calls ibask function GPIB_NIibcac Calls ibcac function GPIB_NIibclr Calls ibclr function GPIB_NIibcmd Calls ibcmd function GPIB_NIibconfig Calls ibconfig function GPIB_NIibdev Calls ibdev function GPIB_NIibdma Calls ibdma function GPIN_Niibeos Calls ibeos function GPIB_NIibeot Calls ibeot function GPIB_NIibfind Calls ibfind function GPIB_NIibgts Calls ibgts function GPIB_NIibist Calls ibist function GPIB_NIiblines Calls iblines function GPIB_NIibln Calls ibln function GPIB_NIibloc Calls ibloc function GPIB_Niibnotify Calls ibnotify function GPIB_NIibonl Calls ibonl function GPIB_NIibpad Calls ibpat function GPIN_NIibpct Calls ibpct function GPIB_NIibppc Calls ibppc function GPIB_NIibrd Calls ibrd function GPIB_NIibrda Calls ibrda function GPIB_NIibrdf Calls ibrdf function GPIB_NIibrpp Calls ibrpp function GPIB_NIibrsc Calls ibrsc function GPIB_NIibrsp Calls ibrsp function GPIB_NIibrsv Calls ibrsv function GPIB_NIibsad Calls ibsad function GPIB_NIibsic Calls ibsic function GPIB_NIibsre Calls ibsre function

Communication (GPIB) methods

GPIB_NIibstop Calls ibstop function

16

Page 20: SGNETX Software Manual

GPIB_NIibtmo Calls ibtmo function GPIB_NIibtrg Calls ibtrg function GPIB_NIibwait Calls ibwait function GPIB_NIibwt Calls ibwt function GPIB_NIibwta Calls ibwta function GPIB_NIibwtf Calls ibwtf function GPIB_NIibcnt Refers ibcnt GPIB_NIibcntl Refers ibcntl GPIB_NIiberr Refers iberr

Communication (GPIB) methods

GPIB_NIibsta Refers GetCurrentStatus USB_DriverConnect Loads device driver of USB Communica

tion (USB) methods

USB_DriverDisconnect Unloads device driver of USB

Axes Refers properties and methods of axes control CmdTimeOut Specifies time-out time of command sending

and receiving StopTimeOut Specifies time-out time before stopping stage CurrentPosition Gets current position of the stage ShowPosition Specifies text box for a current position display

Axes control properties

Move_Stop_Flg Stops the stage StopStageEmergency Stops the stage immediately StopStage Decelerates and stops the stage GetPosition Gets current position of the stage ReturnOrigin Moves the stage to the machine origin ReturnLogicalOrigin Moves the stage to the logical origin ResetPosition Sets logical origin of stage Move Moves the stage relatively ResetAlarm Cancels alarm MoveAbs Moves the stage absolutely FreeHold Excitation and release of the motor JogDrive Jogs stage StatusQ Gets status information (Q) Status2 Gets status information (!) InsideInformation Gets status information (?) SetSpeed Sets stage traveling speed Set_Step Sets the number of move steps of a stage GetMemorySwitch Reads contents of memory switch SetMemorySwitch Updates contents of memory switch GetProgram Reads program SetProgram Updates program StartProgram Starts program CancelProgram Stops program Wait Specifies the move interval time of a stage Remote Remote operation Trigger Trigger output IOcommand Inputs and outputs I/O signal MoveLine Moves stages in a straight motion MoveCircle Moves stages in a circular motion Get_Volt Gets applied voltage Get_Hysteresis Gets hysteresis value

Axes control methods

Set_Track Changes Tracking/Lock mode

*The black-painted item cannot be used on version2.0 or more.

17

Page 21: SGNETX Software Manual

Table 3-2 Events of SGNETX

Category Name Function description SG_WriteEnd SG_Write method termination event Events SG_ReadEnd SG_Read method termination event

18

Page 22: SGNETX Software Manual

3.1 SGNETX properties

■MessageShow

Specify whether a message is displayed or is not displayed.

True:Display / False:Not display 【Default = True】

The message about the input and operation error on screens, such as a setting screen, is

displayed regardless of a setup of this property.

[Example]

SgnetXctl1.MessageShow = True ・・・ Display message.

■ControllerType

Specify type of controller to be used.

The following models can be specified.

SHOT-102(Value = 1102) / SHOT-602(Value = 1602) / SHOT-202(Value = 1202) /

SHOT-204MS(Value = 1204) / SHOT-202AM(Value = 1212) / SHOT-302GS(Value = 1302) /

SHOT-304GS(Value = 1304) / FINE-501(Value = 2501) / FINE-502(Value = 2502) /

FINE-503(Value = 2503) / PAT-001(Value= 3001)/ HIT(SHOT204)(Value= 5004)

※Only SHOT mode can be used at HIT.

【Default = SHOT-204MS】

[Example]

SgnetXctl1.ControllerType = SGNETX.SGNETXctl.ControllerKind.SHOT_204MS

・・・ Set it as SHOT-204MS.

■InterfaceType

Specify the communication interface to be used.

The following interfaces can be specified.

RS232C(Value = 1)/GPIB(Value = 2)/USB_SHOT(Value = 4)/USB_HIT(Value = 5)/TCPIP(Value = 6)

【Default = RS232C】

[Example]

SgnetXctl1.InterfaceType = SGNETX.SGNETXctl.InterfaceKind.Type_RS232C

・・・ Set it as RS232C.

■AnswerMode

Specify the communications protocol type of a controller.

Please unite with a setup (memory switch) of a controller.

True:Main / False:Sub 【Default = True】

When a model is SHOT-102 / SHOT-602 / PAT-001, this property does not have a meaning.

[Example]

SgnetXctl1.AnswerMode = True ・・・ Set it as Main.

19

Page 23: SGNETX Software Manual

■ControllerMode

Specify the mode of operation in the case of using SHOT-102.

Please unite with a setup (dip switch) of a controller.

True:MINI-5P mode / False:SHOT-102 mode 【Default = False】

When a model is except SHOT-102, this property does not have a meaning.

[Example]

SgnetXctl1.ControllerMode = False ・・・ Set it as SHOT-102 mode.

3.2 Communication (RS232C) properties

■RS232C_CommPort

Specify the port number in the case of using RS232C.

A setup is impossible when the port is used.

【Default = 1】 ※For property details, refer to CommPort of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_CommPort = 1 ・・・ Set a port as COM1.

■RS232C_DTREnable

Specify the status of the DTR line in the case of using RS232C.

True:Enable / False:Dsable 【Default = True】

A setup is impossible when the port is used.

※For property details, refer to DTREnable of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_DTREnable = True ・・・ Set DTR as enable.

■RS232C_EOFEnable

Specify whether EOF detection is possible in the case of using RS232C.

True:Enable / False:Disable 【Default = False】

A setup is impossible when the port is used.

※For property details, refer to EOFEnable of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_EOFEnable = False ・・・ Set EOF detection as disable.

20

Page 24: SGNETX Software Manual

■RS232C_Handshaking

Specify handshake method in the case of using RS232C.

The following methodscan be specified.

comNone(Value = 0) / comXOnXOff(Value = 1) / c omRTS(Value = 2) / comRTSXOnXOff(Value = 3)

【Default = comNone】

A setup is impossible when the port is used.

※For property details, refer to Handshaking of Microsoft’s MSComm control. [Example]

SgnetXctl1.RS232C_Handshaking = SGNETX.SGNETXctl.HandshakingKind.comNone

・・・ Set it as none.

■RS232C_InputLen

This property cannot be used by version2.0 or more.

■RS232C_InputMode This property cannot be used by version2.0 or more.

■RS232C_NullDiscard

Specify whether to permit the transfer of Null character in the case of using RS232C.

【Default = False】

A setup is impossible when the port is used.

※For property details, refer to NullDiscard of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_NullDiscard = False ・・・ Set it as not transfer Null.

■RS232C_OutBufferSize

Specify size of transfer buffer in the case of using RS232C.

【Default = 512】

A setup is impossible when the port is used.

※For property details, refer to OutBufferSize of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_OutBufferSize = 512 ・・・ Set the size of a transfer buffer as 512.

21

Page 25: SGNETX Software Manual

■RS232C_ParityReplace When a parity error occurs, specify the character replaced with the invalid character in a data

stream in the case of using RS232C.

【Default = “?”】

A setup is impossible when the port is used.

※For property details, refer to ParityReplace of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_ParityReplace = "?" ・・・ Set a replacement character as "?."

■RS232C_RThreshold

Specify the byte number for inside buffer.

【Default = 0】

A setup is impossible when the port is used.

※For property details, refer to RThreshold of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_SThreshold = 0 ・・・ Set it as 0.

■RS232C_RTSEnable

Specify the status of RTS line in the case of using RS232C.

True:Enable / False:Disable 【Default = True】

A setup is impossible when the port is used.

※For property details, refer to RTSEnable of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_RTSEnable = True ・・・ Set RTS as Enable.

■RS232C_Settings

This property cannot be used by version2.0 or more.

■RS232C_Baudrate

Specify the baudrate in the case of using RS232C.

110 / 300 / 600 / 1200 / 2400 / 4800 / 9600 / 14400 / 19200 / 28800 / 38400 / 56000 / 115200 / 128000 /256000

【Default = 9600】

A setup is impossible when the port is used.

[Example]

SgnetXctl1.RS232C_Baudrate = 9600 ・・・ Set baudrate as 9600.

22

Page 26: SGNETX Software Manual

■RS232C_DataBit Specify the data length in the case of using RS232C.

4 / 5 / 6 / 7 / 8 【Default = 8】

A setup is impossible when the port is used.

[Example]

SgnetXctl1.RS232C_DataBit = 8 ・・・ Set data length as 8.

■RS232C_StopBit

Specify the stop bit length in the case of using RS232C.

1 / 1.5 / 2 【Default = 1】

A setup is impossible when the port is used.

[Example]

SgnetXctl1.RS232C_StopBit = 1 ・・・ Set stop bit length as 1.

■RS232C_Parity

Specify the parity in the case of using RS232C.

n(none) / o(odd) / e(even) 【Defaulet = “n”】

A setup is impossible when the port is used.

[Example]

SgnetXctl1.RS232C_Parity = "n" ・・・ Set parity as none.

■RS232C_SThreshold

This property cannot be used by version2.0 or more.

■RS232C_PortOpen

The communications port is opened or closed in the case of using RS232C.

True:Open / False:Close 【Default = False】

※For property details, refer to PortOpen of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_PortOpen = True ・・・ Open the communications port.

■RS232C_Output

Data is transmitted to the port directly in the case of using RS232C.

Data can be set up only at the time of execution.

Specification of RS232C_Delimiter or RS232C_TimeOut does not have a meaning.

※For property details, refer to Output of Microsoft’s MSComm control.

[Example]

SgnetXctl1.RS232C_Output = "H:W" + vbCrLf ・・・ Transmit "H:W" and CRLF.

23

Page 27: SGNETX Software Manual

■RS232C_Input Data is received from the port directly in the case of using RS232C.

Data can be received only at the time of execution.

Specification of RS232C_Delimiter or RS232C_TimeOut does not have a meaning.

※For property details, refer to Input of Microsoft’s MSComm control.

[Example]

Dim buffer As String

buffer = Me.SgnetXctl1.RS232C_Input ・・・ Receive data.

■RS232C_Delimiter

Specify the delimiter character string in the case of using RS232C.

【Default = CRLF】

This delimiter is added to the last of transmit data. Moreover, received data are received in this

delimiter unit.

[Example]

SgnetXctl1.RS232C_Delimiter = vbCrLf ・・・ Set a delimiter as CRLF.

■RS232C_TimeOut

Specify communication time-out time (seconds) in the case of using RS232C.

In the receiving waiting state, if this time passes, it will become a time-out.

It can specify in the range for 0 - 600 seconds. (A time-out will become nothing if 0 is specified.)

【Default = 10】

[Example]

SgnetXctl1.RS232C_TimeOut = 10 ・・・ Set time-out time as 10 seconds.

3.3 Communication (GPIB) properties

■GPIB_Address

Specify the address (primary address) of communication in the case of using GPIB.

It can specify in the range for 0 - 30. 【Default = 8】

[Example]

SgnetXctl1.GPIB_Address = 8 ・・・ Set address as 8.

■GPIB_Address2

Specify the secondary address of communication in the case of using GPIB.

It can specify in the range for 0 - 30. 【Default = 0】

[Example]

SgnetXctl1.GPIB_Address2 = 0 ・・・ Set secondary address as 0.

24

Page 28: SGNETX Software Manual

■GPIB_Index Specify the index number of an access board in the case of using GPIB.

0 or more values can be specified. 【Default = 0】

[Example]

SgnetXctl1.GPIB_Index = 0 ・・・ Set index as 0.

■GPIB_EOI

Specify whether EOI can be used or not in the case of using GPIB.

True:Enable / False:Disable 【Default = False】

[Example]

SgnetXctl1.GPIB_EOI = False ・・・ Set EOI as disable.

■GPIB_EOS

Specify EOS in the case of using GPIB. 0 or more values can be specified. 【Default = 0】

[Example]

SgnetXctl1.GPIB_EOS = 0 ・・・ Set EOS as 0.

■GPIB_Delimiter

Specify the delimiter character string in the case of using GPIB.

【Default = CRLF】

This delimiter is added to the last of transmit data. Moreover, received data are received in this

delimiter unit.

[Example]

SgnetXctl1.GPIB_Delimiter = vbCrLf ・・・ Set delimiter as CRLF.

■GPIB_TimeOut

Specify communication time-out time (seconds) in the case of using GPIB.

In the receiving waiting state, if this time passes, it will become a time-out.

The following value can be specified.

None(Value = 0) / T10um(Value = 1) / T30um(Value = 2) / T100um(Value = 3) / T300um(Value = 4) /

T1ms(Value = 5) / T3ms(Value = 6) / T10ms(Value = 7) / T30ms(Value = 8) / T100ms(Value = 9) /

T300ms(Value = 10) / T1s(Value = 11) / T3s(Value = 12) / T10s(Value = 13) / T30s(Value = 14) /

T100s(Value = 15) / T300s(Value = 16) / T1000s(Value = 17)

(A time-out will become nothing if None is specified.)

【Default = T300ms】

[Example]

SgnetXctl1.GPIB_TimeOut = SGNETX.SGNETXctl.GPIBTimeOutKind.T300ms

・・・ Set time-out time as 300ms.

25

Page 29: SGNETX Software Manual

■GPIB_Descriptor

Obtain the device descriptor in the case of using GPIB.

This value is set when the device is opened.

【Default = 0】

When a value is 0, the device is in the state which cannot be used.

[Example]

Dim ud As Integer

ud = SgnetXctl1.GPIB_Descriptor ・・・ Obtain the device descriptor.

■GPIB_NIInterface

You can use directly the function for GPIB control currently offered from National

Instruments.

When you use this function, please add LangInt.dll to a reference setup of a project.

※For function details, refer to GPIB manual of National Instrments.

[Example]

Dim ud As Integer

Dim buffer As String

Dim sendstr As String

ud = SgnetXctl1.GPIB_NIInterface.ibdev(0, 8, 0, 10, 0, 0) … Use ibdev

sendstr = "H:W" + vbCrLf

Call SgnetXctl1.GPIB_NIInterface.ibwrt(ud, sendstr, Len(sendstr)) …ibwrt

Call SgnetXctl1.GPIB_NIInterface.ibrd(ud, buffer, 4) … Use ibrd

26

Page 30: SGNETX Software Manual

3.4 Communication (USB) properties

■USB_ID

Specify the ID number of the device to be communicated in the case of using USB.

It can specify in the range for 1 - 8. 【Default = 1】

[Example]

SgnetXctl1.USB_ID = 1 ・・・ Set the ID number as 1.

■USB_Delimiter

Obtain the delimiter character string in the case of using USB.

This delimiter is added to the last of transmit data. Moreover, received data are received in this

delimiter unit.

【Default = CR】

The delimiter cannot be changed other than CR.

[Example]

Dim buffer As String

buffer = SgnetXctl1.USB_Delimiter ・・・ Obtain the delimiter.

■USB_TimeOut

Specify communication time-out time (seconds) in the case of using USB.

In the receiving waiting state, if this time passes, it will become a time-out.

It can specify in the range for 0 - 600 seconds. (A time-out will become nothing if 0 is specified.)

【Default = 10】

[Example]

SgnetXctl1.USB_TimeOut = 10 ・・・ Set time-out time as 10 seconds.

3.5 Communication (TCP/IP) properties

■TCPIP_HostName Specify the host name of the device to be communicated in the case of using TCP/IP.

It can specify host name or IP address.

[Example]

SgnetXctl1.TCPIP_HostName = “192.168.0.1” ・・・ Set the IP Address.

27

Page 31: SGNETX Software Manual

■TCPIP_PortNumber

Specify the port number of the device to be communicated in the case of using TCP/IP.

[Example]

SgnetXctl1.TCPIP_PortNumber = 9001 ・・・ Set the port number.

■TCPIP_Available

Gets the amount of data that has been received from the network and is available to be read.

[Example]

Dim value As Integer

Value = SgnetXctl1.TCPIP_Available ・・・ Gets the amount of data.

■TCPIP_Socket

Gets or sets the Socket object.

[Example]

Dim value As Socket

Value = SgnetXctl1.TCPIP_Socket ・・・ Gets the Soket object.

■TCPIP_Connected

Gets a value indicating whether the underlying Socket for a TcpClient is connected to

a remote host.

[Example]

Dim value As Boolean

Value = SgnetXctl1.TCPIP_Connected ・・・ Gets the connected state.

■TCPIP_ExclusiveAddressUse

Gets or sets a Boolean value that specifies whether the TcpClient allows only one client to use

a port.

[Example]

Dim value As Boolean

Value = SgnetXctl1.TCPIP_ExclusiveAddressUse ・・・ Gets the client state.

■TCPIP_LingerStatus

Gets or sets information about the linger state of the associated socket.

[Example]

Dim value As LingerOption

Value = SgnetXctl1.TCPIP_LingerStatus ・・・ Gets the lingert state.

28

Page 32: SGNETX Software Manual

■TCPIP_NoDelay Gets or sets a value that disables a delay when send or receive buffers are not full.

[Example]

Dim value As Boolean

Value = SgnetXctl1.TCPIP_NoDelay ・・・ Gets the delay state.

■TCPIP_ReceiveBufferSize

Gets or sets the size of the receive buffer.

[Example]

Dim value As Integer

Value = SgnetXctl1.TCPIP_ReceiveBufferSize ・・・ Gets the receive buffer size.

■TCPIP_SendBufferSize

Gets or sets the size of the send buffer.

[Example]

Dim value As Integer

Value = SgnetXctl1.TCPIP_SendBufferSize ・・・ Gets the send buffer size.

■TCPIP_ReceiveTimeout

Gets or sets the amount of time a TcpClient will wait to receive data once a read operation is

initiated.

[Example]

Dim value As Integer

Value = SgnetXctl1.TCPIP_ReceiveTimeout ・・・ Gets the receive timeout.

■TCPIP_SendTimeout

Gets or sets the amount of time a TcpClient will wait for a send operation to complete

successfully.

[Example]

Dim value As Integer

Value = SgnetXctl1.TCPIP_SendTimeout ・・・ Gets the send timeout.

■TCPIP_Delimiter

Specify the delimiter character string in the case of using TCP/IP.

【Default = CRLF】

[Example]

SgnetXctl1.TCPIP_Delimiter = VbCrLf ・・・ Sets the delimiter as CR+LF.

29

Page 33: SGNETX Software Manual

3.6 SGNETX methods

■Controller_SettingForm

Display the window for a condition setup of operation, and set up each parameter.

Controller_SettingForm() As Boolean

Parameter: None

Return value: True (OK) / False (Cancel)

ControllerType

Select the model of controller to be used.

The selected model is set as the "ControllerType" property.

AnsweMode

Select the communications protocol type of a controller.

The selected value is set as the "AnsweMode" property.

ControllerMode

Select the mode of operation in the case of using SHOT-102.

The selected value is set as the “ControllerMode” property.

Fig. 3-1

Interface

Select the communication interface to be used.

The selected value is set as the “InterfaceType” property.

Port/Addr/ID

Select the port number (RS232C) / address (GPIB) / ID (USB) to be used according to a communication interface.

The selected value is set as the “RS232C_CommPort” property in the case of RS232C. It is set as the

“GPIB_Address” property in the case of GPIB, and set as the “USB_ID” property in the case of USB.

CommandTimeOut

Specify command time-out time.

This value is set as the "CmdTimeOut" property for all axes (Axes (0)).

StopTimeOut

Specify stop time-out time.

This value is set as the "StopTimeOu" property for all axes (Axes (0)).

Click on the “OK” button to update with the settings on the window.

Click on the "Cancel" button not to set up the settings.

30

Page 34: SGNETX Software Manual

■Interface_SettingForm

Display the window for a communication condition setup, and set up each parameter.

The setting window displayed changes according to the value of the "InterfaceType" property.

Interface_SettingsForm() As Boolean Parameter: None

Return value: True (OK) / False (Cancel)

Fig. 3-3

Fig. 3-2

Fig. 3-4 Fig. 3-5 When the value of the "InterfaceType" property is RS232C, the window of Fig. 3-2 is displayed.

And the contents chosen on the screen are set as each property of RS232C_CommPort,

RS232C_Settings, RS232C_Delimiter, RS232C_TimeOut, and RS232C_Handshiking.

When the value of the "InterfaceType" property is GPIB, the window of Fig. 3-3 is displayed.

And the contents chosen on the screen are set as each property of GPIB_Index,

GPIB_Address2, GPIB_EOI, GPIB_EOS, GPIB_Delimiter, and GPIB_TimeOut.

When the value of the "InterfaceType" property is USB, the window of Fig. 3-4 is displayed.

And the contents chosen on the screen are set as each property of USB_TimeOut.

When the value of the "InterfaceType" property is TCPIP, the window of Fig. 3-5 is displayed.

And the contents chosen on the screen are set as each property of TCPIP_HostName,

TCPIP_PortNumber,TCPIP_Delimiter and TCPIP_TimeOut.

Click on the “OK” button to update with the settings on the window.

Click on the "Cancel" button not to set up the settings.

31

Page 35: SGNETX Software Manual

■Interface_ConnectForm

Display the window for communication connection and check connection of a device.

Interface_ConnectForm(Optional ByVal CheckMode As Boolean = True) As Boolean Parameter: CheckMode (The check of transmission and reception

True: Check / False: Not check) Return value: True (Connection state) / False (Disconnect state)

Fig. 3-6

If the "Connect" button is clicked, an Interface_Connect method will be performed to the

device of the interface specified with the "InterfaceType" property, and an

Interface_Disconnect method will be performed if the "Disconnect" button is clicked.

CheckMode of a parameter is the same contents as an Interface_Connect method.

If a connection check is successful, "OK" will be displayed, and "NG" will be displayed if it

fails.

■Interface_TerminalForm

Display a terminal window, and transmit and receive commands.

Interface_TerminalForm() As Boolean

Parameter: None

Return value: True (Display OK) / False (Display NG)

It is displayed according to the value of an InterfaceType property.

Input a character string and press "Enter." Then they will be transmitted

The result of the character string transmitted and received is displayed.

Fig. 3-7

32

Page 36: SGNETX Software Manual

A command can be transmitted and received to the device of the interface specified with the

"InterfaceType" property.

When the "InterfaceType" property is RS232C, and a window is displayed, it will be in the

state waiting for receiving. In the case of GPIB and USB, it becomes the waiting for reception

after command transmission.

When displaying a terminal window, communication needs to be connected beforehand.

If communication is not in a connection state, a window will not be displayed and will be

ended by False.

■Axis_ControlForm

Display the operation window of a stage axis specified with the parameter.

Axis_ControlForm(ByVal AxisNo As Integer) As Boolean

Parameter: AxisNo (The axis number for operation)

Return value: True (Display OK) / False (Display NG)

Fig. 3-8

Fig. 3-9

When the model specified with the "ControllerType" property is FINE-501/502/503, figure 3-8

window is displayed, and when it is the other model, the window of Fig. 3-7 is displayed.

When displaying a operation window, communication needs to be connected beforehand.

If communication is not in a connection state, a window will not be displayed and will be

ended by False.

33

Page 37: SGNETX Software Manual

The operation method of an operation window 【SHOT-102/602/202/204MS/202AM/302GS/304GS/PAT-001/GSC-01/02】

⑬ ⑩ ⑪

Fig. 3-10 ⑨ ⑧

⑤ ④

①The axis number of an operation target is displayed. (0 is all axes) ②Input the parameter for speed setting.

③Click to set up the inputted speed parameter.

④Current position of the operated axis is shown.

⑤Click to start jogging. (Select the move direction with the radio button of +-.)

⑥Set current position to logical origin.

⑦Move axis to the logical origin.

⑧Move the specified amount of movements in the + direction.

⑨Specify the amount of movements.

⑩Click and hold to keep the axis moving in the + direction until the button is released. (Max

999999 pulse)

⑪Stop the stage.

⑫Move axis to the machine origin.

⑬Exit from operation window.

34

Page 38: SGNETX Software Manual

【FINE-501/502/503】

Fig. 3-11 ⑧ ⑨ ⑦ ⑥

①The axis number of an operation target is displayed. (0 is all axes) ②Input the parameter for step setting. Then click to set up the inputted step parameter. ③Click to display an applied voltage.( In the case of all axes, it cannot be used.)

④Current position of the operated axis is shown. ⑤Set current position to logical origin. ⑥Move axis to the logical origin. ⑦Move the specified amount of movements in the + direction. ⑧Specify the amount of movements. ⑨Stop the stage. ⑩Click to start jogging. (Select the move direction with the radio button of +-.) ⑪Move axis to the machine origin. ⑫Exit from operation window.

※Since movement of a stage is high-speed by the controller of FINE series, in the middle of a move, the

current position is hardly displayed.

35

Page 39: SGNETX Software Manual

3.7 Communication methods

■Interface_Connect

Connect and check communication.

Perform a SG_Open method to the device of the interface specified with the "InterfaceType"

property, and return a result.

Since communication with a connection partner is established as this method is performed and

a result is True, the method for various control etc. becomes usable henceforth. (Since

processing of Open/Write/Read etc. is performed inside, users' processing is unnecessary.)

When a CheckMode parameter is True, “!:” is transmitted by SG_Write after SG_Open and the

reply of "R" is checked by SG_Read. (The ready state check of a stage controller)

When a ControllerType property is HIT_SHOT204, "?:n" and "Z:0" are transmitted by

SG_Write after SG_Open and reception is checked.

Interface_Connect(Optional ByVal CheckMode As Boolean = True) As Boolean

Parameter: CheckMode (The check of transmission and reception

True: Check / False: Not check)

Return value: True (Connection check OK) / False (Connection check NG)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Interface_Connect(True)

■Interface_Disconnect

Disconnect the communication.

Perform a SG_Close method to the device of the interface specified with the "InterfaceType"

property, and return a result.

Interface_Disconnect() As Boolean

Parameter: None

Return value: True (Disconnection OK) / False (Disconnection NG)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Interface_Disconnect

36

Page 40: SGNETX Software Manual

■SG_Open

Open the device of the interface specified with the "InterfaceType" property.

When InterfaceType is RS232C, the port specified with the RS232C_CommPort property is

opened.

When InterfaceType is GPIB, ibdev is performed to the device of the address specified with the

GPIB_Address property by making the value of each property of GPIB_Index,

GPIB_Address2, GPIB_TimeOut, GPIB_EOI, and GPIB_EOS into a parameter, and a device

is opened. The descriptor returned from ibdev is set to GPIB_Descriptor.

When InterfaceType is USB, the device specified with the USB_ID property is opened. (Only

the SHOT controller corresponding to USB can use USB.)

SG_Open() As Boolean

Parameter: None

Return value: True (Open success) / False (Open failure)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.SG_Open

■SG_Close

Close the device of the interface specified with the "InterfaceType" property.

When InterfaceType is RS232C, the port specified with the RS232C_CommPort property is

closed.

When InterfaceType is GPIB, ibonl is performed to the device (GPIB_Descriptor) which

performed SG_Open.

When InterfaceType is USB, the device specified with the USB_ID property is closed. (Only

the SHOT controller corresponding to USB can use USB.)

SG_Close() As Boolean

Parameter: None

Return value: True (Close success) / False (Close failure)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.SG_Close

37

Page 41: SGNETX Software Manual

■SG_Write Transmit data to the device of the interface specified with the InterfaceType property.

When InterfaceType is RS232C, data is transmitted to the port specified with the

RS232C_CommPort property. The delimiter specified by RS232C_Delimiter is added to the

last of transmit data.

When InterfaceType is GPIB, data is transmitted to the device of the address specified with the

GPIB_Address property. The delimiter specified by GPIB_Delimiter is added to the last of

transmit data.

When InterfaceType is USB, data is transmitted to the device specified with the USB_ID

property. The delimiter (CR fixed) specified by USB_Delimiter is added to the last of transmit

data. (Only the SHOT controller corresponding to USB can use USB.)

SG_Write(ByVal Wstr As String) As Boolean

Parameter: Wstr (Transmit data)

Return value: True (Write success) / False (Write failure)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.SG_Write("H:W")

■SG_Read

Receive data from the device of the interface specified with the InterfaceType property.

When InterfaceType is RS232C, data is received from the port specified with the

RS232C_CommPort property. The data to the delimiter specified by RS232C_Delimiter is

received. Moreover, it waits for reception during the time specified by RS232C_TimeOut.

When InterfaceType is GPIB, data is received from the device of the address specified with the

GPIB_Address property. The data to the delimiter specified by GPIB_Delimiter is received.

Moreover, it waits for reception during the time specified by GPIB_TimeOut.

When InterfaceType is USB, data is received from the device specified with the USB_ID

property. The data to the delimiter (CR fixed) specified by USB_Delimiter is received.

Moreover, it waits for reception during the time specified by USB_TimeOut. After SG_Read,

SG_StopListen is required. (Only the SHOT controller corresponding to USB can use USB.)

SG_Read(ByRef Rstr As String) As Boolean

Parameter: Rstr (The buffer for received-data storing)

Return value: True (Read success) / False (Read failure)

[Example]

Dim rtn As Boolean

Dim Rstr As String

rtn = SgnetXctl1.SG_Read(Rstr)

38

Page 42: SGNETX Software Manual

3.8 Communication (GPIB) methods

■GPIB_NIibask

This property cannot be used by version2.0 or more.

■GPIB_NIibcac

This property cannot be used by version2.0 or more.

■GPIB_NIibclr

This property cannot be used by version2.0 or more.

■GPIB_NIibcmd This property cannot be used by version2.0 or more.

■GPIB_NIibcmda

This property cannot be used by version2.0 or more.

■GPIB_NIibconfig

This property cannot be used by version2.0 or more.

■GPIB_NIibdev

This property cannot be used by version2.0 or more.

■GPIB_NIibdma

This property cannot be used by version2.0 or more.

■GPIB_NIibeos This property cannot be used by version2.0 or more.

■GPIB_NIibeot

This property cannot be used by version2.0 or more.

■GPIB_NIibfind

This property cannot be used by version2.0 or more.

■GPIB_NIibgts

This property cannot be used by version2.0 or more.

39

Page 43: SGNETX Software Manual

■GPIB_NIibist This property cannot be used by version2.0 or more.

■GPIB_NIiblines

This property cannot be used by version2.0 or more.

■GPIB_NIibln This property cannot be used by version2.0 or more.

■GPIB_NIibloc

This property cannot be used by version2.0 or more.

■GPIB_NIibnotify This property cannot be used by version2.0 or more.

■GPIB_NIibonl

This property cannot be used by version2.0 or more.

■GPIB_NIibpad This property cannot be used by version2.0 or more.

■GPIB_NIibpct

This property cannot be used by version2.0 or more.

■GPIB_NIibppc This property cannot be used by version2.0 or more.

■GPIB_NIibrd

This property cannot be used by version2.0 or more.

■GPIB_NIibrda This property cannot be used by version2.0 or more.

■GPIB_NIibrdf

This property cannot be used by version2.0 or more.

■GPIB_NIibrpp

This property cannot be used by version2.0 or more.

40

Page 44: SGNETX Software Manual

■GPIB_NIibrsc This property cannot be used by version2.0 or more.

■GPIB_NIibrsp

This property cannot be used by version2.0 or more.

■GPIB_NIibrsv

This property cannot be used by version2.0 or more.

■GPIB_NIibsad

This property cannot be used by version2.0 or more.

■GPIB_NIibsic This property cannot be used by version2.0 or more.

■GPIB_NIibsre

This property cannot be used by version2.0 or more.

■GPIB_NIibstop This property cannot be used by version2.0 or more.

■GPIB_NIibtmo

This property cannot be used by version2.0 or more.

■GPIB_NIibtrg This property cannot be used by version2.0 or more.

■GPIB_NIibwait

This property cannot be used by version2.0 or more.

■GPIB_NIibwt This property cannot be used by version2.0 or more.

■GPIB_NIibwta This property cannot be used by version2.0 or more.

■GPIB_NIibwtf

This property cannot be used by version2.0 or more.

41

Page 45: SGNETX Software Manual

■GPIB_NIibcnt

This property cannot be used by version2.0 or more.

■GPIB_NIibcntl This property cannot be used by version2.0 or more.

■GPIB_NIiberr

This property cannot be used by version2.0 or more.

■GPIB_NIibsta

Obtain the value of the GetCurrentStatus.

Dim r As Integer

r = SgnetXctl1.GPIB_NIibsta

42

Page 46: SGNETX Software Manual

3.9 Communication (USB) methods

■USB_DriverConnect

When using USB, load a required USB driver and change into the state which can be used.

When using USB, it is necessary to perform this method once first, and USB becomes usable

henceforth.

※Sets the InterfaceType property before using this method.

USB_DriverConnect(ByVal hWnd As Long) As Boolean

Parameter: hWnd (The window handle of application)

Return value: True (Driver load OK) / False (Driver load NG)

[Example]

Dim rtn As Boolean

SgnetXctl1.InterfaceType = SGNETX.SgnetXctl1.InterfaceKind.Type_USB_SHOT

rtn = SgnetXctl1.USB_DriverConnect(Me.Handle.ToInt32)

■USB_DriverDisconnect

When using USB, stop use of a required USB driver.

Before ending the application which uses USB, it is necessary to perform this

USB_DriverDisconnect() As Boolean

Parameter: None

Return value: True (Driver unload OK) / False (Driver unload NG)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.USB_DriverDisconnect

■SG_StopListen When InterfaceType is USB_SHOT or USB_HIT, the reception processing by SG_Read is

suspended.Whenever SG_Read is completed, it is necessary to perform SG_StopListen.

SG_StopListen() As Boolean

Parameter: None

Return value: True (OK) / False (NG)

[Example]

Dim rtn As Boolean

Dim Rstr As String

rtn = SgnetXctl1.SG_Read(Rstr)

rtn = SgnetXctl1.SG_StopListen

43

Page 47: SGNETX Software Manual

3.10 Axis control properties

■Axes

Specify the axis of a controlled object. Specify operation to the axis after it.

It can specify from 0 to 4 axes. (If 0 is specified, all axes will be set as the object of control.)

Axes(ByVal AxisNumber As Integer) Parameter: AxisNumber (0-4 axes) The number of axes which can be specified changes

with controllers to be used. [Example]

SgnetXctl1.Axes(1).property or method for axial control

■CmdTimeOut

Specify time (second) after transmitting a command to a stage and making it operate until a

stage returns to a ready state. If it does not become a ready within this time after transmitting a

command, it will become a command time-out. To perform operation which requires time,

such as moving a long stroke or making movement speed late, it is necessary to enlarge this

value.

It can specify in the range for 0 - 600 seconds. (A time-out will become nothing if 0 is specified.)

【Default = 30】

[Example] SgnetXctl1.Axes(1).CmdTimeOut = 30 ・・・ Specify command time-out time as 30 seconds.

■StopTimeOut

Specify time (second) after a stage will be in a ready state until it stops completely. If a stage

does not stop completely to within this time after becoming a ready, it will become a stop

check time-out. To take time to final positioning on a stage with a scale etc., it is necessary to

enlarge this value.

It can specify in the range for 0 - 600 seconds. (A time-out will become nothing if 0 is specified.)

【Default = 30】

[Example] SgnetXctl1.Axes(1).StopTimeOut = 30 ・・・ Specify stop check time-out time as 30 seconds.

■CurrentPosition

The current position after operating a stage is obtained.

This property cannot be acquired, when CmdTimeOut is 0, or when Axes is 0 (all axial

specification).

[Example]

Dim pos As Double

pos = SgnetXctl1.Axes(1).CurrentPosition ・・・ Obtain the current position after operation.

44

Page 48: SGNETX Software Manual

■ShowPosition

Specify TextBox to display, in displaying the current position while the stage is operating.

【Default = Nothing】

If TextBox which wants to display the current position is specified as this property, when the

method (Move/MoveAbs/ReturnOrigin/ReturnLogicalOrigin/JogDrive) of a move system is

performed, the current position of a stage is displayed on TextBox.

When CmdTimeOut is 0, or when a Mode parameter is set to True at the time of move system

method execution, it is not displayed on TextBox.

It cannot be specified as this property other than TextBox. ※Since movement of a stage is high-speed by the controller of FINE series, in the middle of a move, the current position is hardly displayed. [Example]

SgnetXctl1.Axes(1).ShowPosition = Me.TextBox1 ・・・ Specify TextBox to display.

SgnetXctl1.Axes(1).Move(5000) ・・・ If a stage is moved, the current position will be displayed on TextBox.

■Move_Stop_Flg

Stop the stage under operation. This property is effective when the “Mode” of Move Method,

MoveAbs or JogDrive is set to False. StopStageEmergency or StopStage is used when

“Mode” is set to True.

*In USB,It cannot be used. (Please use StopStageEmergency)

[Example]

SgnetXctl1.Axes(1).Move_Stop_Flg = True ・・・ Stop the 1st axis of a stage.

3.11 Axis control methods

■StopStageEmergency

Stop the stage under operation immediately.

StopStageEmergency() As Boolean

Parameter: None

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean rtn = SgnetXctl1.Axes(1).StopStageEmergency ・・・ Stop the 1st axis of a stage

immediately.

45

Page 49: SGNETX Software Manual

■StopStage

Decelerate and stop the stage under operation.

StopStage() As Boolean

Parameter: None

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).StopStage ・・・ Decelerate and stop the 1st axis of a stage.

■GetPosition

Obtain current position of the stage.

The current position is asked to a stage controller when this method is performed.

GetPosition() As String

Parameter: None

Return value: Current position

[Example]

Dim pos As String pos = SgnetXctl1.Axes(1).GetPosition ・・・ Obtain the current positon of the 1st axis of

a stage.

■ReturnOrigin

Move the stage to the machine origin.

A Dir parameter is effective only when a model is SHOT-102 or SHOT-602.

In the case of other models, it is not necessary to specify. (It is ignored even if it specifies.)

If True is specified with a Mode parameter, this method will return, shortly after starting

movement to a machine orogin. (Since after a return will be in a busy state, it is necessary to

perform the next processing after checking a ready by the user side.)

If False is specified with a Mode parameter, (or nothing is specified) this method will make

movement to a machine origin start, and processing will be completed, and if it will be in a

ready state, it will return.

ReturnOrigin(Optional ByVal Dir As Boolean = True,

Optional ByVal Mode As Boolean = False) As Boolean

Parameter: Dir (The direction of the origin: True = + / False = -),

Mode (Mode of operation: True = Return immediately /

False = Return after a ready)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean rtn = SgnetXctl1.Axes(1).ReturnOrigin ・・・ Move the 1st axis to the machine origin. rtn = SgnetXctl1.Axes(0).ReturnOrigin ・・・ Move the all axes to the machine origin.

46

Page 50: SGNETX Software Manual

■ReturnLogicalOrigin Move the stage to the logical origin.

Specify the current position of the axis for movement as Vdata1 parameter.

When you move all axes, specify the current position of each axis as Vdata2-Vdata4.

If True is specified with a Mode parameter, this method will return, shortly after starting

movement to a logical orogin. (Since after a return will be in a busy state, it is necessary to

perform the next processing after checking a ready by the user side.)

If False is specified with a Mode parameter, (or nothing is specified) this method will make

movement to a logical origin start, and processing will be completed, and if it will be in a

ready state, it will return.

ReturnLogicalOrigin(ByVal Vdata1 As Double,

Optional ByVal Vdata2 As Double = 0,

Optional ByVal Vdata3 As Double = 0,

Optional ByVal Vdata4 As Double = 0,

Optional ByVal Mode As Boolean = False) As Boolean

Parameter: Vdata1 (The current position of the axis for movement),

Vdata2,Vdata3,Vdata4 (The current position of 2 axis more than in the

case of moving all axes)

Mode (Mode of operation: True = Return immediately / False = Return after a ready)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).ReturnLogicalOrigin(100)

・・・ Move the 1st axis of the stage whose current position is 100 to the logical origin.

rtn = SgnetXctl1.Axes(2).ReturnLogicalOrigin(100)

・・・ Move the 2nd axis of the stage whose current position is 100 to the logical origin.

rtn = SgnetXctl1.Axes(0).ReturnLogicalOrigin(100,100,100,100)

・・・ Move the all axes of the stage whose current position is 100 to the logical origin.

■ResetPosition

Set current position of the stage as logical origin.

ResetPosition() As Boolean

Parameter: None

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).ResetPosition ・・・ Set up the logiccal origin of the 1st axis of a stage.

47

Page 51: SGNETX Software Manual

■Move

Move the stage relatively.

Specify the quantity of the relative movement of the axis for movement as Vdata1 parameter.

When you move all axes, specify the relative movement of each axis as Vdata2-Vdata4.

If True is specified with a Mode parameter, this method will return, shortly after starting

movement. (Since after a return will be in a busy state, it is necessary to perform the next

processing after checking a ready by the user side.)

If False is specified with a Mode parameter, (or nothing is specified) this method will make

movement start, and processing will be completed, and if it will be in a ready state, it will

return.

Move(ByVal Vdata1 As Double,

Optional ByVal Vdata2 As Double = 0,

Optional ByVal Vdata3 As Double = 0,

Optional ByVal Vdata4 As Double = 0,

Optional ByVal Mode As Boolean = False) As Boolean

Parameter: Vdata1 (The amount of relative movement of the axis for movement),

Vdata2,Vdata3,Vdata4 (The amount of relative movement of 2 axis

more than in the case of moving all axes)

Mode (Mode of operation: True = Return immediately / False = Return after a ready)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).Move(100) ・・・ Move the 1st axis of a stage relatively by 100 pulses.

rtn = SgnetXctl1.Axes(2).Move(100) ・・・ Move the 2nd axis of a stage relatively by 100 pulses. rtn = SgnetXctl1.Axes(0).Move(100,100,100,100) ・・・ Move the all axes of a stage relatively

by 100 pulses.

■ResetAlarm Reset the alarm (of a scale / servo) generated by the controller.

This method can be used only when a model is SHOT-204MS/202AM/302GS/304GS.

An axial number is not related and resets the alarm of a controller by every axial number.

ResetAlarm() As Boolean

Parameter: None

Return value: True (Normal end) / False (Error)

[Example]

rtn = SgnetXctl1.Axes(1).ResetAlarm ・・・ Reset the alarm of a controller.

48

Page 52: SGNETX Software Manual

■MoveAbs

Move the stage absolutely.

Specify the quantity of the absolute movement of the axis for movement as Vdata1 parameter.

When you move all axes, specify the absolute movement of each axis as Vdata2-Vdata4.

If True is specified with a Mode parameter, this method will return, shortly after starting

movement. (Since after a return will be in a busy state, it is necessary to perform the next

processing after checking a ready by the user side.)

If False is specified with a Mode parameter, (or nothing is specified) this method will make

movement start, and processing will be completed, and if it will be in a ready state, it will

return.

This method cannot be used when a model is SHOT-602.

MoveAbs(ByVal Vdata1 As Double,

Optional ByVal Vdata2 As Double = 0,

Optional ByVal Vdata3 As Double = 0,

Optional ByVal Vdata4 As Double = 0,

Optional ByVal Mode As Boolean = False) As Boolean

Parameter: Vdata1 (The amount of absolute movement of the axis for movement), Vdata2,Vdata3,Vdata4 (The amount of absolute movement of 2 axis

more than in the case of moving all axes) Mode (Mode of operation: True = Return immediately /

False = Return after a ready) Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).MoveAbs(100) ・・・ Move the 1st axis of a stage absolutely by 100 pulses.

rtn = SgnetXctl1.Axes(2).MoveAbs(100) ・・・ Move the 2nd axis of a stage absolutely by 100 pulses. rtn = SgnetXctl1.Axes(0).MoveAbs(100,100,100,100) ・・・ Move the all axes of a stage absolutely

100 pulses.

■FreeHold

Change the motor of a stage into magnetization or a free state.

Magnetization/freelancer can be specified by Mode of a parameter.

This method cannot be used when models are SHOT-202AM, and FINE-501/502/503.

FreeHold(ByVal Mode As Boolean) As Boolean

Parameter: Mode (Mode of operation: True = Magnetization / False = Free)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).FreeHold(True) ・・・ Magnetize the motor of the 1st axis of a stage.

49

Page 53: SGNETX Software Manual

■JogDrive

Jog the stage.

Specify the move direction as a Dir parameter.

When you stop jog operation, please perform a StopStageEmergency method by a SHOT

system controller, and perform a StopStage method by a FINE system controller.

If False is specified with a Mode parameter, (or nothing is specified), this method does not

return until stop instruction is executed, but the current position is set as a ShowPosition

property. If True is specified with a Mode parameter, this method will return immediately, but

the current position is not set as a ShowPosition property. (It is necessary to check the current

position, a ready state, etc. by the user side.)

JogDrive(ByVal Dir As Boolean, Optional ByVal Mode As Boolean = False) As Boolean

Parameter: Dir (The move direction),

Mode (Mode of operation: True = Return immediately / False = Return by stop instruction)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).JogDrive(True) ・・・ Jog the 1st axis of a stage at + side.

■StatusQ

Transmit the Q command to a controller and return response.

※For details, refer to the manual of the controller.

An axial number is not related and can acquire a result by every axial number.

StatusQ() As String

Parameter: None

Return value: The result of the Q command

[Example]

Dim qstr As String

qstr = SgnetXctl1.Axes(1).StatusQ ・・・ Get the result of the Q command.

■Status2 Transmit the ! command to a controller and return response.

※For details, refer to the manual of the controller.

An axial number is not related and can acquire a result by every axial number.

Status2() As String

Parameter: None

Return value: The result of the ! command

[Example]

Dim qstr As String

qstr = SgnetXctl1.Axes(1).Status2 ・・・ Get the result of the ! command.

50

Page 54: SGNETX Software Manual

■InsideInformation

Obtain the inside information of a controller.

Specify the contents of acquisition with a Func parameter.

Specify the axial target number with an Axis parameter.

※For details, refer to the manual of the controller.

Only the controller which has inside information can be used.

Acquirable information is restricted by the model.

An axial number is not related and can acquire a inside information by every axial number.

InsideInformation(ByVal Func As Integer, Optional ByVal Axis As Integer = 1)

As String

Parameter: Func (Function type:

1→Version number / 2→Last output value of the O command /

3→Last settings value of W command / 4→Last settings value of E command /

5→Last settings value of K command / 6→Travel per pulse /

7→Travel speed / 8→The last amount of relative pulses /

9→The last amount of absolute pulses / 10→The number of division /

11→Model name / 12→Control mode)

※Func1 can be used by each controller.

2-10 can be used by SHOT-20 system / 30 system.

7 and 11-12 can be used by FINE-50 system.

Axis (Axis number: 1-4)

Return value: The obtained value

[Example]

Dim vstr As String

vstr = SgnetXctl1.Axes(1).InsideInformation(1) ・・・ Obtain version number

vstr = SgnetXctl1.Axes(1).InsideInformation(2) ・・・ Last output value of the O command

vstr = SgnetXctl1.Axes(1).InsideInformation(3) ・・・ Last settings value of W command

vstr = SgnetXctl1.Axes(1).InsideInformation(4) ・・・ Last settings value of E command

vstr = SgnetXctl1.Axes(1).InsideInformation(5) ・・・ Last settings value of K command

vstr = SgnetXctl1.Axes(1).InsideInformation(6,1) ・・・ Travel per pulse of 1st asis

vstr = SgnetXctl1.Axes(1).InsideInformation(7,1) ・・・ Travel speed of 1st axis vstr = SgnetXctl1.Axes(1).InsideInformation(8,1) ・・・ The last amount of relative

pulses of 1st axis vstr = SgnetXctl1.Axes(1).InsideInformation(9,1) ・・・ The last amount of absolute

pulses of 1st axis vstr = SgnetXctl1.Axes(1).InsideInformation(10,1) ・・・ The number of division of 1st axis

vstr = SgnetXctl1.Axes(1).InsideInformation(11) ・・・ Model name

vstr = SgnetXctl1.Axes(1).InsideInformation(12) ・・・ Control mode

51

Page 55: SGNETX Software Manual

■SetSpeed

Set the traveling speed of the stage.

Set the minimum speed of the axis for movement as S1 parameter, set the maximum speed as

F1 and set acceleration-and-deceleration time as R1.

When you set up all axes, set the value of each axis as S2-S4, F2-F4, and R2-R4.

It needs to be set up of the MINI-5P mode of SHOT-602 and SHOT-102 for two axes (all

axes).

A Range parameter is used only in the MINI-5P mode of SHOT-602 and SHOT-102.

In the case of a FINE system controller, please use Set_Step.

SetSpeed(ByVal S1 As Integer, ByVal F1 As Integer, ByVal R1 As Integer,

Optional ByVal S2 As Integer = 500, Optional ByVal F2 As Integer = 5000,

Optional ByVal R2 As Integer = 200, Optional ByVal S3 As Integer = 750,

Optional ByVal F3 As Integer = 7500, Optional ByVal R3 As Integer = 200,

Optional ByVal S4 As Integer = 1000, Optional ByVal F4 As Integer = 10000,

Optional ByVal R4 As Integer = 200, Optional ByVal Range As Integer = 2)

As Boolean

Parameter: S1 (The minimum speed of the axis for a setup),

F1 (The maximum speed of the axis for a setup),

R1 (Acceleration-and-deceleration time of the axis for a setup), S2~S4,F2~F4,R2~R4 (The value which more than 2 axis in the case

of setting up all axes sets up) Range (Speed range)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).SetSpeed(1000, 5000, 200) ・・・ Speed setting of the 1st axis of the stage of SHOT-102(102 mode) / 20 system / 30 system / PAT001

rtn = SgnetXctl1.Axes(2).SetSpeed(1000, 5000, 200) ・・・ Speed setting of the 2nd axis of the stage of SHOT-102(102 mode) / 20 system / 30 system

rtn = SgnetXctl1.Axes(3).SetSpeed(1000, 5000, 200)

・・・ Speed setting of the 3rd axis of the stage of SHOT-204 / 304

rtn = SgnetXctl1.Axes(0).SetSpeed(1000, 5000, 200, 1000, 5000, 200)

・・・ Speed setting of the all axes of the stage of SHOT-102(102 mode) / 202 / 302

rtn = SgnetXctl1.Axes(0).SetSpeed(1000, 5000, 200, 1000, 5000, 200,

1000, 5000, 200, 1000, 5000, 200)

・・・ Speed setting of the all axes of the stage of SHOT-204 / 304

rtn = SgnetXctl1.Axes(0).SetSpeed(1000, 5000, 200, 1000, 5000, 200

, , , , , , , 2)

・・・ Speed setting of SHOT-102(MINI-5P mode) / 602

52

Page 56: SGNETX Software Manual

■Set_Step

Set up the number of move steps of a stage.

This method can be used only when a model is FINE-501/502/503.

Set the number of steps of the axis for a setup to S1 parameter.

When you set up all axes, set the value of each axis as S2-S3.

Set_Step(ByVal SP1 As Integer, Optional ByVal SP2 As Integer = 10,

Optional ByVal SP3 As Integer = 10) As Boolean

Parameter: S1 (The number of steps of the axis for a setup), S2~S3 (The value which more than 2 axis in the case of setting up all

axes sets up) Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean rtn = SgnetXctl1.Axes(1).Set_Step(10) ・・・ Set up the number of steps of the 1st

axis of a stage. rtn = SgnetXctl1.Axes(2).Set_Step(10) ・・・ Set up the number of steps of the 2nd

axis of a stage. rtn = SgnetXctl1.Axes(0).Set_Step(10, 10, 10)

・・・ Set up the number of steps of the all axes of a stage of FINE-503.

■GetMemorySwitch

The contents of the memory switch in a controller are read into the specified buffer.

Specify the buffer of a reading place as a MS_Data parameter.

It can be used only by the controller which has a memory switch.

This method cannot be used when a model is SHOT-102/602/PAT001.

An axial number is not related and obtains the contents of the memory switch by every axial

number.

GetMemorySwitch(ByRef MS_Data As String) As Boolean

Parameter: MS_Data (The reading place of memory switch data)

Return value: True (Normal end) / False (Error)

[Example]

Dim buffer As String

rtn = SgnetXctl1.Axes(1).GetMemorySwitch(buffer)

・・・ Read the contents of the memory switch into buffer.

53

Page 57: SGNETX Software Manual

■SetMemorySwitch

Write the contents of the memory switch into a controller.

Specify the buffer which set data as the MS_Data parameter.

It can be used only by the controller which has a memory switch.

This method cannot be used when a model is SHOT-102/602/PAT001.

An axial number is not related and writes the contents of the memory switch by every axial

number.

The contents of the data to write in change with models.

SetMemorySwitch(ByRef MS_Data As String) As Boolean

Parameter: MS_Data (Memory switch data to write in)

Return value: True (Normal end) / False (Error)

[Example]

Dim buffer As String

buffer = "3,100,1000,200,500,5000,200,750,7500,200,1000,10000,200,

3,2,1,2,8,0,0,0,0,40,40,4,4,4,4,4,4,1,1,1,1,40,40,40,40,

0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,1,1,1,1,500,5000,200,

500,5000,200,500,5000,200,500,5000,200,0" rtn = SgnetXctl1.Axes(1).SetMemorySwitch(buffer) ・・・ Write the contents of the

memory switch

■GetProgram

The contents of the program in a controller are read into the specified buffer.

Specify the number of the program read into a ProgramNumber parameter.

Specify the buffer of a reading place as a MS_Data parameter.

It can be used only by the controller which has a program function.

This method cannot be used when a model is SHOT-102/602/PAT001.

An axial number is not related and obtains the contents of the program by every axial number. ※Since communication may become unstable by USB in the case of a program which exceeds

1000 lines, it cannot recommend. GetProgram(ByVal ProgramNumber As Integer, ByRef PG_Data As String)

As Boolean

Parameter: ProgramNumber (The program number to read: 1/2)

MS_Data (The reading place of program)

Return value: True (Normal end) / False (Error)

[Example]

Dim buffer As String

rtn = SgnetXctl1.Axes(1).GetProgram(1, buffer)

・・・ Read the contents of the program 1 into buffer.

54

Page 58: SGNETX Software Manual

■SetProgram

Write the contents of the program into a controller.

Specify the number of a program written in ProgramNumber parameter.

Specify the buffer which set up the program written in a MS_Data parameter.

It can be used only by the controller which has a program function.

This method cannot be used when a model is SHOT-102/602/PAT001.

An axial number is not related and writes the contents of the program by every axial number. ※Since communication may become unstable by USB in the case of a program which exceeds

1000 lines, it cannot recommend. SetProgram(ByVal ProgramNumber As Integer, ByRef PG_Data As String) As Boolean

Parameter: ProgramNumber (The program number to write: 1/2)

MS_Data (The program to write in)

Return value: True (Normal end) / False (Error)

[Example]

Dim buffer As String

buffer = "1,0,10,20,0,1,0" + vbCrLf + "2,99,-,-,-,-,-" + vbCrLf

rtn = SgnetXctl1.Axes(1).SetProgram(1, buffer) ・・・ Write the contents of the program 1

■StartProgram

Start the program in a controller.

If this method is performed, a controller will become a program mode, will start the program

of the specified number, and will return to host mode.

Specify the number of the program to start as a ProgramNumber parameter.

Specify mode of operation as a CompMode parameter. If True is specified with a CompMode

parameter, this method will not return until a program is completed. If False is specified, it

returns immediately, but it is necessary to check the operating state of a program etc. by the

user side.

It can be used only by the controller which has a program function.

This method cannot be used when a model is SHOT-102/602/PAT001.

An axial number is not related and starts the program by every axial number.

StartProgram(ByVal ProgramNumber As Integer,

Optional ByVal CompMode As Boolean = False) As Boolean

Parameter: ProgramNumber (The program number to start: 1/2)

CompMode (mode of operation: True = Return after the completion of

processing / False = Return immediately)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).StartProgram(1,True) ・・・ Start program 1

55

Page 59: SGNETX Software Manual

■CancelProgram

Stop the program under operation in a controller.

If this method is performed, the program under operation will be stopped and a controller will

be returned to host mode.

It can be used only by the controller which has a program function.

This method cannot be used when a model is SHOT-102/602/PAT001.

An axial number is not related and stops the program by every axial number.

CancelProgram() As Boolean

Parameter: None

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).CancelProgram ・・・ Stop the program under operation

■Wait

Wait for operation of a stage during the specified time (second).

Waits by the controller side from movement of a stage to the next movement during the time

specified with the WTime parameter.

※For details, refer to the manual of the controller.

It can be used only by the controller which has a wait function.

This method cannot be used when a model is SHOT-102/602/PAT001/FINE-501/502/503.

An axial number is not related and waits by every axial number.

Wait(ByVal WTime As Integer) As Boolean

Parameter: WTime (Wait time (1~2550→0.1~255.0 second))

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).Wait(1) ・・・ Sets up a wait for 0.1 seconds.

56

Page 60: SGNETX Software Manual

■Remote

Operate the internal program of a controller in a remote state.

Specify contents of operation with a Func parameter.

Specify the program number to operate with a PgNumber parameter.

※For details, refer to the manual of the controller.

It can be used only by the controller which has a remote function.

This method cannot be used when a model is SHOT-102/602/PAT001/FINE-501/502/503.

An axial number is not related and can perform remote operation by every axial number.

Remote(ByVal Func As Integer, Optional ByVal PgNumber As Integer = 1)

As Boolean

Parameter: Func (Function type:

1→Go into remote mode / 2→Return to host mode /

3→Set program number / 4→Start program /

5→Stop program / 6→Pause program /

7→Cancel a program pause /

8→Disable transmission of completion signal /

9→Enable transmission of completion signal /

10→Disable transmission of trigger signal /

11→Enable transmission of trigger signal)

PgNumber (Program number: 1/2)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).Remote(1) ・・・ Go into remote mode

rtn = SgnetXctl1.Axes(1).Remote(2) ・・・ Return to host mode

rtn = SgnetXctl1.Axes(1).Remote(3,1) ・・・ Set program number as 1

rtn = SgnetXctl1.Axes(1).Remote(4) ・・・ Start program

rtn = SgnetXctl1.Axes(1).Remote(5) ・・・ Stop program

rtn = SgnetXctl1.Axes(1).Remote(6) ・・・ Pause program

rtn = SgnetXctl1.Axes(1).Remote(7) ・・・ Cancel a program pause

rtn = SgnetXctl1.Axes(1).Remote(8) ・・・ Disable transmission of completion signal

rtn = SgnetXctl1.Axes(1).Remote(9) ・・・ Enable transmission of completion signal

rtn = SgnetXctl1.Axes(1).Remote(10) ・・・ Disable transmission of trigger signal

rtn = SgnetXctl1.Axes(1).Remote(11) ・・・ Enable transmission of trigger signal

57

Page 61: SGNETX Software Manual

■IOcommand

Input and output the I/O signal of a controller.

When a Mode parameter is Ture (Out), output the value set as OutData.

When a Mode parameter is False (In), input the signal from a controller.

※For details, refer to the manual of the controller.

It can be used only by the controller which has a I/O function.

This method cannot be used when a model is SHOT-102/602/FINE-501/502/503.

An axial number is not related and can input and output the I/O signal by every axial number.

IOcommand(ByVal Mode As Boolean, Optional ByVal OutData As Integer = 0)

As String

Parameter: Mode (Input output: True = Out / False = In)

OutData (Output data: 0~15)

Return value: In the case of an output (Out) → ”OK” (Normal end) / “NG” (Error)

In the case of a input (In) → Input data (“0”~”15”)

[Example]

Dim rtn As String

rtn = SgnetXctl1.Axes(1).IOcommand(True, 7) ・・・ Output 7

rtn = SgnetXctl1.Axes(1).IOcommand(False) ・・・ input data

58

Page 62: SGNETX Software Manual

■Trigger

Output a trigger signal from a controller.

Specify the functional type of a trigger output with a Func parameter.

Specify a setup required according to a function with Timer, Axis, and a Pulse parameter.

※For details, refer to the manual of the controller.

It can be used only by the controller which has a trigger function.

This method cannot be used when a model is SHOT-102/602/PAT001/FINE-501/502/503.

An axial number is not related and can output a trigger signal by every axial number.

Trigger(ByVal Func As Integer, Optional ByVal Timer As Integer = 1,

Optional ByVal Axis As Integer = 1,

Optional ByVal Pulse As Integer = 100) As Boolean

Parameter: Func (Functional type: 1→Set timer / 2→Set pulse /

3→prohibits output of pulse /

4→output one time)

Timer (Value of timer: 1~10000 → 0.01~100.00 seconds)

Axis (The object axis at the time of pulse specification: 1 or 2)

Pulse (value of pulse: 2~30000)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).Trigger(1,100)

・・・ Output a trigger by timer specification (1 second).

rtn = SgnetXctl1.Axes(1).Trigger(2,,1,100)

・・・ Output a trigger by pulse specification (1 axis 100 pulse).

rtn = SgnetXctl1.Axes(1).Trigger(3) ・・・ Prohibit the trigger output in pulse specification.

rtn = SgnetXctl1.Axes(1).Trigger(4) ・・・ Output a trigger once.

59

Page 63: SGNETX Software Manual

■MoveLine

Move stages by straight line motion (linear interpolation).

Specify final point coordinates by a pulse by EndX and EndY parameter.

※For details, refer to the manual of the controller.

If True is specified with a Mode parameter, this method will return, shortly after starting

movement. (Since after a return will be in a busy state, it is necessary to perform the next

processing after checking a ready by the user side.)

If False is specified with a Mode parameter, (or nothing is specified) this method will make

movement start, and processing will be completed, and if it will be in a ready state, it will

return.

It can be used only by the controller which has a straight line motion function.

This method cannot be used when a model is SHOT-102/602/PAT001/FINE-501/502/503.

Although an axial number is not related and can move stages by straight line motion by every

axial number , it is only 1st axis and 2nd axis that it can be used.

MoveLine(ByVal EndX As Long, ByVal EndY As Long,

Optional ByVal Mode As Boolean = False) As Boolean

Parameter: EndX (Final point coordinates of the X-axis (1st axis))

EndY (Final point coordinates of the Y-axis (2nd axis))

Mode (Mode of operation: True = Return immediately / False = Return after a ready)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).MoveLine(100,200)

・・・ Move by linear interpolation by 1st axis 100 pulse and 2nd axis 200 pulse.

60

Page 64: SGNETX Software Manual

■MoveCircle

Move stages by circular motion (cirle interpolation).

Specify final point coordinates by a pulse by EndX and EndY parameter.

Specify central point coordinates by a pulse by CenX and CenY parameter.

※For details, refer to the manual of the controller.

If True is specified with a Mode parameter, this method will return, shortly after starting

movement. (Since after a return will be in a busy state, it is necessary to perform the next

processing after checking a ready by the user side.)

If False is specified with a Mode parameter, (or nothing is specified) this method will make

movement start, and processing will be completed, and if it will be in a ready state, it will

return.

It can be used only by the controller which has a circular motion function.

This method cannot be used when a model is SHOT-102/602/PAT001/FINE-501/502/503.

Although an axial number is not related and can move stages by circular motion by every axial

number , it is only 1st axis and 2nd axis that it can be used.

MoveCircle(ByVal EndX As Long, ByVal EndY As Long, ByVal CenX As Long,

ByVal CenY As Long, Optional ByVal Mode As Boolean = False) As Boolean

Parameter: EndX (Final point coordinates of the X-axis (1st axis))

EndY (Final point coordinates of the Y-axis (2nd axis))

CenX(Central point coordinates of the X-axis (1st axis))

CenY(Central point coordinates of the Y-axis (2nd axis))

Mode (Mode of operation: True = Return immediately / False = Return after a ready)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).MoveLine(0,0,2000,10) ・・・ Move by cirle interpolation by the 1st axis and the 2nd axis

at a final point (0, 0) and the center (2000, 100).

61

Page 65: SGNETX Software Manual

■Get_Volt

Obtain applied voltage.

This method can be used only when a model is FINE-501/502/503.

It cannot specify all axes.

Get_Volt() As Double

Parameter: None

Parameter: Value of applied voltage

[Example]

Dim Vt As Double

Vt = SgnetXctl1.Axes(1).Get_Volt ・・・ Obtain the applied voltage of the 1st axis of a stage.

■Get_Hysteresis

Set up hysteresis data acquisition.

This method can be used only when a model is FINE-501/502/503.

An axial number is not related and can set up by every axial number.

Get_Hysteresis() As Boolean

Parameter: None

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).Get_Hysterresis ・・・ Set up hysteresis data acquisition.

■Set_Track

Change Tracking or Lock mode.

This method can be used only when a model is FINE-501/502/503.

An axial number is not related and can set up by every axial number.

Set_Track(ByVal Mode As Boolean) As Boolean

Parameter: Mode (True: Tracking mode / False: Lock mode)

Return value: True (Normal end) / False (Error)

[Example]

Dim rtn As Boolean

rtn = SgnetXctl1.Axes(1).Set_Track(True) ・・・ Set it as tracking mode.

62

Page 66: SGNETX Software Manual

3.12 SGNETX events

■SG_WriteEnd

It occurs by the end of SG_Write.

SG_WriteEnd(ByVal InterfaceKind As Integer, ByVal ID As Integer)

Parameter: InterfaceKind (Communication type),

ID (Connection place)

[Example]

Private Sub SgnetXctl1_SG_WriteEnd(ByVal InterfaceKind As Integer,

ByVal ID As Integer) Handles SgnetXctl1.SG_WriteEnd

■SG_ReadEnd

It occurs by the end of SG_Read. SG_ReadEnd(ByVal InterfaceKind As Integer, ByVal ID As Integer)

Parameter: InterfaceKind (Communication type),

ID (Connection place)

[Example]

Private Sub SgnetXctl1_SG_ReadEnd(ByVal InterfaceKind As Integer,

ByVal ID As Integer) Handles SgnetXctl1.SG_ReadEnd

63

Page 67: SGNETX Software Manual

4. Programming This chapter explains the programming method by SGNETX.

※The program explained in this chapter has omitted description of error handling etc.

4.1 Programming using a fixed form function

Create the program which operates a controller by using the fixed form function which SGNETX

has.

Start VisualBasic.NET, select a "VisualBasic project" and "Windows application" from "a new

project", and create a project newly.(.NET Framework3.5 is surely chosen.) ※Please understand that windows composition differs from the text in part by the version (2008/2010) of

VB.NET.

Fig. 4-1

64

Page 68: SGNETX Software Manual

Attach SGNETXctl on Form1 from a tool box.

Fig. 4-2

Attach a button on Form1 from a tool box.

Fig. 4-3

Attach a total of seven buttons on Form1, and arrange as shown in the following figure.

Button7

Button6

Button5

Button4

Button3

Button2

SgnetXctl

Button1

Fig. 4-4

65

Page 69: SGNETX Software Manual

Input the following code on a window of Form1.vb [Design].

List 4-1

66

Page 70: SGNETX Software Manual

After inputting of the code and “Build”, the created application will operate if you perform it. If

you click a button, a regular form window is displayed and you can perform various kinds of

setup and operations.

Controller Settings Form

Axis Control Form

End a program

Terminal Form

Communication Settings Form

Communication connection Form

Loading of the USB driver at the time of USB use

Fig. 4-5

67

Page 71: SGNETX Software Manual

4.2 Programming which uses RS232C

Create the program in the case of controlling stage controller SHOT-204MS by RS232C.

As created in Chapter 4.1, the fixed form currently prepared by SGNETX can also be used, but

create by the method of describing by a program without form here.

After creating a project newly like Chapter 4.1, attach SGNETXctl and buttons on Form1 and

arrange them as shown in the following figure.

TextBox2

Button4

Button3

Button2

TextBox1

Button1

SgnetXctl

Fig. 4-6

68

Page 72: SGNETX Software Manual

Input the following code on a window of Form1.vb [Design].

List 4-2

After inputting of the code and “Build”, the created application will operate if you perform it. If

you click a button, each function will operate.

End a program.

Specify the amount of movements of a stage.

Return a stage to machine origin.

Move a stage by a specified amount

The current position of a stage is displayed on real time.

The conditions of a controller and RS232C are set up and communication is connected.

Fig. 4-7

69

Page 73: SGNETX Software Manual

4.3 Programming which uses GPIB

Create the program in the case of controlling stage controller SHOT-102 by GPIB.

As created in Chapter 4.1, the fixed form currently prepared by SGNETX can also be used, but

create by the method of describing by a program without form as well as Chapter 4.2 here.

Although the program to create is completely the same as Chapter 4.2, only the contents of

"Button1_Click" differ.

Please create a program like Chapter 4.2 and change only the contents of "Button1_Click" below.

List 4-3

After inputting of the code and “Build”, the created application will operate like Chapter 4.2 if

you perform it.

70

Page 74: SGNETX Software Manual

4.4 Programming which uses USB

Create the program in the case of controlling stage controller FINE-503 by USB.

As created in Chapter 4.1, the fixed form currently prepared by SGNETX can also be used, but

create by the method of describing by a program without form as well as Chapter 4.2 or 4.3 here.

※To use USB, it is required to install a USB driver.

Although the program to create is completely the same as Chapter 4.2 or 4.3, the contents of

"Button1_Click" differ. And in order to perform loading and the unload of a USB driver,

processing of "Form1_Load", "Form1_Closing" and declaration of a variable "USB_Flag" are

added.

Please create a program like Chapter 4.2 or 4.3, change the contents of "Button1_Click" below,

declare a variable "USB_Flag", and add processing of "Form1_Load", "Form1_Closing".

List 4-4

After inputting of the code and “Build”, the created application will operate like Chapter 4.2 or

4.3 if you perform it. ※Since movement of a stage is high-speed as the controller of a FINE system, most current positions under

movement are not displayed.

71

Page 75: SGNETX Software Manual

4.5 Programming which controls two or more axes and two or more controllers

Create the program in the case of changing the control axis of a stage or controlling two or more

stage controllers.

Create a project newly and attach two SGNETXctls on Form1 from a tool box.

Fig. 4-8

Attach buttons and text boxes on Form1 and arrange them as shown in the following figure.

TextBox6

TextBox4

TextBox1

TextBox3

Button7

TextBox5

Button9

SgnetXctl

Button11

Button10

Button8

TextBox2

Button6

Button4

Button2SgnetXctl

Button5

Button3

Button1

Fig.4-9

72

Page 76: SGNETX Software Manual

Input the following code on a window of Form1.vb [Design].

List 4-5

※Continues to the following page.

73

Page 77: SGNETX Software Manual

List 4-6

74

Page 78: SGNETX Software Manual

After inputting of the code and “Build”, the created application will operate and each function

will operate if you perform it.

End a program. Fig. 4-10

Set up the conditions of an operation of a controller etc.

Operation of the 2nd controller

Operation of the 1st controller

Return the stage of an object axis to mechanical origin.

Specify the amount of movements of a stage.

Move the stage of an object axis by a specified amount.

The current position of the axis for operation is displayed as real time.

Specify the axis for operation. All axes are objects when 0 is specified.

This example has described the contents which control two or more controllers and the the

contents which control two or more stage axes by one program.

Although a condition setup of a controller etc. was here performed by displaying fixed form, the

method of describing by a program like the example of Chapter 4.2-4.4 is also possible.

Please refer to these examples and create the program according to a user's environment.

75