Client Control Interface
Client Control Interface
Table of Contents
1 .........................................................................................................................
Introduction 7
2 .........................................................................................................................
Base Functions 8
3.........................................................................................................................
Application 15
4.1 View
.............................................................................................................. 26
4.2 Optic
.............................................................................................................. 28
4.2.1 Min
.......................................................................................................
/ Max ... 36
4.2.2 Advanced
....................................................................................................... 39
4.2.2.1 ................................................................................................
Head Optic Settings 41
4.2.2.2 ................................................................................................
MOTF hardware settings 44
4.3 General
.............................................................................................................. 47
4.4 Remote
.............................................................................................................. 47
4.5 I/O
.............................................................................................................. 48
4.6 Extras
.............................................................................................................. 50
4.7 Splitting
.............................................................................................................. 50
4.8 User level
.............................................................................................................. 52
4.9 sc_setup
.............................................................................................................. 53
5.........................................................................................................................
Pen Settings 56
6.........................................................................................................................
Job 81
7.1 ..............................................................................................................
Direct motion home 175
7.2 ..............................................................................................................
Direct motion move 175
7.3 ..............................................................................................................
Direct motion RS-232 179
7.4 ..............................................................................................................
Direct motion status 180
7.5 ..............................................................................................................
Direct motion stop 181
8 Inputs and Outputs
......................................................................................................................... 181
9 Mark
......................................................................................................................... 190
9.1 ..............................................................................................................
Mark Dialog 193
9.1.1.......................................................................................................
Red Pointer 194
9.2 ..............................................................................................................
Trigger Dialog 195
9.3 ..............................................................................................................
Mark Preview 196
9.4 ..............................................................................................................
Mark Sequence 196
9.5 ..............................................................................................................
Mark Time 197
9.6 ..............................................................................................................
Mark Counter 198
10 Splitting
......................................................................................................................... 200
11.1 3D Surfaces
.............................................................................................................. 221
12 Option SAM3D
......................................................................................................................... 227
19 Deprecated commands
......................................................................................................................... 317
1 Introduction
Welcome to our new client control documentation. In the past, this documentation was part of the SAMLight
manual. As the Client Control Interface (CCI) was growing and growing we decided that a separate manual
with a more user friendly structure and detailed descriptions of the commands including the definition and
explanation of all relevant parameters as well as an easy example for each function was necessary.
If there are any questions or problems related to our documentation, feel free to contact us.
This manual will teach and show you how to remote control SAMLight from another software via a CCI
application. The following chapters specify the main base functions used in combination with their constants
as well as some programming examples and give tips to optimize the performance.
The basic structure of this manual follows the structure in the SAMLight manual. Each chapter of the
SAMLight manual can be found in a similar way here if any relevant commands do exist. The amount of
functions in SAMLight is huge - not all functions are also available in CCI. If there is a command missing in
your opinion, feel free to contact us.
Client Control can be done via one of the following ways (further details in implementation):
· Function calls
o OCX - ActiveX
o COM
· ASCII commands
Regarding the function calls, the OCX (ActiveX) control SCAPS.ScSamlightClientCtrl and the COM (CCI Ex)
control SCAPS.ScSamlightClientCtrlEx are providing function commands to remote control SAMLight from
another software. This allows fast development of automation with different Windows development
environments. OCX and COM can be used with a 32-bit or a 64-bit custom software. In addition CCI can be
used without the OCX or COM encapsulation. In this case, plain ASCII commands are sent via TCP from a
different system which does not need to be a Windows PC.
These three different ways to realize CCI are illustrated and described in further detail in the following
(images always show the connection to a USC card, but CCI of course can also be used together with an
RTC card.):
2.CCI Function commands (OCX or COM) via TCP © 2022 SCAPS GmbH
Client Control Interface Manual - Introduction 8
2 Base Functions
This chapter explains some of the major functions needed to realize a CCI application. These basic
commands can then be used in combination with the CCI constants. For each function, a small example in
C# is given.
The commands given in this chapter are:
· DoubleValue
· EntityDoubleData
· EntityLongData
· EntityStringData
· ExecCommand
· IDStringData
· LongValue
· StringValue
DoubleValue Set
Get
DLL Function int CCI_Return = ScSetDoubleValue(int Value_Type, double Parameter)
double Parameter = ScGetDoubleValue(int Value_Type)
ASCII Function int CCI_Return = ScCciSetDoubleValue(int Value_Type, double Parameter)
double Parameter = ScCciGetDoubleValue(int Value_Type)
Description This is the definition of the base function to use Double Value Types. The function
needs two arguments: Value_Type and Parameter. The available Value_Types are
listed at List of Constants Double Value Types.
Value_Type Type: int
Location: ScComSAMLightClientCtrlValueTypes
See available Double Value Types.
Parameter Type: double Unit: depends on constant
Further details are given in Double Value Types.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: How to use DoubleValue Types:
EntityDoubleData Set
Get
DLL Function int CCI_Return = ScSetEntityDoubleData(string Entity_Name, int Data_ID, double Parameter)
int CCI_Return = ScGetEntityDoubleData(string Entity_Name, int Data_ID, ref double Parameter)
ASCII Function int CCI_Return = ScCciSetEntityDoubleData(string Entity_Name, int Data_ID, double Parameter)
double Parameter = ScCciGetEntityDoubleData(string Entity_Name, int Data_ID)
Description This is the definition of the base function to use Entity Double Data IDs. The function
needs two/three arguments: Entity_Name, Data_ID and Parameter. Sometimes the
function returns the parameter or the parameter has to be initialized before. The
available Data_IDs are listed at List of Constants Double Data IDs.
Entity_Name Type: string Unit: none
Specify the entity based on the name.
Data_ID Type: int
Location: ScComSAMLightClientCtrlFlags
See available Double Data IDs.
Data_ID can be combined with:
· scComSAMLightClientCtrlDoubleDataIdFlagDontUpdateView 0x10000 (set only)
The view will not be updated to increase the performance.
· scComSAMLightClientCtrlDoubleDataIdFlagDontUpdateEntity 0x20000 (set only)
The vectors will not be updated to increase the performance.
· scComSAMLightClientCtrlDoubleDataIdFlagToplevelOnly 0x40000
Only entities in the top level of the job will be considered to increase the
performance.
Parameter Type: double Unit: none
Set or get the required data. Further details are given in the Double Data IDs.
CCI_Return Type: int
CCI return number, see error list.
Notes · Set function also available for SAM3D. No get function.
C# Example: How to use EntityDoubleDataIDs:
EntityLongData Set
Get
DLL Function int CCI_Return = ScSetEntityLongData(string Entity_Name, int Data_ID, int Parameter)
int Parameter = ScGetEntityLongData(string Entity_Name, int Data_ID)
ASCII Function int CCI_Return = ScCciSetEntityLongData(string Entity_Name, int Data_ID, int Parameter)
int Parameter = ScCciGetEntityLongData(string Entity_Name, int Data_ID)
Description This is the definition of the base function to use Entity Long Data IDs. The function
needs two/three arguments: Entity_Name, Data_ID and Parameter. Sometimes the
function returns the parameter or the parameter has to be initialized before. The
available Data_IDs are listed at List of Constants Long Data IDs.
Entity_Name Type: string Unit: none
Specify the entity based on the name.
Data_ID Type: int
Location: ScComSAMLightClientCtrlFlags
See available Long Data IDs.
Data_ID can be combined with following ScComSAMLightClientCtrlFlags:
· scComSAMLightClientCtrlLongDataIdFlagDontUpdateView 0x10000 (set only)
The view will not be updated to increase the performance.
· scComSAMLightClientCtrlLongDataIdFlagDontUpdateEntity 0x20000 (set only)
The vectors will not be updated to increase the performance.
Parameter Type: int Unit: none
See available Long Data IDs.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: How to use EntityLongDataIDs:
EntityStringData Set
Get
DLL Function int CCI_Return = ScSetEntityStringData(string Entity_Name, int Data_ID, string Parameter)
int CCI_Return = ScGetEntityStringData(string Entity_Name, int Data_ID, ref string Parameter)
ASCII Function int CCI_Return = ScCciSetEntityStringData(string Entity_Name, int Data_ID, string Parameter)
string Parameter = ScCciGetEntityStringData(string Entity_Name, int Data_ID)
Description Set or get specific string data of an entity Entity_Name depending on the Data_ID.
Entity_Name Type: string Unit: none
Specify the entity based on the name.
Data_ID Type: int
Location: ScComSAMLightClientCtrlFlags
See available Entity String Data IDs.
Data_ID can be combined with following ScComSAMLightClientCtrlFlags:
· scComSAMLightClientCtrlStringDataIdFlagDontUpdateView 0x10000 (set only)
The view will not be updated to increase the performance.
· scComSAMLightClientCtrlStringDataIdFlagDontUpdateEntity 0x20000 (set only)
The vectors will not be updated to increase the performance.
· scComSAMLightClientCtrlStringDataIdFlagToplevelOnly 0x200000
Only entities in the top level of the job will be considered to increase the
performance.
Parameter Type: string Unit: none
The corresponding value.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: How to use Entity String Data IDs
Description This is the definition of the base function to use Excec Commands. Only the Cmd_ID
has to be given. The available Cmd_IDs are listed at List of Constants Cmd ID.
Cmd_ID Type: int
Location: ScComSAMLightClientCtrlExecCommandConstants
See available Cmd IDs.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: How to use Exec Commands:
IDStringData Set
Get
DLL Function int CCI_Return = ScSetIDStringData(int Data_ID, int Index, string Parameter)
int CCI_Return = ScGetIDStringData(int Data_ID, int Index, ref string Parameter)
ASCII Function int CCI_Return = ScCciSetIDStringData(int Data_ID, int Index, string Parameter)
string Parameter = ScCciGetIDStringData(int Data_ID, int Index)
Description Set or get specific string data of an entity by Index depending on the Data_ID.
Data_ID Type: int
Location: ScComSAMLightClientCtrlValueTypes
See available ID String Data IDs.
Index Type: int Unit: none
0 based entity index of current job.
Index can be combined with following ScComSAMLightClientCtrlFlags:
· scComSAMLightClientCtrlStringDataIdFlagDontUpdateView 0x10000 (set only)
The view will not be updated to increase the performance.
· scComSAMLightClientCtrlStringDataIdFlagDontUpdateEntity 0x20000 (set only)
The vectors will not be updated to increase the performance.
· scComSAMLightClientCtrlStringDataIdFlagToplevelOnly 0x200000
Only entities in the top level of the job will be considered to increase the
performance.
Parameter Type: string Unit: none
The corresponding value.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: How to use ID String Data IDs
LongValue Set
Get
DLL Function int CCI_Return = ScSetLongValue(int Value_Type, int Parameter)
int Parameter = ScGetLongValue(int Value_Type)
ASCII Function int CCI_Return = ScCciSetLongValue(int Value_Type, int Parameter)
int Parameter = ScCciGetLongValue(int Value_Type)
Description This is the definition of the base function to use Long Value Types. The function
needs two arguments: Value_Type and Parameter. The available Value_Types are
listed at List of Constants Long Value Types.
Value_Type Type: int
Location: ScComSAMLightClientCtrlValueTypes
See available Long Value Types.
Parameter Type: int Unit: depends on constant
Further details are given in Long Value Types.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: How to use Long Value Types
StringValue Set
Get
DLL Function int CCI_Return = ScSetStringValue(int Value_Type, string Parameter)
int CCI_Return = ScGetStringValue(int Value_Type, ref string Parameter)
ASCII Function int CCI_Return = ScCciSetStringValue(int Value_Type, string Parameter)
string Parameter = ScCciGetStringValue(int Value_Type)
Description This is the definition of the base function to use String Value Types. The function
needs two arguments: Value_Type and Parameter. The available Value_Types are
listed at List of Constants String Value Types.
Value_Type Type: int
Location: ScComSAMLightClientCtrlValueTypes
See available String Value Type.
Parameter Type: string Unit: none
See available String Value Types.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: How to use String Value Types
3 Application
The following commands can be used to check the global state of the system. There is a subchapter for:
· Async Mode
· Change View2D
· Check Communication
· Connection Status
· Entity List/Property Sheet
· Extended Error Mode
· Mode
· SAMLight ShutDown
· SAMLight Status
· SAMLight Window
· Simulation Mode
· Update View2D
· Write Trail
Description SAMLight pops up a test message box to check the communication between the CCI
application and SAMLight.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandTest 1
CCI_Return Type: int
CCI return number, see error list.
Notes · The message box that has to be closed manually.
· The command returns after the message box is closed.
C# Example: Check communication:
int CCI_Return = cci.ScExecCommand( ( int )
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandTest );
Table 10: Check Communication
Description SAMLight pops up a cci test message box to check the communication between the
CCI application and SAMLight.
Message Type: string Unit: none
This string will be part of the message in the message box.
CCI_Return Type: int
CCI return number, see error list.
Notes · The command returns immediately.
· The message box that has to be closed manually.
ASCII Example: Send a test message to SAMLight:
ScCciTest("Test message.")<LF>
Table 11: Connection Status
Mode Set
Get
DLL Function int CCI_Return = ScSetMode(int Mode)
int CCI_Return = ScGetMode(ref int Mode)
ASCII Function int CCI_Return = ScCciSetMode(int Mode)
int Mode = ScCciGetMode()
Description Set or get global SAMLight parameters by combining following flags.
Mode Type: int Flag:
Location: ScComSAMLightClientCtrlFlags
scComSAMLightClientCtrlModeFlagTopLevelOnly 0x1
The next calls only search for objects in the top level of the job. This can be helpful
to increase the performance.
scComSAMLightClientCtrlModeFlagDontUpdateView 0x2
Suppress drawing of entities in the view or in the entity list. This can be helpful to
increase the performance.
scComSAMLightClientCtrlModeFlagDisableFileCompression 0x10
Checks the check box Disable file compression in Settings System General.
scComSAMLightClientCtrlModeFlagEntityNamesSeparatedBySemicolon 0x20
The parameter Entity_Name in ScMarkEntityByName and others can include more
than one entity name. They have to be separated by a semicolon. If the client control
is used via a TCP connection then the maximum length of the parameter
Entity_Name is 512 characters (511 + an ending zero).
scComSAMLightClientCtrlModeFlagDisableUndo 0x4000
Checks the checkbox Disable Undo in Settings System General, which
disables Undo function.
scComSAMLightClientCtrlModeFlagArrayCopyAdapt 0x8000
ArrayCopy of a serial number results in an array of serial numbers where the copies
are enumerated from the number of the original one up to n. If not checked all copies
will get the same number as the original one.
scComSAMLightClientCtrlModeFlagArrayCopyAssociate 0x10000
This function is useful for creating multiple serial numbers with a complex sequence.
If checked the ArrayCopy of two and more different serial numbers results in one
serial so that no serial number gets repeated. This check button is only enabled if
Adapt is selected and association is possible. Creating one serial after an array copy
is only possible if the actual values of the current serial differ in a constant step.
CCI_Return Type: int
CCI return number, see error list.
Notes · To prevent incorrect operation please read chapter How to work with flags
· For more information about Performance optimization under usage of these flags,
please refer to Optimize Performance chapter.
C# Example: Enable Don't Update View and don't change all other flags:
int Mode = 0;
int CCI_Return_01 = cci.ScGetMode( ref Mode );
Mode = Mode | ( int )ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagDontUpdateView;
int CCI_Return_02 = cci.ScSetMode( Mode );
C# Example: Disable Don't Update View and don't change all other flags:
int Mode = 0;
int CCI_Return_01 = cci.ScGetMode( ref Mode );
Mode = Mode & ~( int )ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagDontUpdateView;
int CCI_Return_02 = cci.ScSetMode( Mode );
ASCII Function -
Description Can be used for checking whether the scanner application software is running or not.
Is_Running Type: int Unit: none
· 0: SAMLight doesn't run or is not found.
· 1: SAMLight runs.
Notes · If this function returns 0, it makes no sense to use any other CCI commands.
C# Example: Check SAMLight status:
Description Set SAMLight into one of the common show states of Windows.
Window_Properties Type: int Unit: none
· 0: Hide SAMLight.
· 2: Minimize SAMLight.
· 3: Maximize SAMLight.
· 5: Show SAMLight and display it in its current size and position.
· 9: Show SAMLight and restore its original size and position, if it is minimized or
maximized.
CCI_Return Type: int
CCI return number, see error list.
Notes · You can set only one index simultaneously.
C# Example: Hide the SAMLight window:
// With enabled async mode the CCI commmand returns immediately without returning an answer.
double dummy = cci.ScGetEntityOutline( "Circle", 0 );
do
{
// Your operations while async CCI command executes.
}
// Check if cci command is completed.
while( cci.ScGetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeClientCtrlAsyncModeIsRunning ) !=
0 );
// Get the return double value of async CCI command.
double Entity_Outline = cci.ScGetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeAsyncModeResult );
Table 23: DoubleValue Async
// With enabled async mode the CCI commmand returns immediately without returning an answer.
int dummy = cci.ScExecCommand( ( int )
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandNewJob );
do
{
// Your operations while async CCI command executes.
}
// Check if cci command is completed.
while( cci.ScGetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeClientCtrlAsyncModeIsRunning ) !=
0 );
// Get the integer cci return of async CCI command.
int CCI_Return = cci.ScGetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeClientCtrlAsyncModeResult );
Table 24: LongValue Async
4 Global Settings
The following chapter will guide you through the commands used to set up the main parameters and global
settings. In SAMLight this functions can be found at Settings System. The main structure follows the
structure of SAMLight. In total there are more tabs at Settings System than subchapters. Not all options
in SAMLight are also implemented in CCI, meaning that if one tab is not listed as subchapter here, then we
do not have any commands for this tab. Even not all functions of SAMLight are also available in CCI. There
is an additional subsection sc_setup, which was located here.
· View
· Optic
· General
· Remote
· I/O
· Extras
· Splitting
· User Level
· sc_setup
4.1 View
This subchapter refers in SAMLight to Settings System View to change the Toolbar settings.
4.2 Optic
The following parameters can be found in SAMLight at Settings System Optic. It could be that not all
parameters or options are given here. This subchapter lists all available options for this dialog. Here you can
go deeper into detail at the following buttons, which contain further options:
· Min / Max
· Advanced
Gain Set
Get
DLL Function int CCI_Return = ScSetDoubleValue(int Value_Type, double Gain)
double Gain = ScGetDoubleValue(int Value_Type)
ASCII Function int CCI_Return = ScCciSetDoubleValue(int Value_Type, double Gain)
double Gain = ScCciGetDoubleValue(int Value_Type)
Description Set or get the gain x/y correction factor of the optic.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlDoubleValueTypeGainX 46
Set or get the gain x correction factor of the optic.
scComSAMLightClientCtrlDoubleValueTypeGainY 47
Set or get the gain y correction factor of the optic.
Gain Type: double Unit: none
Set or get the gain factor for x or y.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Set gain X:
Offset Set
Get
DLL Function int CCI_Return = ScSetDoubleValue(int Value_Type, double Offset)
double Offset = ScGetDoubleValue(int Value_Type)
ASCII Function int CCI_Return = ScCciSetDoubleValue(int Value_Type, double Offset)
double Offset = ScCciGetDoubleValue(int Value_Type)
Description Set or get the Offset x/y correction factor of the optic.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlDoubleValueTypeOffsetX 58
Set or get the offset x correction factor of the optic.
scComSAMLightClientCtrlDoubleValueTypeOffsetY 59
Set or get the offset y correction factor of the optic.
scComSAMLightClientCtrlDoubleValueTypeOffsetZ 90
Only for RTC cards. Set or get the offset z correction factor of the optic in
sc_setup.exe. Requires Optic3D license.
Offset Type: double Unit: [mm]*
Set offset factor for x/y/z.
CCI_Return Type: int
CCI return number, see error list.
Notes · Z Offset can only be set in sc_setup.
· The default unit is mm, but the user can select a different unit.
C# Example: Set offset X:
4.2.2 Advanced
The following parameters can be found in SAMLight at Settings System Optic Advanced.
The CCI commands for inputs, outputs and output inversions are described here.
· Is Card Allowed
· Load from USC3
· Restore Transformation
· Store Flash Settings
Description Load the current stored settings from the USC3 in SAMLight.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandLoadHeadFromUSC3 64
CCI_Return Type: int
CCI return number, see error list.
Notes · Only for USC3
· Only head specific settings are loaded.
C# Example: Load current settings from USC3:
Description Store the matrix of each entity, recover them and update if needed. Mark, then shift
and get later original positions back.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeStoreRestoreTransformation 32
Index Type: int Index:
Location: None
RESTORE_TRANSFORMATION_STORE 0x0
RESTORE_TRANSFORMATION_RESTORE 0x1
RESTORE_TRANSFORMATION_RESTORE_WITH_UPDATE 0x2
CCI_Return Type: int
CCI return number, see error list.
Description Stores the settings to the USC-card EPCS (this is necessary for stand-alone
operation). Make sure that the settings fit to the laser and other machinery. The
settings will be loaded during powering on the card.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandStoreFlashSettings 58
CCI_Return Type: int
CCI return number, see error list.
Notes · Do not use for USC-1 since it has no Flash memory.
C# Example: Store flash settings:
4.3 General
The following parameters can be found in SAMLight at Settings System General.
· Mode Application
o Don't Update View
o DisableUndo
· Save Settings Now
4.4 Remote
The following parameters can be found in SAMLight at Settings System Remote.
· Conntection Status
· Open TCP Connection
ASCII Function -
Description Get the connection state for CCI via TCP.
Status Type: int Index:
Location: ScComConnectionToolCtrlResultValues
scComConnectionToolCtrlResultOK 0
If connected, the return value is 0.
scComConnectionToolCtrlResultOpenFailed 1
The connection could not be opened.
scComConnectionToolCtrlResultConnectRecipientFailed 2
The recipient could not connect.
scComConnectionToolCtrlResultSendFailed 3
ASCII Function -
Description Opens an TCP connection to the scanner application through the network and
returns 1 if the connection could be established successfully. The RecipientAddr is
the IP and the RecipientPort is the Port of the application that has to be accessed
using the client control interface as described above. For the recipient IP in every
case the real IP of the host systems network interface card has to be entered where
the application that has to be remote controlled is running. If that application was
configured using 0.0.0.0 it is not allowed to enter that value here.
Recipient_Address Type: string Unit: none
Set an IP-Address.
Recipient_Port Type: int Unit: none
Set the recipient port.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Open a TCP connection:
4.5 I/O
The following parameters can be found in SAMLight at Settings System I/O.
· Job Toolbar
· Job Execution Delay
· Last Message Input Hardware Status
4.6 Extras
The following parameters for Improved Beam Compensation can be found and only be set in SAMLight at
Settings System Extras.
Description Set or get the status of the SAMLight Improved Beam Compensation.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeEnableImprovedBeamCompensation 137
Improved_Beam_ Type: int Unit: none
Compensation · 0: Disable Improved Beam Compensation
· 1: Enable Improved Beam Compensation
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Enable Improved Beam Compensation:
4.7 Splitting
The following parameters for Ring Splitting can be found and only be set in SAMLight at Settings System
Splitting. In addition there is a Ring Splitting dialog, see Splitting Ring Splitting.
· User Account
· User Logout
4.9 sc_setup
The following commands can not be set in the global settings of SAMLight. Here it is required to open the
sc_setup. Since this are global parameters, these commands are also listed in the global settings.
· DA1/DA2
· Language
· Laser Type
· Z Offset Optic
Description Set the analog output 1 or 2 of the scanner controller card (DAC_A/DA1 or
DAC_B/DA2).
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeDA1 6
Set the analog output 1 of the scanner controller card (DAC_A).
scComSAMLightClientCtrlLongValueTypeDA2 7
Set the analog output 2 of the scanner controller card (DAC_B).
DAC Type: int Unit: none
The values that can be set in principle range from 0 to 65535 (2^16-1). But
depending on USC card and preselected DAC_A/DAC_B voltage signal range of 2.5,
5 and 10V only the 8 to 12 most significant of 16 bits can be actual used to set the
DAC_A/DAC_B value, see Notes below.
CCI_Return Type: int
CCI return number, see error list.
Notes · The commands will just set the output and will not change the pen power.
· For USC-2/-3 card values 2^6-1 correspond to a voltage of 0V of the preselected
DAC_A/DAC_B voltage signal range of 0 to 2.5V, values 2^5-1 correspond to a
voltage of 0V of the preselected DAC_A/DAC_B voltage signal range of 0 to 5V
and values 2^4-1 correspond to a voltage of 0V of the preselected
DAC_A/DAC_B voltage signal range of 0 to 10V. So for USC-2/-3 only the 10,11
or 12 most significant of 16 bits from 2^4-1=15, 2^5-1=31 and 2^6-1=63 to 2^16-
1=65535 can be actual used to set the DAC_A/DAC_B value, which corresponds
to a resolution range between 0 to 1023, 2047 and 4095. For USC-2/-3 the set
value can checked at InfoView of sc_usc_server.exe for Member AnalogOutA and
AnalogOutB.
· For USC-1 card values 2^8-1 = 255 correspond to a voltage of 0V, independent
of the preselected DAC_A/DAC_B voltage signal range of 0 to 2.5, 5 or 10V. So
for USC-1 only the 8 most significant of 16 bits from 2^8-1=255 to 2^16-1=65535
can be actual used to set the DAC_A/DAC_B value, which corresponds to a
resolution range between 0 and 255.
C# Example: Set DAC_A to maximum value value of USC-1/-2/-3 of 2^16-1=65535:
Language Set
Get
DLL Function int CCI_Return = ScGetStringValue(int Value_Type, ref string Language)
5 Pen Settings
The following chapter explains all commands, which can be used to edit the Pen Settings. There are
subchapters for each tab in the SAMLight Pen Settings:
· Advanced Settings
· Main
· Laser-Specials
· Scanner
· Misc
· Drill
· Ramping
· Path
· Bitmap
int PenNumber = 0;
int CCI_Return = cci.ScGetPen( ref PenNumber );
Table 69: Pen Number
Description Returns a set of 7 pen parameters for the defined entity. The return parameters are
described below. It is possible to get the values for multiple entities.
Pen_Number Type: string Unit: none
This string can contain multiple pen numbers separated by semicolon.
Data_ID Type: int ID:
Location: ScComSAMLightClientCtrlFlags
scComSAMLightClientCtrlStringDataIdSpecialPenAndMore 34
Pen_Special Type: string Unit: depends on parameter
The separator for multiple pens is a vertical tab (\v). For each requested pen the
following seven double values with 6 decimal places separated by semicolon are
returned:
· Mark Speed [mm/s*]
· Power [Watt]
· Frequency [Hz]
· CO2_Power1 [%]
· CO2_Power2 [%]
· Pulse_Length [µ s]
· First_Pulse [µ s]
CCI_Return Type: int
CCI return number, see error list.
Notes · If the return string is send via Ethernet, it's maximum length is 512 characters.
· If you enter multiple pen numbers, this function will return sets of values for each
pen. Each set is separated by a vertical tab '\v'.
C# Example: Get the parameters for pen 1:
5.2 Main
The following settings can be made under Mark Edit... Main.
· CO2 Power
· Pen Main Parameters
· Pen Enable Flags, see PenSettings
o LongDelay
o Pen Standby (RTC YAG only)
o Power Control
5.3 Laser-Specials
The existence of this tab depends on the set laser type. It is named after the laser type like given in the
subchapters. There may be not a command for all laser types, but all available commands are given in the
following subchapters for the following types:
· IPG
· SPI
5.3.1 IPG
The following tab is available, if an IPG laser is configured. It can be found via Mark Edit... IPG. The
following commands can be set via CCI:
5.3.2 SPI
The following tab is available, if an SPI laser is configured. It can be found via Mark Edit... SPI. The
following commands can be set via CCI:
· SPI CW Mode
· SPI Waveform
· SPI Simmer Value
5.4 Scanner
The following functions can be found under Mark Edit... Scanner:
5.5 Misc
The following functions can be found under Mark Edit... Misc:
· Defocus
· Pen Enable Flags, see Pen Settings
o SkyWriting
o Defocus
o Apply power changes after jump
o RTC5/6 SkyWriting Enable
o RTC5/6 SkyWriting Mode 0x1
o RTC5/6 SkyWriting Mode 0x2
· SkyWriting parameters
· Pen MarkFlags
Defocus Set
Get
DLL Function int CCI_Return = ScSetDoubleValue(int Value_Type, double Defocus)
double Defocus = ScGetDoubleValue(int Value_Type)
ASCII Function int CCI_Return = ScCciSetDoubleValue(int Value_Type, double Defocus)
double Defocus = ScCciGetDoubleValue(int Value_Type)
Description Set or get the Defocus Value.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlDoubleValueTypeDefocus 62
Defocus Type: double Unit: [mm]*
Defocus value.
CCI_Return Type: int
CCI return number, see error list.
Notes · The pen number has to be set by ScSetPen.
· The default unit is mm, but the user can select a different unit.
C# Example: Set the defocus to 1.0 mm:
5.6 Drill
The following commands can be found under Mark Edit... Drill:
5.7 Ramping
The following commands can be found under Mark Edit... Ramping:
· Ramping Checkboxes
· Ramping Double Parameters
5.8 Path
The following command can be found under Mark Edit... Path
· Pen Path
5.9 Bitmap
The following command can be found under Mark Edit... Bitmap:
· Bitmap Settings
· Pen Enable Flags, see Pen Settings
o Pixel Hardware Mode
o Pen PixelMap
o Pen Power as Max Power
o Use Vector Delays
· Pen Pixel Map
6 Job
The following chapter gos through the main functions to create and edit jobfiles. This chapter is divided into
different subchapters:
· Entity Objects
· Entities Properties
· Data Wizard
Description Remove the current job and creates a new one with empty working area.
Cmd_ID Type: int ID:
Location:ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandNewJob 3
CCI_Return Type: int
CCI return number, see error list.
Notes · ScCciNewJob() is deprecated, please use this ExecCommand.
· The removed jobfile exists on last saving state.
C# Example: Create new job:
ASCII Function -
Description Executes a command in the flash mode. Return is an empty string variable that you
have to declare in advance.
Command Type: string Unit: none
The string Command is the flash command as you would type it in inside the flash
dialog window and it has to be terminated by the ASCII characters 13 and 10 (Return
and LineFeed). For the flash commands see the corresponding hardware manual.
Flag Type: int Unit: none
Flags can be 0 or -2147483648. If 0, the client control waits until a carriage return
from the Flash. If -2147483648 is set the client control will wait a certain time and
then end the command.
Return Type: string Unit: none
Standard Flash error codes.
CCI_Return Type: int
CCI return number, see error list.
Notes · Some of the commands require the flash license. Further information is given in
the Flash command interface documentation.
C# Example: Start marking:
ASCII Function int CCI_Return = ScCciProcessFlashJob(string File_Name, int Job_Num, int Mode, int Flag)
Description This command allows you to access the flash jobs, see Flash Jobs and Settings. Flag
must be 0.
File_Name Type: string Unit: none
Defines the complete path to the UNF file.
Job_Number Type: int Unit: none
Defines the Flash Job Number.
Mode Type: int Index:
Location: ScComSAMLightClientCtrlFlags
scComSAMLightClientCtrlProcessFlashJobModeStoreCurrentToFlash 0x1
For standalone mode, the Flash job (UNF) is created from the SAMLight job (SJF)
together with a subset of the SAMLight settings and is saved on the USC card and in
<SCAPS>\jobfiles. This means, the creation of the identical UNF from the SJF always
requires identical SAMLight settings. Furthermore, a copy of the SJF is also stored on
the USC card. This mode of ScProcessFlashJob is only possible if the SJF already
exists.
· JobNum defines the flash job number. FileName and Flags are not used.
scComSAMLightClientCtrlProcessFlashJobModeLoadFromFlash 0x2
Loads the copy of the SJF job (which is stored on the USC) to SAMLight. JobNum
defines the flash job number. However, the USC settings and the UNF cannot be
loaded to SAMLight.
Will do the same as the checkbox in the import dialog. This should be used with
command 128.
Polyline and LineArray entites imported with this flag will not be shown in the View2D
and will not be splitted. Vectors of entities imported with this flag will not be stored in
a *.sjf file. However, it is possible to remember the last position of the protected
entities within the *.sjf file. If you re-import an entity with the same name, the old
position will be adjusted automatically. Protected entities can be rotated and
translated but not scaled. The redpointer pre-view will only show the outline of
protected entities. Pen and hatch properties of protected entities cannot be changed.
If at least one protected entity is present within the entity list the mark preview is not
possible anymore. They cannot be copied, duplicated or grouped.
CCI_Return Type: int
CCI return number, see error list.
Notes · This Flags value is usually a combination of multiple flags. Be sure not to
accidentally overwrite the previous flags. See the chapter How to work with flags to
learn more about combining multiple flags.
· When using this command in SAM3D, the last two arguments (Resolution and
Flags) have to be 0.>
C# Example: Reimport a bitmap file:
Description Get the name of the current job file with its complete path.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlStringValueTypeJobFileName 4
Job_Path Type: string
Returns the name of the current job file with its complete path.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Get job file name and path:
Description Get a preview bitmap image of a *.sjf job file to the local hard disc. JobFileName and
BmpFileName includes the complete paths. The size of the resulting bitmap is 100 x
100 pixel.
Description Sorts objects inside a group by their name if the name of the group is specified with
Top Level. If no group name is specified this sorts the top level entities of the job.
Cmd_ID Type: int ID:
Location:ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandSortJobByName 52
CCI_Return Type: int
CCI return number, see error list.
Notes · A entity can be set as top level with the following command SetToTopLevelEntity.
UNDO Set
Get
DLL Function int CCI_Return = ScExecCommand(int Cmd_ID)
ASCII Function int CCI_Return = ScCciSetEntityLongData(string Entity_Name, int Data_ID, int Flag)
Description This command is developed for "connected" serial number/ barcode and Text2D
(share the same name in EntityInfo) -- when the text is changed, the barcode would
be changed in the same way. This command has the same functionality as the
button apply in the barcode page after changing the text in SAMLight.
Entity_Name Type: string Unit: none
Specify the entity to be changed.
Data_ID Type: int ID:
Location: ScComSAMLightClientCtrlFlags
scComSAMLightClientCtrlLongDataIdEntityGenerate 125
Flag Type: int Unit: none
Flag = 1 is required for this command.
Description Specify the type of the entity to be created. For further information on the creation of
an entity, see ScCreateEntity.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlStringValueTypeCreateEntity 36
Entity_Type Type: string Unit: none
Can take following values:
· ScBarCode12Chars2D
· ScWinTextChars2D
· ScSerialNumber
· ScEllipse2D
· ScRectangle2D
· ScPolyline2D
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: for usage examples, please refer to Programming Examples: Create Entity chapter.
Table 109: Entity Type
6.1.1.1 Spiral
· Spiral Entity Properties
· Spiral Radius Value
· Spiral Rotation and Segment Settings
6.1.1.2 Ellipse
· Ellipse Parameters
· Segment Number
6.1.1.3 PolyLine
· Add point to PolyLine
· Add PolyLine
Description Add additional PolyLine in the same Layer. All created points after sending this
command will be used in the new PolyLine.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandAddPolylineToCreateEntityPolyline 66
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Add PolyLine:
6.1.2 Barcode
· Barcode Format
· Barcode Level and Mode
· Barcode Limits Flags
· Barcode Line Reduction
· Barcode Parameter
· Barcode Type
· Human Readable Text
· Human Readable Text Settings
6.1.2.2 QR-Code
· QR Code Settings
6.1.3 Bitmap
· Bitmap Blank Threshold
· Bitmap Line Index Step
· Entity Specific Bitmap Settings
· Export Scanner Bitmap
· Pixel Map Size
double Intensity = 0;
int CCI_Return = cci.ScGetEntityDoubleData("bmp1", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdBitmapIntensity,ref Intensity);
Table 135: Entity Specific Bitmap Settings
ASCII Function int CCI_Return = ScCciSetEntityStringData(string Entity_Name, int Data_ID, string Name)
Description This is used to change the file name of a serial number list in txt/xlsx format. This is
recommended to use with ResetSerialNumber together.
Entity_Name Type: string Unit: none
Specify the entity to be changed.
Data_ID Type: int ID:
Location: ScComSAMLightClientCtrlFlags
scComSAMLightClientCtrlStringDataIdEntitySerialASCIIFileName or 24
scComSAMLightClientCtrlStringDataIdEntitySerialExcelFileName
Name Type: string Unit: none
Enter the new path.
CCI_Return Type: int
CCI return number, see error list.
Notes · The "from File" checkbox has to be activated before.
· You can insert an existing path. No new files will be created with this command.
C# Example: Change the serial numbers file path to the file "serial2.txt" (for the entity "SerialEntity1"):
Description This call resets all serial number entities to their start values.
CCI_Return Type: int
CCI return number, see Error list.
Notes · Further command to reset via DLL function is given in Entities->Objects-
>SerialNumber
C# Example: -
Table 142: CCI Reset Serial Number
Description Increment, decrement or reset all serial number entities in the job.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandResetSerialNumber 8
Reset all the serial numbers in the job.
scComSAMLightClientCtrlExecCommandIncSerialNumber 23
Increment all serial numbers.
scComSAMLightClientCtrlExecCommandDecSerialNumber 24
Decrement all serial numbers.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Reset all serial numbers:
6.1.6 Text2D
· Change Text
· Change Text and Font
· Check Font Availability
· Spacing Mode
· Text2D Checkboxes
· Text Alignment
· Text Weight
· Various Text Parameters
Description The string of the text object with the given Entity_Name can be set to the string
specified by the parameter Text. This function allows the dynamic change of text
objects. The different text objects are identified by their name.
Entity_Name Type: string Unit: none
· Specify the entity to be changed
· An empty string for a name in the parameter Text is valid too.
Text Type: string Unit: none
Enter the new text.
CCI_Return Type: int
Description Sucht Entity mit übergebenem Textinhalt, gibt Name des Entities zurück.
Entity_Name Type: string Unit: none
Specify the entity based on the name.
Data_ID Type: int
Location: ScComSAMLightClientCtrlFlags
scComSAMLightClientCtrlStringDataIdFindEntityWithText
Parameter Type: string Unit: none
The corresponding value.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: How to use Entity String Data IDs
USC-1:
0000_0000_0000_0000_0000_0000_0010_0000
| Opto_In/Out_0
Opto_In/Out_5
USC-2/-3:
0000_0000_0000_0000_0000_0000_0010_0000
| || Opto_In/Out_0
| | Opto_In/Out_5
| Digi_In/Out_0
Digi_In/Out_9
RTC3/4/5/6:
0000_0000_0000_0000_0000_0000_0010_0000
| Digi_In/Out_0
Digi_In/Out_15
Alternative mathematical representation of unsigned Mask:
scComSAMLightClientCtrlLongDataIdEntityIoControlObjectStates 147
States is a decimal number that is best understood binary:
The bits represent a value:
· 0: inactive (SAMLight: "X" if Maskn is 0, "0" if Maskn is 1)
· 1: active (SAMLight: "X" if Maskn is 0, "1" if Maskn is 1).
Some bits are undefined (gray). Which bit represents which in/output depends on the
hardware and is shown below.
USC-1:
0000_0000_0000_0000_0000_0000_0010_0000
| Opto_In/Out_0
Opto_In/Out_5
USC-2/-3:
0000_0000_0000_0000_0000_0000_0010_0000
| || Opto_In/Out_0
| | Opto_In/Out_5
| Digi_In/Out_0
Digi_In/Out_9
RTC3/4/5/6:
0000_0000_0000_0000_0000_0000_0010_0000
| Digi_In/Out_0
Digi_In/Out_15
Alternative mathematical representation of unsigned States:
Description Insert a new motion entity and set the corresponding position value.
Value_Type Type: int
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlDoubleValueTypeMotionAxisAddControl 64
Position Type: double Unit: depends on constant
The desired position coordinate.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Insert new motion entity at 60.0:
ASCII Function int CCI_Return = ScCciSetEntityStringData(string Entity_Name, int Data_ID, string Parameter)
ASCII Function int CCI_Return = ScCciSetEntityStringData(string Entity_Name, int DataID, string Parameter)
// select 3 entities
int CCI_Return_02 = cci.ScSetEntityLongData("Entity1;Entity2;Entity3", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLongDataIdEntitySelected, 1);
Description Sets the entity inside the job with the specified name to the top level entity.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlStringValueTypeSetToTopLevelEntity 17
Entity_Name Type: string Unit: none
The entity name to be set to the top level.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Set the entity with the name "entity1" to the top level:
6.2.3 Transformations
· Center Entity
· Entity Outline
· Entity Rotation Angle
· Mirror Entity
· Outline 2D
· Rotate Entity
· Rotate Entity (DataID)
· Rotation Angle & Outline
· Scale Entity
· Scale Entity (Current Position)
· Translate Entity
· Translate Entity (DataID)
ASCII Function int CCI_Return = ScCciSetEntityLongData(string Entity_Name, int Data_ID, int Axis)
Description Returns the outline of the current enitity specified by Entity_Name. The following
constants can be set for Index to specify which outline value has to be returned.
Entity_Name Type: string Unit: none
If Entity_Name is an empty string, the function returns the job outline.
Index Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlOutlineIndexMinX 0
The smallest x coordinate.
scComSAMLightClientCtrlOutlineIndexMinY 1
The smallest y coordinate.
scComSAMLightClientCtrlOutlineIndexMinZ 2
The smallest z coordinate.
scComSAMLightClientCtrlOutlineIndexMaxX 3
The biggest x coordinate.
scComSAMLightClientCtrlOutlineIndexMaxY 4
The biggest y coordinate.
scComSAMLightClientCtrlOutlineIndexMaxZ 5
The biggest z coordinate.
Value Type: double Unit: [mm]*
double Entity_Rotation_Angle = 0;
int CCI_Return = cci.ScGetEntityDoubleData( "rotEntity1", ( int )
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdEntityRotationAngle, ref
Entity_Rotation_Angle );
C# Example: Set the rotation angle of the entity "rotEntity1" to 50°:
int CCI_Return = cci.ScSetEntityDoubleData( "rotEntity1", ( int )
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdEntityRotationAngle, 50.0 );
Table 179: Entity Rotation Angle
ASCII Function int CCI_Return = ScCciSetEntityLongData(string Entity_Name, int Data_ID, int Mirror_Plane)
Description Mirrors the specified entity along the specified plane. The same functionality as the
buttons of page Z-Dimension > Mirror and Rotate.
Entity_Name Type: string Unit: none
Specify the entity to be changed.
Data_ID Type: int ID:
Location: ScComSAMLightClientCtrlFlags
scComSAMLightClientCtrlLongDataIdEntityMirrorOnPlane 120
Mirror_Plane Type: int Unit: none
Outline 2D Set
Get
DLL Function int CCI_Return = ScSetEntityOutline2D(string Entity_Name, double Min_X, double Min_Y, double
Max_X, double Max_Y, int Index)
int CCI_Return = ScGetEntityOutline2D(string Entity_Name, ref double Min_X, ref double Min_Y,
ref double Max_X, ref double Max_Y)
ASCII Function int CCI_Return = ScCciSetEntityOutline2D(string Entity_Name, double Min_X, double Min_Y,
double Max_X, double Max_Y, int Index)
double Min_X double Min_Y double Max_X double Max_Y = ScCciGetEntityOutline2D(string
Entity_Name)
Description With this command the total 2D outlines of all entities with Entity_Name can be set
or get.
Entity_Name Type: string Unit: none
If Entity_Name is an empty string, the function returns the job outline.
Min_X Type: double Unit: none
The smallest x coordinate.
Min_Y Type: double Unit: none
The smallest y coordinate.
Max_X Type: double Unit: none
The biggest x coordinate.
Max_Y Type: double Unit: none
The biggest y coordinate.
Index Type: int Index:
Location: ScComSAMLightClientCtrlFlags
- 0x0
Entity will be scaled like defined by the parameters.
scComSAMLightClientCtrlSetOutlineNoMove 0x1
Left down point will stay at current position. Just the dimension will be changed,
defined by: X_dim = Max_X - Min_X and Y_dim = Max_Y - Min_Y.
scComSAMLightClientCtrlSetOutlineNoSize 0x2
Specity the center coordinates. The dimension will be ignored.
X_center = Max_X - Min_X and Y_center = Max_Y - Min_Y.
Outline 2D Set
Get
CCI_Return Type: int
CCI return number, see error list.
Note · For this command the index cannot be combined.
· This command can also be used for 1D entities. In this case make sure that Min_X
= Max_X or Min_Y = Max_Y.
C# Example: Set new outline for the entity "circle":
Description This allows to get the Outline and the Rotation Angle of the Entities defined by
Entity_Name.
Entity_Name Type: string Unit: none
Specify the entity to be changed
Data_ID Type: int ID:
Location: Location: ScComSAMLightClientCtrlFlags
scComSAMLightClientCtrlStringDataIdOutlineAndRotate 31
Outl_Angle Type: string Unit: none
Returns the outline and the rotation angle in the following format:
"MinX;MinY;MaxX;MaxY;Angle"
CCI_Return Type: int
CCI return number, see error list.
Notes · If used for multiple entities Entity_NamesSeparatedBySemicolon has to be set.
Outl_Angle will hold the Outlines and Rotation Angle in a list in the format
"MinX;MinY;MaxX;MaxY;Angle".
C# Example: Get the outline and the rotation angle of the entity "entity1":
Description Translates the entity specified by Entity_Name relative to its current position..
Entity_Name Type: string Unit: none
The Entity to be translated.
ASCII Function int CCI_Return = ScCciSetEntityStringData(string Entity_Name, int Data_ID, string Coordinates)
6.2.4 Hatch
· EnableHatch & HatchStyle
· Hatch Angle
· Hatch Beam Compensation
· Hatch Default Values
· Hatch Distance
· Hatch End Offset
· Hatch Flags
· Hatch Line Index Step
· Hatch Line Reduction
· Hatch Loop
· Hatch Loop Angle
· Hatch Minimal Jump
· Hatch Minimal Length
· Hatch Num Loops
· Hatch Point Offset
· Hatch Rehatch All
· Hatch Select Hatch Pair
· Hatch Start Offset
double Hatch_Angle_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchAngle2, ref Hatch_Angle_2);
Table 190: Hatch Angle
double Beam_Compensation_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchBeamcompensation2, ref
Beam_Compensation_2);
Table 191: Hatch Beam Compensation
ASCII Function int CCI_Return = ScCciSetEntityLongData(string Entity_Name, int Data_ID, int Pair)
double Hatch_Distance_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchDistance2, ref hatchdistance2);
Table 193: Hatch Distance
double Hatch_Endoffset_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchEndoffset2, ref Hatch_Endoffset_2);
Table 194: Hatch End Offset
This flag has to be used together with the hatch flag PolyLineBeamComp
and will generate NumLoops from inside to outside of the object.
CCI_Return Type: int
CCI return number, see error list.
Notes · This works not only for 2D but also in SAM3D situation.
C# Example: Activate the checkboxe Sort of hatch 1A:
double Hatch_Line_Index_Step2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchLineIndexStep2, ref
Hatch_Line_Index_Step2);
Table 196: Hatch Line Index Step
double Hatch_Line_Reduct_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchLinereduct2, ref
Hatch_Line_Reduct_2);
Table 197: Hatch Line Reduction
double Hatch_Loop_1 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLoopDataIdHatchLoop1, ref Hatch_Loop_1);
Table 198: Hatch Loop
double Hatch_Loop_Angle_1 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchLinereduct2, ref Hatch_Loop_Angle_1);
Table 199: Hatch Loop Angle
double hatch_min_jump_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchMinjump2, ref hatch_min_jump_2);
Table 200: Hatch Minimal Jump
double hatch_minimal_length_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchMinLength2, ref
hatch_minimal_length_2);
Table 201: Hatch Minimal Length
double hatch_num_loops_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchNumloops2, ref hatch_num_loops_2);
Table 202: Hatch Num Loops
double hatch_point_offset_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchPointOffset2, ref
hatch_point_offset_2);
Table 203: Hatch Point Offset
double hatch_start_offset_2 = 0;
int CCI_Return = cci.ScGetEntityDoubleData("rectangle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchStartoffset2, ref
hatch_start_offset_2);
Table 206: Hatch Start Offset
Description This is used to get the entity type by its index. The index is zero based and starts
from the top level going through the tree on the base of the first object, going on with
the siblings.
Data_ID Type: int ID:
Location: ScComSAMLightClientCtrlFlags
int array_count_x = 0;
array_count_x = cci.ScGetEntityLongData("ArrayCopy Soft",(int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLongDataIdEntityArrayCountX);
Table 214: Array Copy & Arry Step
6.2.7 Bitmap
· Bitmap Mode
Description Create a beam comped copy of the entity that is defined via StringPara1. The copy
will be stored in the entity defined by StringPara2. The Dist parameter is defined by
DoublePara1.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandCreateBeamCompedCopy 37
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Create beam comped copy:
Description Use the data wizard function data reduction redundant points.
Description This allows you to use the data wizard function data reduction short lines.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandWizardDataReductionShortLines 42
CCI Return Type: int
CCI error number, see error list.
Notes · Select entities with EntitySelected.
· Define Short Lines Length with DoublePara1.
C# Example: Data reduction short lines, e.g. generate circle with SegCount = 1000 and then execute:
Description The total jump distance between poly lines would be optimized.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandWizardOptimizeJumps 62
CCI_Return Type: int
CCI return number, see error list.
Notes · Select entities with EntitySelected.
C# Example: Optimize jumps, e.g. draw a line and duplicate it or draw two parallel lines with same direction,
check marking jumps by SAMLight Menu Bar > Window > Preview and Mark > Preview and then execute:
Description This allows the use of the data wizard areas functions.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandWizardClipper 43
CCI_Return Type: int
CCI returnb number, see error list.
Notes · Select entities with EntitySelected.
· Define area operation with DoublePara1.
· Define fill type with DoublePara2.
C# Example: Data wizard clipper, e.g. to get positive union of two or more drawn overlapping geometries
with geometry object toolbar execute:
Description Executes the Data Wizard command "Set Order". There can be set 3 parameters
with Client Control. See Double Value Types DoublePara1/2/3. This will affect all
entities in the job.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandWizardOrder 55
CCI_Return Type: int
CCI return number, see error list.
Notes · Select entities with EntitySelected.
· Define marking order with DoublePara1.
· Define checkbox "Sort Equal Coordinates By Size" with DoublePara2.
· Define checkbox "Sort Equal by other Coordinate" with DoublePara3.
C# Example: Data wizard order:
Description Updates the SAMLight motion position from the motion controller
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandMotionUpdatePos 18
CCI_Return Type: int
CCI return number, see error list.
Notes · MotionAxis has to be set before.
· After the update the position can be get with AxisPosition or MotionAxisAngle.
C# Example: Update motion position:
· Get Inputs
· Get Outputs
· Set Outputs
· Get Output Inversions
Description This function is used to get the input states of the Opto_Ins and Digi_Ins.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeOptoIO 4
Input_States Type: int Unit: none
Input_States is a decimal number that is best understood binary:
The bits represent an input state (blue), inactive (0) or active (1). Some bits are
undefined (gray). Which bit represents which input depends on the hardware and is
shown below.
USC-1:
0000_0000_0000_0000_0000_0000_0010_0000
| Opto_In_0
Opto_In_5
USC-2/-3:
0000_0000_0000_0000_0000_0000_0010_0000
| | | || Opto_In_0
| | | | Opto_In_5
| | | Digi_In_0
| | Digi_In_9
| Stepper_In_0
Stepper_In_2
RTC3/4/5/6:
0000_0000_0000_0000_0000_0000_0010_0000
| Digi_In_0
Digi_In_15
Description This function is used to get the output states of the Opto_Outs and Digi_Outs.
Output_States Type: int Unit: none
Output_States is a decimal number that is best understood binary:
The bits represent an output state (blue), inactive (0) or active (1). Some bits are
undefined (gray). Which bit represents which output depends on the hardware and is
shown below.
USC-1:
0000_0000_0000_0000_0000_0000_0000_1000
| Opto_Out_0
Opto_Out_5
USC-2/-3:
0000_0000_0000_0000_0000_0000_0000_1000
| | | | | || Opto_Out_0
| | | | | | Opto_Out_5
| | | | | Digi_Out_0
| | | | Digi_Out_9
| | | Stepper_Out_0
| | Stepper_Out_5
| Laser_Port_0
Laser_Port_7
Alternative mathematical representation of unsigned Ouput_States:
Description This function is used to set the output states of the Opto_Outs and Digi_Outs.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeOptoIO 4
Output_States Type: int Unit: none
Output_States is a 32 bit signed integer that is best understood binary:
The first 16 bits represent a mask of the outputs (red), telling which output should be
changed (0) or unchanged (1). The last 16 bits represent the desired state of the
output (blue), inactive (0) or active (1). Some bits are undefined (gray). Which bit
represents which output depends on the hardware and is shown below.
USC-1:
1111_1111_1111_0111_0000_0000_0000_1000
| | | State Opto_Out_0
| | State Opto_Out_5
| Mask Opto_Out_0
Mask Opto_Out_5
USC-2/-3:
1111_1111_1111_0111_0000_0000_0000_1000
| || | | || State Opto_Out_0
| || | | | State Opto_Out_5
| || | | State Digi_Out_0
| || | State Digi_Out_9
| || Mask Opto_Out_0
| | Mask Opto_Out_5
| Mask Digi_Out_0
Mask Digi_Out_9
RTC3/4/5/6:
1111_1111_1111_0111_0000_0000_0000_1000
| | | State Digi_Out_0
| | State Digi_Out_15
| Mask Digi_Out_0
Mask Digi_Out_15
USC-2/-3:
0000_0000_0000_0000_0000_0000_0000_0101
| | | || Inversion State Opto_Out_0
| | | | Inversion State Opto_Out_5
| | | Inversion State Digi_Out_0
| | Inversion State Digi_Out_9
| Inversion State Stepper_Out_0
Inversion State Stepper_Out_5
USC-2/-3:
1111_1111_1100_0000_0000_0000_0011_1111
| || | | || Inversion State Opto_Out_0
| || | | | Inversion State Opto_Out_5
| || | | Inversion State Digi_Out_0
| || | Inversion State Digi_Out_9
| || Mask Opto_Out_0
| | Mask Opto_Out_5
| Mask Digi_Out_0
Mask Digi_Out_9
----------
USC-1:
0000_0000_0010_0000
| Opto_In/Out_0
Opto_In/Out_5
USC-2/-3:
0000_0000_0010_0000
RTC3/4/5/6:
0000_0000_0010_0000
| Digi_In/Out_0
Digi_In/Out_15
Alternative mathematical representation of unsigned Mask:
scComSAMLightClientCtrlLongDataIdEntityIoControlObjectStates 147
Mask is a decimal number that is best understood binary:
The bits represent a value:
· 0: inactive (SAMLight: "X" if Maskn is "0" or "0" if Maskn is "1")
· 1: active (SAMLight: "X" if Maskn is "0" or "1" if Maskn is "1").
Some bits of the USC-1 are undefined (gray). Which bit represents which in/output
depends on the hardware and is shown below.
USC-1:
0000_0000_0010_0000
| Opto_In/Out_0
Opto_In/Out_5
USC-2/-3:
0000_0000_0010_0000
| || Opto_In/Out_0
| | Opto_In/Out_5
| Digi_In/Out_0
Digi_In/Out_9
RTC3/4/5/6:
0000_0000_0010_0000
| Digi_In/Out_0
Digi_In/Out_15
Alternative mathematical representation of unsigned States:
9 Mark
Mark has following sub-chapters:
· Mark Dialog
o Red Pointer
· Trigger Dialog
· Mark Preview
· Mark Sequence
· Mark Time
· Mark Counter
· Execution Status
· Is Marking
· Mark Entity by Name
· Mark Flags
· Stop Marking
Is Marking Set
Get
DLL Function int CCI_Return = ScIsMarking()
Description If the ScMarkEntityByName function was called with WaitForMarkEnd set to 0, this
function can be used for checking whether the actual marking process is already
finished or not. The Function returns 1 if the scanner application is still marking.
CCI_Return Type: int
CCI return number, see error list.
Notes -
Is Marking Set
Get
C# Example: Check if the actual marking process is already finished or not:
Quantity Set
Get
DLL Function int CCI_Return = ScSetLongValue(int Value_Type, int Quantity)
int Quantity = ScGetLongValue(int Value_Type)
ASCII Function int CCI_Return = ScCciSetLongValue(int Value_Type, int Quantity)
int Quantity = ScCciGetLongValue(int Value_Type)
Description Set or get the current quantity or maximum quantity.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeQuantity 5
Quantity. Quantity counter must be enabled.
scComSAMLightClientCtrlLongValueTypeMaxQuantity 15
Maximum quantity, after that a message is shown. When a value of -1 is set, the
quantity counter functionality is disabled.
Quantity Type: int Unit: none
Returns the number of marks.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Get the current quantity:
Quantity Set
Get
int Quantity = cci.ScGetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeQuantity );
Table 262: Quantity
10 Splitting
This chapter deals with the option splitting. There exist several options that are only available in some
modes but not in all modes. The commands available in all modes are explained below. Other commands
only available in a few modes are explained with further details in the following subchapters:
· Angular Splitting
· 1D Planar Splitting
· 2D Planar Splitting
· Ring Splitting
· 1D MOTF Splitting
· Bitmap Rotary Splitting
· Step and Repeat
Following commands can be used and are relevant for all Splitting Modes:
· Disable Splitting
· Global Splitting Checkboxes
· Save Splits As Entities
· Save Splits Job File Name
· Save Splits As Orig Entities
· Split Mode
· Split Order
· Split Overlap
· Split / Resplit Job
· Split Repetitions
· Splitting Submode
Description This constant can be used to save a splitted job file as an entity list of split tiles.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandSaveSplitsAsOrigEntities 30
Save the splitted job with the functionality of the checkbox "Original positions /
Positions as in job to mark".
scComSAMLightClientCtrlExecCommandSaveSplitsAsEntities 38
Save the splitted job.
CCI_Return Type: int
CCI return number, see error list.
Notes This constant has to be executed after SaveSplitsJobFileName.
C# Example: Resplit job:
SplitAxis ReverseSplitOrder Fixed Size Split Order Entity Based Split Order
0 0
0 1
1 0
1 1
Description Set the submode of the drop down menu in the splitting settings dialog.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandSetMotfFixed 45
Vector marking - fixed split size.
scComSAMLightClientCtrlExecCommandSetMotfBmp 46
Bitmap Marking.
scComSAMLightClientCtrlExecCommandSetMotf 53
Vector marking - entity based splitting.
CCI_Return Type: int
CCI return number, see error list.
Notes
C# Example: Set 1D splitting submode to vector marking - fixed size:
Diameter Set
Get
DLL Function int CCI_Return = ScSetDoubleValue(int Value_Type, double Total_Diameter)
double Total_Diameter = ScGetDoubleValue(int Value_Type)
ASCII Function int CCI_Return = ScCciSetDoubleValue(int Value_Type, double Total_Diameter)
double Total_Diameter = ScCciGetDoubleValue(int Value_Type)
Description Set or get the angular splitting total diameter.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlDoubleValueTypeAngularSplittingTotalDiameter 50
Total_Diameter Type: double Unit: [mm]*
The corresponding value of the total diameter.
CCI_Return Type: int
CCI return number, see error list.
Notes · The default unit is mm, but the user can select a different unit.
C# Example: Set the angular splitting total diameter to 100.0:
The command SplitKeepMarkFlag does not set the flag Keep Marking Active Output for Step and
Repeat.
11 Option Optic3D
The following chapter deals with Optic3D. Global parameters can be found in the main chapter, whereby the
commands for 3D surfaces are explained in the following subchapter:
· Optic 3D Settings
11.1 3D Surfaces
· 3D Surface Enable
· 3D Surface Type
· Cylinder Properties
· Sphere Properties
· Tilted Surface Properties
· STL Projection Properties
· STL Path
12 Option SAM3D
The following commands can be used for SAM2D and SAM3D. Please find the detailed description linked in
the following table. Specific SAM3D information can be found in the corresponding notes line of each
command.
· SCAPS Dongle ID
· String User Value
· Translate Entity
· Working Area
Description Returns the outline of the current slice of the ScLayerSolid specified by Entity_Name.
The following constants can be set for Index to specify which outline value has to be
returned.
Entity_Name Type: string Unit: none
If Entity_Name is an empty string, the function returns the job outline.
Index Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlOutlineSliceIndexMinX 6
The smallest x coordinate.
scComSAMLightClientCtrlOutlineSliceIndexMinY 7
The smallest y coordinate.
scComSAMLightClientCtrlOutlineSliceIndexMinZ 8
The smallest z coordinate.
scComSAMLightClientCtrlOutlineSliceIndexMaxX 9
The biggest x coordinate.
scComSAMLightClientCtrlOutlineSliceIndexMaxY 10
The biggest y coordinate.
scComSAMLightClientCtrlOutlineSliceIndexMaxZ 11
The biggest z coordinate.
Value Type: double Unit: [mm]*
The corresponding value.
Notes · The default unit is mm, but the user can select a different unit.
C# Example: Get the biggest x coordinate of the whole job:
double comp = 0;
int CCI_Return = cci.ScGetEntityDoubleData("", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdHatchLayerSolidUpDownSkinBeamComp, ref
comp);
Table 301: Hatch Layer Solid Parameters
Layer Set
Get
DLL Function int CCI_Return = ScSetLongValue(int Value_Type, int Parameter)
int Parameter = ScGetLongValue(int Value_Type)
ASCII Function int CCI_Return = ScCciSetLongValue(int Value_Type, int Parameter)
int Parameter = ScCciGetLongValue(int Value_Type)
Description Set or get different layer numbers.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeGetTotalSlices 44
Total number of layers in job. There is no set function.
scComSAMLightClientCtrlLongValueTypeSliceFrom 45
First layer to be marked
scComSAMLightClientCtrlLongValueTypeSliceTo 46
Last layer to be marked
scComSAMLightClientCtrlLongValueTypeCurrentSliceNum 47
Current layer
Parameter Type: int Unit: none
The corresponding value.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Set current layer to 3:
Outline 3D Set
Get
DLL Function int CCI_Return = ScSetEntityOutline3D(string Entity_Name, double Min_X, double Min_Y, double
Max_X, double Max_Y, double Min_Z, double Max_Z, int Flag)
int CCI_Return = ScGetEntityOutline3D(string Entity_Name, ref double Min_X, ref double Min_Y,
ref double Max_X, ref double Max_Y, ref double Max_Z, ref double Max_Z, int Flag)
ASCII Function int CCI_Return = ScCciSetEntityOutline3D(string Entity_Name, double Min_X, double Min_Y,
double Max_X, double Max_Y, double Min_Z, double Max_Z, int Flag)
double Min_X double Min_Y double Max_X double Max_Y double Min_Z double Max_Z =
ScCciGetEntityOutline3D(string Entity_Name)
Description Set or get the 3D outlines of all entities named Entity_Name.
Entity_Name Type: string Unit: none
If Entity_Name is an empty string, the function returns the outline of the whole job.
Min_X Type: double Unit: [mm]*
The smallest x coordinate.
Min_Y Type: double Unit: [mm]*
The smallest y coordinate.
Max_X Type: double Unit: [mm]*
The biggest x coordinate.
Max_Y Type: double Unit: [mm]*
The biggest y coordinate.
Min_Z Type: double Unit: [mm]*
The smallest z coordinate.
Max_Z Type: double Unit: [mm]*
The biggest z coordinate.
Flag Type: int Flag:
Location: ScComSAMLightClientCtrlFlags
Outline 3D Set
Get
scComSAMLightClientCtrlSetOutlineNoMove 0x1
Left down point will stay at current position and the rest is scaled.
scComSAMLightClientCtrlSetOutlineNoSize 0x2
All values should be the same value to define the new center
CCI_Return Type: int
CCI return number, see error list.
Note · The default unit is mm, but the user can select a different unit.
· ScSetEntityOutline3D does not work for ScLayerSolid entities.
· When 0 is used as Flag, the object will be scaled and positioned like defined.
· For this command the flags cannot be combined.
C# Example: Set new 3D outline for the ScTriaMesh3D entity "Sphere":
int CCI_Return = cci.ScSetEntityOutline3D( "Sphere", 0.0, 0.0, 10.0, 10.0, 0.0, 10.0, 0 );
C# Example: Get current 3D outline of entity "Sphere":
int CCI_Return = cci.ScRotateEntity3D( "Star", 4.0, 5.0, 0.0, 0.0, 0.0, 1.0, 30.0 );
Table 309: Rotate Entity 3D
Slice Set
Get
DLL Function int CCI_Return = ScSlice(string Entity_Name, string Layer_Solid_Name, double Layer_Spacing,
int Only_Selected, int Slice_Reverse )
ASCII Function -
Slice Set
Get
· 1: The order of the sliced layers is from top to bottom (subtractive manufacturing).
CCI_Return Type: int
CCI return number, see error list.
Notes · The default unit is mm, but the user can select a different unit.
C# Example: Slices a ScTriaMesh3D entity into a ScLayerSolid entity:
Description Slices a ScTriaMesh3D entity into a ScLayerSolid entity according to a text file
containing the slice information.
File_Path Type: string Unit: none
Path to the text file containing the slice information. The path must include the file
extension ".txt". The specification of the slice parameter in the text file can be found
here.
Entity_Name Type: string Unit: none
Entity name of the ScTriaMesh3D that is being sliced. Use "" for all ScTriaMesh3D
entities in job.
Layer_Solid_Name Type: string Unit: none
Entity name of the generated ScLayerSolid entity.
Only_Selected Type: int Unit: none
· 0: All ScTriaMesh3D entities named Entity_Name are being sliced.
· 1: All ScTriaMesh3D selected entities which are named Entity_Name are being
sliced.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Slice from text file:
13 Other
This chapter contains several diverse commands, which could not assigned to one of the previous
chapters.
13.4 RS-232
Description Set the analog out values 3-6 at the RTC3/4 I/O extension board.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeDA3 34
Set analog out 3.
scComSAMLightClientCtrlLongValueTypeDA4 35
Set analog out 4.
scComSAMLightClientCtrlLongValueTypeDA5 36
Set analog out 5.
scComSAMLightClientCtrlLongValueTypeDA6 37
Set analog out 6.
Analog_Out Type: int Unit: none
Description This commands return the temperature for an RTC4 for the galvanometer scanner
termperature for intelliSCAN, intelliSCANde, intelliDRILL, intellicube.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeRTCTempX 72
Get the Temp X from RTC4.
scComSAMLightClientCtrlLongValueTypeRTCTempY 73
Get the Temp Y from RTC4.
scComSAMLightClientCtrlLongValueTypeRTCTempZ 80
Get the Temp Z from RTC4.
Temp Type: int Unit: [°C]
Return the temperature of the desired command.
Notes · Command only for RTC4
C# Example: Get X Temp:
Description This commands return the servo board temperature of the scan head for an RTC5.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeRTCServo2TempY 74
Get the Temp Y from Head 2.
scComSAMLightClientCtrlLongValueTypeRTCServoTempX 83
Get the Temp X from Head 1.
scComSAMLightClientCtrlLongValueTypeRTCServoTempY 84
Get the Temp Y from Head 1.
scComSAMLightClientCtrlLongValueTypeRTCServoTempZ 85
scComSAMLightClientCtrlLongValueTypeRTCServo2TempX
Get the Temp Z/Temp X from Head 1/2.
Temp Type: int Unit: [°C]
Return the temperature of the desired command.
Notes · Command only for RTC5
C# Example: Get Servo X Temp:
13.6 Screenshot
This chapter deals with creating screenshots in SAMLight. There are two different possibilities:
· Screenshot of current View2D (SAMLicht must not be hidden, colored current View2D)
· Screenshot of entities (SAMLight can be hidden, only black and white)
scComSAMLightClientCtrlStringValueTypeSaveView2D320 7
The width of the screenshot is set to 320 pixel. [*]
scComSAMLightClientCtrlStringValueTypeSaveView2DVariableSize 8
The width of the screenshot is defined by SaveView2DBitmapVariableSize. [*]
scComSAMLightClientCtrlStringValueTypeSaveView2DFull 9
Size of the screenshot is 1:1 from the current View2D.
Screenshot_Path Type: string Unit: none
Defines the path, where the screenshot is saved to. The path must include the file
extension, which must be ".bmp".
CCI_Return Type: int
CCI error number, see error list.
Notes · [*]: The larger axis (usually x) is set to a fixed value, the aspect ratio is kept.
· The screenshot contains the section of the current View2D.
· The screenshot is colored.
· There are several possibilities to control the pixel size of the screenshot.
· This CCI command only works if SAMLight is visible and not hidden by something
else.
· The current View2D can be changed via CCI, see Change View2D.
C# Example: Make a 1:1 screenshot of current View2D:
SaveView2DBitmapDPI Set
Get
DLL Function int CCI_Return = ScSetDoubleValue(int Value_Type, double DPI)
double DPI = ScGetDoubleValue(int Value_Type)
ASCII Function int CCI_Return = ScCciSetDoubleValue(int Value_Type, double DPI)
double DPI = ScCciGetDoubleValue(int Value_Type)
Description Set or get the pixel resolution for SaveView2DAdjustableDPI, depending on SAM2D
or SAM3D.
SaveView2DBitmapDPI Set
Get
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapDPI 44
DPI Type: double Unit: depends on constant
Pixel density [dpi]
CCI_Return Type: int
CCI error number, see error list.
Notes -
C# Example: Set screenshot to 96.0 dpi:
Head ID Set
Get
DLL Function int CCI_Return = ScSetHead (int Head_ID)
int CCI_Return = ScGetHead (int Head_ID)
ASCII Function int CCI_Return = ScCciSetHead(int Head_ID)
int Head_ID = ScCciGetHead()
Description This function is for MultiHead applications. It specifies a head that is used with the
commands that follow after ScSetHead or returns the number of the active head.
HeadID can have a number in range 0..n that is the number of the active head or -1
to apply commands for all heads.
Head_ID Type: int Unit: none
Enter the number of the head to select.
CCI_Return Type: int
CCI return number, see error list.
Notes · -1 is for all heads which are connected.
C# Example: Set head 2:
int Head_ID = 1;
int CCI_Return = cci.ScGetHead( ref Head_ID );
Table 338: Head ID
Description Returns the status of the primary or secondary head. For different card types (USC-
1, USC-2/3, RTC), different values can be returned, also a combination of them. If
you use more than one card, you have to select the card with ScSetHead first.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeHeadStatus 2
Returns the status of the primary head.
scComSAMLightClientCtrlLongValueTypeHead2Status 75
Returns the status of the secondary head.
Flag Type: int Flag:
Location: none
Temperature OK 0x1
Only for RTC cards, the temperature status is available.
Power OK 0x2
Only for RTC cards, the power status is available.
Position OK 0x4
Only for RTC cards, the position status is available.
Out of data with laser on 0x1024
For all cards, the state out of data with laser on is available.
Notes · Depending on the specific type of card, different flags are available.
C# Example: Get head status:
Description With this flag, the behaviour of the ScMoveAbs command is completely different.
The ScMoveAbs commands will be executed as a list.
The red pointer move list is
* started and cleared by setting SelectRedpointerForMoveAbs to '1'.
* filled by one or multiple ScMoveAbs commands.
* executed by setting SelectRedpointerForMoveAbs to '0'. After the execution the list
is cleared.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeSelectRedpointerForMoveAbs 57
Use the red pointer move list.
RP_On_Off Type: int Unit: none
· 0: Redpointer selection for ScMoveAbs off
· 1: Redpointer selection for ScMoveAbs on
CCI Return Type: int
CCI return number, see error list.
Notes · Use this flag before ScMoveAbs.
C# Example:
CCI_Return = cci.ScSetLongValue((int)
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeSelectRedpointerForMoveAbs, 1 )
Table 341: Redpointer for absolute scanner move
ASCII Function int CCI_Return = ScCciMoveAbs(double X_Position, double Y_Position, double Z_Position)
Description Jumps with the defined pen directly to the new position specified by x, y and z.
During the jump the laser emission is turned off by default and can be turned on with
ScSwitchLaser().
X_Position Type: double Unit: [mm]
X value of the target position.
Y_Position Type: double Unit: [mm]
Y value of the target position.
Z_Position Type: double Unit: [mm]
Z value of the target position.
CCI_Return Type: int
CCI return number, see error list.
Notes · Define the pen which should be used for the jump using ScSetPen().
· Without pen definition, pen #1 will be taken as default.
· The values will be affected by the correction file as well.
C# Example: Move the scanner to x = 10mm, y = 10mm and z = 22mm:
Description Switches the laser_gate signal of a USC card on or off, depending on the On_Off
parameter.
On_Off Type: int Unit: none
· 0: Laser_Gate signal off
· 1: Laser_Gate signal on
CCI_Return Type: int
CCI return number, see error list.
Notes · The on or off switch of laser_gate will be done immediately.
· Can be used together with ScMoveAbs.
· Do not use this command together with regular job because ScSwitchLaser stops
the marking process.
C# Example: Switch the laser_gate signal on:
XY Status Set
Get
DLL Function int XY_Status = ScGetLongValue(int Value_Type)
Description Returns the status of the scanner (head 0 or head 1) based on the status signal of
the XY2-100 interface of the selected USC-2 or USC-3 card. If you use more than
one USC-2 or USC-3 card, you have to select the card with ScSetHead first.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeXYStatus 68
Get the status of head 0.
XY Status Set
Get
scComSAMLightClientCtrlLongValueTypeXYStatus1 69
Get the status of head 1.
XY_Status Type: int Unit: none
Returns the status of the head.
Notes · The status will be updated every 100 ms (approximately).
· For the interpretation of this signal please refer to your scanner manual.
C# Example: Get XY status of the scanner connected to head 0:
13.8 sc_corr_table
· Correction Mode
· Correction Points
· 2D Fit Type
· Correct SamLight
· Send Cor Table Values
Description Specifies the number of influence points for each grid point for inverse distance
weighting (IDW) mode. A value of '4' seems to lead to good results. IDW mode must
be enabled with CorrectionModeIDW.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeCorrectionPoints 82
Parameter Type: int Unit: none
· 0: Disable.
· 1: Enable.
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Correct points in Fit2D correction algorithm:
Description Executes the correction of the currently used correction file with
<SCAPS>\system\sc_calib_points.txt. The new correction file is applied in SAMLight
and it is saved in the same folder as the previous used one. The correction mode
can be chosen with CorrectionMode. An example can be found in the chapter
Correct UCF. In sc_corr_table, this function is called 'Correct UCF by calibration
points'.
Cmd_ID Type: int ID:
Location: ScComSAMLightClientCtrlExecCommandConstants
scComSAMLightClientCtrlExecCommandCorrectSamLight 50
CCI_Return Type: int
CCI return number, see error list.
Notes -
C# Example: Execute the correction with <SCAPS>\system\sc_calib_points.txt and apply the new
correction file in SAMLight:
13.9 View2D
· BackgroundColor
· MultiHeadSplit
· Show Coordinates/Working Area/Grid
MultiHeadSplit Set
Get
DLL Function int CCI_Return = ScExecCommand(int Cmd_ID)
ASCII Function -
Description Set the status of the Coordinates, Working Area and Grid in the View2D.
Value_Type Type: int ID:
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlLongValueTypeShowCoordinates 76
Hide or show the Coordinates in View2D.
scComSAMLightClientCtrlLongValueTypeShowWorkingArea 77
Hide or show the Working Area in View2D.
scComSAMLightClientCtrlLongValueTypeShowGrid 78
Hide or show the Grid in View2D.
Mode Type: int Unit: none
· 0: To hide.
· 1: To show.
CCI_Return Type: int
· CCI return number, see error list.
Notes -
C# Example: Hide the coordinates, working area and grid in View2D:
14 List of Commands
14.1 ASCII Commands
· ScCciAutoCompensateCal
· ScCciAutoCompensateOff
· ScCciAutoCompensateRef
· ScCciChangeTextByName
· ScCciCreateEntity
· ScCciDecSerialNumbers
· ScCciDeleteEntity
· ScCciDuplicateEntity
· ScCciExecCommand
· ScCciFitViewToEntities
· ScCciFitViewToSelectedEntities
· ScCciFitViewToWorkingArea
· ScCciGetDoubleValue
· ScCciGetEntityDoubleData
· ScCciGetEntityLongData
· ScCciGetEntityOutline
· ScCciGetEntityOutline2D
· ScCciGetEntityOutline3D
· ScCciGetEntityStringData
· ScCciGetHead
· ScCciGetIDStringData
· ScCciGetInterfaceVersion
· ScCciGetLongValue
· ScCciGetMarkFlags
· ScCciGetMode
· ScCciGetOpticMatrix
· ScCciGetPen
· ScCciGetStringDoubleValue
· ScCciGetStringValue
· ScCciGetWorkingArea
· ScCciImport
· ScCciIncSerialNumbers
· ScCciIsMarking
· ScCciLoadJob
· ScCciMarkEntityByName
· ScCciMotionGo
· ScCciMotionHome
· ScCciMotionSendString
· ScCciMotionStopMove
· ScCciMotionUpdatePos
· ScCciMoveAbs
· ScCciNewJob
· ScCciOpticMatrixReset
· ScCciOpticMatrixRotate
· ScCciOpticMatrixScale
· ScCciOpticMatrixTranslate
· ScCciProcessFlashJob
· ScCciResetCounter
· ScCciResetSequence
· ScCciResetSerialNumbers
· ScCciResplitJob
· ScCciRotateEntity
· ScCciRotateEntity3D
· ScCciSaveJob
· ScCciSaveSplitsAsEntities
· ScCciScaleEntity
· ScCciScaleEntityCurPos
· ScCciSetDoubleValue
· ScCciSetEntityDoubleData
· ScCciSetEntityLongData
· ScCciSetEntityOutline2D
· ScCciSetEntityOutline3D
· ScCciSetEntityStringData
· ScCciSetFieldSizeAndWorkingArea
· ScCciSetHead
· ScCciSetIDStringData
· ScCciSetLongValue
· ScCciSetMarkFlags
· ScCciSetMode
· ScCciSetPen
· ScCciSetPixelMapForPen
· ScCciSetStringDoubleValue
· ScCciSetStringLongValue
· ScCciSetStringValue
· ScCciShowApp
· ScCciShutdown
· ScCciStopMarking
· ScCciSwitchLaser
· ScCciTest
· ScCciTranslateEntity
· ScCciUpdateScannerPos
· ScCciUpdateViewNow
· ScMoveAbs
· ScOpenEthernetConnection
· ScOpenTCPConnection
· ScOpenUDPConnection
· ScOpticMatrixReset
· ScOpticMatrixRotate
· ScOpticMatrixScale
· ScOpticMatrixTranslate
· ScProcessFlashJob
· ScRotateEntity
· ScRotateEntity3D
· ScSaveJob
· ScScaleEntity
· ScScaleEntityCurPos
· ScSetDoubleValue
· ScSetEntityDoubleData
· ScSetEntityLongData
· ScSetEntityOutline2D
· ScSetEntityOutline3D
· ScSetEntityStringData
· ScSetFieldSizeAndWorkingArea
· ScSetHead
· ScSetIDStringData
· ScSetLongData
· ScSetLongValue
· ScSetLongValue64
· ScSetMarkFlags
· ScSetMode
· ScSetPen
· ScSetPenPathForPen
· ScSetPixelMapForPen
· ScSetStringDblValue
· ScSetStringLongValue
· ScSetStringValue
· ScShowApp
· ScShutDown
· ScSlice
· ScSliceFromTxt
· ScStopMarking
· ScSwitchLaser
· ScTranslateEntity
15 List of Constants
15.1 Double Value Types
Double Value Types
Location: ScComSAMLightClientCtrlValueTypes
scComSAMLightClientCtrlDoubleValueTypeOverrideSpeed 1
scComSAMLightClientCtrlDoubleValueTypeOverridePower 2
scComSAMLightClientCtrlDoubleValueTypeOverrideFrequency 3
scComSAMLightClientCtrlDoubleValueTypeMarkSpeed 4
scComSAMLightClientCtrlDoubleValueTypeJumpSpeed 5
scComSAMLightClientCtrlDoubleValueTypeFrequency 6
scComSAMLightClientCtrlDoubleValueTypeJumpDelay 7
scComSAMLightClientCtrlDoubleValueTypeMarkDelay 8
scComSAMLightClientCtrlDoubleValueTypePolyDelay 9
scComSAMLightClientCtrlDoubleValueTypeLaserOnDelay 10
scComSAMLightClientCtrlDoubleValueTypeLaserOffDelay 11
scComSAMLightClientCtrlDoubleValueTypeScannerXPos 12
scComSAMLightClientCtrlDoubleValueTypeScannerYPos 13
scComSAMLightClientCtrlDoubleValueTypeScannerZPos 14
scComSAMLightClientCtrlDoubleValueTypePulseLength 15
scComSAMLightClientCtrlDoubleValueTypeFirstPulseLength 16
scComSAMLightClientCtrlDoubleValueTypeLaserPower 17
scComSAMLightClientCtrlDoubleValueTypeSizePowerMap 18
scComSAMLightClientCtrlDoubleValueTypePowerMapStartId 19
scComSAMLightClientCtrlDoubleValueTypeMaxPower 20
scComSAMLightClientCtrlDoubleValueTypeLastMarkTime 21
scComSAMLightClientCtrlDoubleValueTypeOverridePower2 22
scComSAMLightClientCtrlDoubleValueTypeHomePosX 23
scComSAMLightClientCtrlDoubleValueTypeHomePosY 24
scComSAMLightClientCtrlDoubleValueTypeHomePosZ 25
scComSAMLightClientCtrlDoubleValueTypeLineRampingPowerStartRampValue 26
scComSAMLightClientCtrlDoubleValueTypeLineRampingPowerStartRampLength 27
scComSAMLightClientCtrlDoubleValueTypeLineRampingPowerEndRampValue 28
scComSAMLightClientCtrlDoubleValueTypeLineRampingPowerEndRampLength 29
scComSAMLightClientCtrlDoubleValueTypeLineRampingSpeedStartRampValue 30
scComSAMLightClientCtrlDoubleValueTypeLineRampingSpeedStartRampLength 31
scComSAMLightClientCtrlDoubleValueTypeLineRampingSpeedEndRampValue 32
scComSAMLightClientCtrlDoubleValueTypeLineRampingSpeedEndRampLength 33
scComSAMLightClientCtrlDoubleValueTypeLastExpectedMarkTime 34
scComSAMLightClientCtrlDoubleValueTypeSkyWritingStartLength 35
scComSAMLightClientCtrlDoubleValueTypeSkyWritingEndLength 36
scComSAMLightClientCtrlDoubleValueTypeSkyWritingBreakAngle 37
scComSAMLightClientCtrlDoubleValueTypeMotionAxisPosition 38
scComSAMLightClientCtrlDoubleValueTypeMotionAxisAngle 39
scComSAMLightClientCtrlDoubleValueTypeMotionAxisPositionRelative 40
scComSAMLightClientCtrlDoubleValueTypeMotionAxisAngleRelative 41
scComSAMLightClientCtrlDoubleValueTypeMotionAxisSpeed 42
scComSAMLightClientCtrlDoubleValueTypeHalfPeriod 43
scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapDPI 44
scComSAMLightClientCtrlDoubleValueTypeSpiLaserSimmer 45
scComSAMLightClientCtrlDoubleValueTypeGainX 46
scComSAMLightClientCtrlDoubleValueTypeGainY 47
scComSAMLightClientCtrlDoubleValueTypeLaserCo2Power1 48
scComSAMLightClientCtrlDoubleValueTypeLaserCo2Power2 49
scComSAMLightClientCtrlDoubleValueTypeAngularSplittingTotalDiameter 50
scComSAMLightClientCtrlDoubleValueTypeAngularSplittingAngle 51
scComSAMLightClientCtrlDoubleValueTypeHorizontalSplittingValue 52
scComSAMLightClientCtrlDoubleValueTypeVerticalSplittingValue 53
scComSAMLightClientCtrlDoubleValueTypeWobbleFrequency 54
scComSAMLightClientCtrlDoubleValueTypeWobbleAmplitude 55
scComSAMLightClientCtrlDoubleValueTypeStartSplittingPosX 56
scComSAMLightClientCtrlDoubleValueTypeStartSplittingPosY 57
scComSAMLightClientCtrlDoubleValueTypeOffsetX 58
scComSAMLightClientCtrlDoubleValueTypeOffsetY 59
scComSAMLightClientCtrlDoubleValueTypeLineRampingLengthenStart 60
scComSAMLightClientCtrlDoubleValueTypeLineRampingLengthenEnd 61
scComSAMLightClientCtrlDoubleValueTypeDefocus 62
scComSAMLightClientCtrlDoubleValueTypeAsyncModeResult 63
scComSAMLightClientCtrlDoubleValueTypeMotionAxisAddControl 64
scComSAMLightClientCtrlDoubleValueTypeMOFExtStartDelay 65
scComSAMLightClientCtrlDoubleValueTypeDoublePara1 66
scComSAMLightClientCtrlDoubleValueTypeDoublePara2 67
scComSAMLightClientCtrlDoubleValueTypeWorkingAreaMinX 68
scComSAMLightClientCtrlDoubleValueTypeWorkingAreaMinY 69
scComSAMLightClientCtrlDoubleValueTypeWorkingAreaMaxX 70
scComSAMLightClientCtrlDoubleValueTypeWorkingAreaMaxY 71
scComSAMLightClientCtrlDoubleValueTypeDrillPeriod 72
scComSAMLightClientCtrlDoubleValueTypeDrillDuration 73
scComSAMLightClientCtrlDoubleValueTypeDrillLength 74
scComSAMLightClientCtrlDoubleValueTypeDrillJumpSpeed 75
scComSAMLightClientCtrlDoubleValueTypeDrillJumpDelay 76
scComSAMLightClientCtrlDoubleValueTypeDrillDimension 78
scComSAMLightClientCtrlDoubleValueTypeDrillCo2HalfPeriod 79
scComSAMLightClientCtrlDoubleValueType3DVariHatchAngle 80
scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapVariableSize 81
scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapX 82
scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapY 83
scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapXW 84
scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapYW 85
scComSAMLightClientCtrlDoubleValueTypeSelPointXPos 86
scComSAMLightClientCtrlDoubleValueTypeSelPointYPos 87
scComSAMLightClientCtrlDoubleValueTypeSelPointZPos 88
scComSAMLightClientCtrlDoubleValueTypeLongDelay 89
scComSAMLightClientCtrlDoubleValueTypeOffsetZ 90
scComSAMLightClientCtrlDoubleValueTypeSpeedMotfEntityBasedSplitting 91
scComSAMLightClientCtrlDoubleValueTypeEntityArrayStepX 92
scComSAMLightClientCtrlDoubleValueTypeEntityArrayStepY 93
scComSAMLightClientCtrlDoubleValueTypeEntityBasedSplittingGroupedEntityWidth 94
scComSAMLightClientCtrlDoubleValueTypeDoublePara3 95
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue1 96
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue2 97
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue3 98
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue4 99
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue5 100
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue6 101
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue7 102
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue8 103
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue9 104
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue10 105
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue11 106
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue12 107
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue13 108
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue14 109
scComSAMLightClientCtrlDoubleValueType3DSurfaceValue15 110
scComSAMLightClientCtrlDoubleValueTypeOpticRotation 111
scComSAMLightClientCtrlDoubleValueTypeLastPreviewTime 112
scComSAMLightClientCtrlDoubleValueType2DSplitWidthValue 113
scComSAMLightClientCtrlDoubleValueType2DSplitHeightValue 114
scComSAMLightClientCtrlDoubleValueTypeRingSplittingZTiltAngle 115
scComSAMLightClientCtrlDoubleValueTypeRingSplittingZSpindleCenterHeight 116
scComSAMLightClientCtrlDoubleValueTypeRingSplittingSpindleRradius 117
scComSAMLightClientCtrlDoubleValueTypeRingSplittingZRingCenterHeight 118
scComSAMLightClientCtrlDoubleValueTypeFieldMinX 119
scComSAMLightClientCtrlDoubleValueTypeFieldMinY 120
scComSAMLightClientCtrlDoubleValueTypeFieldMaxX 121
scComSAMLightClientCtrlDoubleValueTypeFieldMaxY 122
scComSAMLightClientCtrlDoubleValueTypeIPGPulseLength 123
scComSAMLightClientCtrlDoubleValueTypeMinFrequency 124
scComSAMLightClientCtrlDoubleValueTypeMaxFrequency 125
scComSAMLightClientCtrlDoubleValueTypeDrillMarkLineAsDotsGridX 126
scComSAMLightClientCtrlDoubleValueTypeDrillMarkLineAsDotsGridY 127
scComSAMLightClientCtrlDoubleValueTypeMinMarkSpeed 128
scComSAMLightClientCtrlDoubleValueTypeMaxMarkSpeed 129
scComSAMLightClientCtrlDoubleValueTypeMinJumpSpeed 130
scComSAMLightClientCtrlDoubleValueTypeMaxJumpSpeed 131
scComSAMLightClientCtrlDoubleValueTypeStepAndRepeatPlanarStartX 132
scComSAMLightClientCtrlDoubleValueTypeStepAndRepeatPlanarStartY 133
scComSAMLightClientCtrlDoubleValueTypeStepAndRepeatPlanarStepX 134
scComSAMLightClientCtrlDoubleValueTypeStepAndRepeatPlanarStepY 135
scComSAMLightClientCtrlDoubleValueTypeStepAndRepeatSpeed 136
scComSAMLightClientCtrlDoubleValueTypeBmpAlphaBlendPointXTo 137
scComSAMLightClientCtrlDoubleValueTypeBmpAlphaBlendPointYTo 138
scComSAMLightClientCtrlDoubleValueTypeBmpAlphaBlendDimXTo 139
scComSAMLightClientCtrlDoubleValueTypeBmpAlphaBlendDimYTo 140
scComSAMLightClientCtrlDoubleValueTypeBmpContinuousTotalDiameter 141
scComSAMLightClientCtrlDoubleValueTypeBmpContinuousAngle 142
scComSAMLightClientCtrlDoubleValueTypeProcessTime 143
scComSAMLightClientCtrlDoubleValueTypeTotalMarkingTime 144
scComSAMLightClientCtrlDoubleValueTypeProcessTime 143
scComSAMLightClientCtrlDoubleValueTypeTotalMarkingTime 144
scComSAMLightClientCtrlDoubleValueTypeSplitOverlap 145
scComSAMLightClientCtrlDoubleValueTypeSplitMotfDistanceBetweenSplits 147
scComSAMLightClientCtrlDoubleValueTypeDoublePara4 148
scComSAMLightClientCtrlDoubleValueTypeDoublePara5 149
scComSAMLightClientCtrlDoubleValueTypeDoublePara6 150
scComSAMLightClientCtrlDoubleValueTypeDoublePara7 151
scComSAMLightClientCtrlDoubleValueTypeDoublePara8 152
scComSAMLightClientCtrlDoubleValueTypeBackgroundImageWebcamMaxFramesPerSecond 153
scComSAMLightClientCtrlDoubleValueTypeRedPointerOffsetX 154
scComSAMLightClientCtrlDoubleValueTypeRedPointerOffsetY 155
scComSAMLightClientCtrlDoubleValueTypeRedPointerFactorX 156
scComSAMLightClientCtrlDoubleValueTypeRedPointerFactorY 157
scComSAMLightClientCtrlDoubleValueTypeStyleIdPixelMapZone 4096
scComSAMLightClientCtrlDoubleValueTypeUserValue 20000
scComSAMLightClientCtrlDoubleValueTypeUsc1MotfCh0Multiplier 65539
scComSAMLightClientCtrlDoubleValueTypeUsc1MotfCh1Multiplier 65540
scComSAMLightClientCtrlDoubleValueTypePrimaryHeadOffsetX 65546
scComSAMLightClientCtrlDoubleValueTypePrimaryHeadOffsetY 65547
scComSAMLightClientCtrlDoubleValueTypePrimaryHeadGainX 65548
scComSAMLightClientCtrlDoubleValueTypePrimaryHeadGainY 65549
scComSAMLightClientCtrlDoubleValueTypePrimaryHeadRotate 65550
scComSAMLightClientCtrlDoubleValueTypePrimaryHeadEnable 65551
scComSAMLightClientCtrlDoubleValueTypeSecondaryHeadOffsetX 65552
scComSAMLightClientCtrlDoubleValueTypeSecondaryHeadOffsetY 65553
scComSAMLightClientCtrlDoubleValueTypeSecondaryHeadGainX 65556
scComSAMLightClientCtrlDoubleValueTypeSecondaryHeadGainY 65557
scComSAMLightClientCtrlDoubleValueTypeSecondaryHeadRotate 65558
scComSAMLightClientCtrlDoubleValueTypeSecondaryHeadEnable 65559
scComSAMLightClientCtrlDoubleValueTypeLaserType 65597
scComSAMLightClientCtrlDoubleValueTypeLaserTypeVersion 65598
scComSAMLightClientCtrlDoubleValueTypeSendCorTableValues 65630
scComSAMLightClientCtrlDoubleValueTypeUsc1MotfSimulate 65638
scComSAMLightClientCtrlDoubleValueTypeUsc1MotfUseYChannel 65640
scComSAMLightClientCtrlDoubleValueTypeUsc1MotfInvertOffset 65661
scComSAMLightClientCtrlDoubleValueTypeUsc2MotfCh0Enable 65662
scComSAMLightClientCtrlDoubleValueTypeUsc2MotfCh1Enable 65663
scComSAMLightClientCtrlDoubleValueTypeUsc2MotfCh0Simulate 65664
scComSAMLightClientCtrlDoubleValueTypeUsc2MotfCh1Simulate 65665
scComSAMLightClientCtrlDoubleValueTypeUsc2MotfCh0Multiplier 65670
scComSAMLightClientCtrlDoubleValueTypeUsc2MotfCh1Multiplier 65671
scComSAMLightClientCtrlDoubleValueTypeUsc2MotfCh0Counter 65718
scComSAMLightClientCtrlDoubleValueTypeUsc2MotfCh1Counter 65719
scComSAMLightClientCtrlDoubleValueTypeDistanceMirrorsMM 196608
scComSAMLightClientCtrlDoubleValueTypeRadiusSecondMirrorMM 196609
scComSAMLightClientCtrlDoubleValueTypeZNumControlPoints 196610
scComSAMLightClientCtrlDoubleValueTypeZCorrFieldSize 196612
scComSAMLightClientCtrlDoubleValueTypeLookupZMMStart 196864
scComSAMLightClientCtrlDoubleValueTypeLookupZDacStart 229632
Table 353: Double Value Types
Temperature OK 0x1
Power OK 0x2
Position OK 0x4
scComSAMLightClientCtrlLongValueTypeExecutionStatus 3
scComSAMLightClientCtrlLongValueTypeOptoIO 4
scComSAMLightClientCtrlLongValueTypeQuantity 5
scComSAMLightClientCtrlLongValueTypeDA1 6
scComSAMLightClientCtrlLongValueTypeDA2 7
scComSAMLightClientCtrlLongValueTypeDeviceEnableFlagsSet 8
scComStandardDeviceEnableFlagGroupStyle 0x0
scComStandardDeviceEnableFlagGroupOptoOut 0x1
scComSAMLightClientCtrlLongValueTypeDeviceEnableFlagsValue 9
scComStandardDeviceStyleFlagEnableLongDelay 0x1
scComStandardDeviceStyleFlagEnablePortLaser 0x2
scComStandardDeviceStyleFlagEnablePort1 0x4
scComStandardDeviceStyleFlagEnableWobble 0x8
scComStandardDeviceStyleFlagEnableYAGStandBy 0x20
scComStandardDeviceStyleFlagEnablePixelOutput (deprecated, use 0x40
BitmapPixelHardwareMode)
scComStandardDeviceStyleFlagEnablePort2 0x80
scComStandardDeviceStyleFlagEnableDA1 0x200
scComStandardDeviceStyleFlagEnableDA2 0x400
scComStandardDeviceStyleFlagEnableSkyWriting 0x2000
scComStandardDeviceStyleFlagEnablePointUsePowerMap 0x400000
scComSAMLightClientCtrlLongValueTypeTotalEntityNum 10
scComSAMLightClientCtrlLongValueTypeToplevelEntityNum 11
scComSAMLightClientCtrlLongValueTypeJobExecutionDelay 12
scComSAMLightClientCtrlLongValueTypeGetMarkCount 13
scComSAMLightClientCtrlLongValueTypeQueueLength 14
scComSAMLightClientCtrlLongValueTypeMaxQuantity 15
scComSAMLightClientCtrlLongValueTypeOverridePen 16
scComSAMLightClientCtrlLongValueTypeMotionAxis 17
scComSAMLightClientCtrlLongValueTypeMotionWaitForEnd 18
scComSAMLightClientCtrlLongValueTypeMotionMoving 19
scComSAMLightClientCtrlLongValueTypeSpiWaveform 20
scComSAMLightClientCtrlLongValueTypeSpiCw 21
scComSAMLightClientCtrlLongValueTypeLineRampingPowerStartRampActive 22
scComSAMLightClientCtrlLongValueTypeLineRampingPowerEndRampActive 23
scComSAMLightClientCtrlLongValueTypeLineRampingSpeedStartRampActive 24
scComSAMLightClientCtrlLongValueTypeLineRampingSpeedEndRampActive 25
scComSAMLightClientCtrlLongValueTypeLineRampingLengthenStartActive 26
scComSAMLightClientCtrlLongValueTypeLineRampingLengthenEndActive 27
scComSAMLightClientCtrlLongValueTypeClientCtrlAsyncMode 28
scComSAMLightClientCtrlLongValueTypeClientCtrlAsyncModeIsRunning 29
scComSAMLightClientCtrlLongValueTypeClientCtrlAsyncModeResult 30
scComSAMLightClientCtrlLongValueTypeGetOptoOut 31
scComSAMLightClientCtrlLongValueTypeStoreRestoreTransformation 32
scComSAMLightClientCtrlLongValueTypeAngularSplittingParts 33
scComSAMLightClientCtrlLongValueTypeDA3 34
scComSAMLightClientCtrlLongValueTypeDA4 35
scComSAMLightClientCtrlLongValueTypeDA5 36
scComSAMLightClientCtrlLongValueTypeDA6 37
scComSAMLightClientCtrlLongValueTypeLastAutoCompensateResult 38
scComSAMLightClientCtrlLongValueTypeDongleUserNumber 39
scComSAMLightClientCtrlLongValueTypeDongleSystemNumber 40
scComSAMLightClientCtrlLongValueTypeHardwareState 41
scComSAMLightClientCtrlLongValueTypeSizePixelMap 42
scComSAMLightClientCtrlLongValueTypeSwitchToPane 43
scComSAMLightClientCtrlLongValueTypeGetTotalSlices 44
scComSAMLightClientCtrlLongValueTypeSliceFrom 45
scComSAMLightClientCtrlLongValueTypeSliceTo 46
scComSAMLightClientCtrlLongValueTypeCurrentSliceNum 47
scComSAMLightClientCtrlLongValueTypePort2 48
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendSourceConstantAlpha 50
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendCenterPointX 51
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendUpperLeftPointX
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendCenterPointY 52
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendUpperLeftPointY
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendBmpDimX 53
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendBmpDimY 54
scComSAMLightClientCtrlLongValueTypeDrillEnable 55
scComSAMLightClientCtrlLongValueTypeDrillEnableCo2Power 56
scComSAMLightClientCtrlLongValueTypeSelectRedpointerForMoveAbs 57
scComSAMLightClientCtrlLongValueTypeEntityArrayCountX 58
scComSAMLightClientCtrlLongValueTypeEntityArrayCountY 59
scComSAMLightClientCtrlLongValueTypeEntityArrayOrderFlags 60
scComSAMLightClientCtrlEntityArrayOrderFlagNegX 0x100
scComSAMLightClientCtrlEntityArrayOrderFlagNegY 0x200
scComSAMLightClientCtrlEntityArrayOrderFlagMainDirX 0x400
scComSAMLightClientCtrlEntityArrayOrderFlagBiDir 0x800
scComSAMLightClientCtrlLongValueTypeGetHeadCount 61
scComSAMLightClientCtrlLongValueTypeSaveView2DBitmapMode 63
scComSAMLightClientCtrlLongValueTypeSelectHatchPair 64
scComSAMLightClientCtrlLongValueTypeRedpointerMode 65
scComSAMLightClientCtrlLongValueTypeSetLockSjfToDongleFlags 66
scComSAMLightClientCtrlLockToDongleFlagLockLoadToSystemId 0x1
scComSAMLightClientCtrlLockToDongleFlagLockLoadToUserId 0x2
scComSAMLightClientCtrlLockToDongleFlagLockExport 0x4
(get only) scComSAMLightClientCtrlLongValueTypeServerStatus 67
SC_USC1_SERVER_STATUS_DEVICE_CONNECTED 0x1
SC_USC1_SERVER_STATUS_DEVICE_OK 0x2
SC_USC1_SERVER_STATUS_DEVICE_MISSING 0x8
SC_USC1_SERVER_STATUS_DEVICE_USC_1 0x10000
SC_USC1_SERVER_STATUS_DEVICE_USC_2 0x20000
SC_USC1_SERVER_STATUS_DEVICE_USC_3 0x80000
(set only) scComSAMLightClientCtrlLongValueTypePrepareLayer
scComSAMLightClientCtrlLongValueTypeXYStatus 68
scComSAMLightClientCtrlLongValueTypeXYStatus1 69
scComSAMLightClientCtrlLongValueTypeSimulationMode 70
scComSAMLightClientCtrlLongValueType3D 71
scComSAMLightClientCtrlLongValueTypeRTCTempX 72
scComSAMLightClientCtrlLongValueTypeRTCTempY 73
scComSAMLightClientCtrlLongValueTypeRTCServo2TempY 74
scComSAMLightClientCtrlLongValueTypeHead2Status 75
Temperature OK 0x1
Power OK 0x2
Position OK 0x4
scComSAMLightClientCtrlLongValueTypeShowCoordinates 76
scComSAMLightClientCtrlLongValueTypeShowWorkingArea 77
scComSAMLightClientCtrlLongValueTypeShowGrid 78
scComSAMLightClientCtrlLongValueTypeBackgroundColor 79
scComSAMLightClientCtrlLongValueTypeRTCTempZ 80
scComSAMLightClientCtrlLongValueTypeCorrectionMode 81
scComSAMLightClientCtrlCorrectionModeOld 0x0
scComSAMLightClientCtrlCorrectionModeRTS 0x1
scComSAMLightClientCtrlCorrectionModeIDW 0x2
scComSAMLightClientCtrlCorrectionMode2dFit 0x4
scComSAMLightClientCtrlLongValueTypeCorrectionPoints 82
scComSAMLightClientCtrlLongValueTypeRTCServoTempX 83
scComSAMLightClientCtrlLongValueTypeRTCServoTempY 84
scComSAMLightClientCtrlLongValueTypeRTCServoTempZ 85
scComSAMLightClientCtrlLongValueTypeRTCServo2TempX
scComSAMLightClientCtrlLongValueType3DSurfaceSetType 86
scComSAMLightClientCtrlLongValueTypeEnable3DSurface 87
scComSAMLightClientCtrlLongValueTypeEnableJobToolbar 88
scComSAMLightClientCtrlLongValueTypeBitmapPixelHardwareMode 89
scComSAMLightClientCtrlLongValueTypeBitmapPenPowerAsMaxPower 90
scComSAMLightClientCtrlLongValueTypeEnableMotf 91
scComSAMLightClientCtrlLongValueType2dFitType 92
scComSAMLightClientCtrlLongValueTypeEnableBmpSplitting 93
scComSAMLightClientCtrlLongValueTypeAngularSplittingSplitAxis 94
scComSAMLightClientCtrlLongValueTypeEnableAllSerialNumbersInJob 95
scComSAMLightClientCtrlLongValueTypeRingSplittingEnableZTiltCompensation 96
scComSAMLightClientCtrlLongValueTypeRingSplittingZMotionAxis 97
scComSAMLightClientCtrlLongValueTypePauseBuild 98
scComSAMLightClientCtrlLongValueTypeShowEntityList 99
scComSAMLightClientCtrlLongValueTypeShowPropSheet 100
scComSAMLightClientCtrlLongValueTypeDrillMarkLineAsDotsActive 101
scComSAMLightClientCtrlLongValueTypeProtectedPen 102
scComSAMLightClientCtrlLongValueTypeShowToolBars 103
SC_SHOW_TOOLBAR_MAIN 0x1
SC_SHOW_TOOLBAR_CAMERA 0x2
SC_SHOW_TOOLBAR_VIEW_LEVEL 0x4
SC_SHOW_TOOLBAR_FUNC_OBJECTS 0x8
SC_SHOW_TOOLBAR_ALIGN 0x10
SC_SHOW_TOOLBAR_GEOM_OBJECTS 0x20
SC_SHOW_TOOLBAR_EXTRAS 0x40
SC_SHOW_TOOLBAR_STEPPER 0x80
SC_SHOW_TOOLBAR_SURFACE 0x100
SC_SHOW_TOOLBAR_ANALOG_IN 0x200
scComSAMLightClientCtrlLongValueType1dMotfReverse 104
scComSAMLightClientCtrlLongValueTypeNewCciErrorReturn 105
scComSAMLightClientCtrlLongValueTypeAfterDefocusDelay 106
scComSAMLightClientCtrlLongValueTypeMarkMode 107
scComStandardDeviceMiscPenPathsAndMarkModeFlagSkipContour 0x10000
scComStandardDeviceMiscPenPathsAndMarkModeFlagSkipHatch1 0x20000
scComStandardDeviceMiscPenPathsAndMarkModeFlagSkipHatch2 0x30000
scComSAMLightClientCtrlLongValueTypeReverseSplitOrder 108
scComSAMLightClientCtrlLongValueTypeDisableSimulationMode 109
scComSAMLightClientCtrlLongValueTypeOpticAxisState 110
X-axis inverted 0x1
Y-axis inverted 0x2
X- & Y-axes inverted 0x3
XY-axis flipped 0x4
scComSAMLightClientCtrlLongValueTypeGetCameraCount 138
scComSAMLightClientCtrlLongValueTypeBackgroundImageFromFileUpdateInMs 139
scComSAMLightClientCtrlLongValueTypeBackgroundImage 140
scComSAMLightClientCtrlLongValueTypeImageFromFileUpdate 141
scComSAMLightClientCtrlLongValueTypeBackgroundImageCrop 142
Table 354: Long Value Types
scComSAMLightClientCtrlStringValueTypeCorrectionFileLcf 29
scComSAMLightClientCtrlStringValueTypeCorrectionFileLcfLensInit 30
scComSAMLightClientCtrlStringValueTypeTrail 31
scComSAMLightClientCtrlStringValueTypeLoadStl 32
scComSAMLightClientCtrlStringValueTypeCurrentUserName 33
scComSAMLightClientCtrlStringValueTypeLanguage 34
scComSAMLightClientCtrlStringValueTypeEntityNamesWithTypeAsInSAMLight 35
scComSAMLightClientCtrlStringValueTypeCreateEntity 36
scComSAMLightClientCtrlStringValueTypeGroupingName 37
scComSAMLightClientCtrlStringValueTypeLoginUserAndPassword 38
scComSAMLightClientCtrlStringValueTypeControlCmdCW300 50
scComSAMLightClientCtrlStringValueTypeUserValue 20000
scComSAMLightClientCtrlStringValueTypeCameraName 40000-40099
Table 355: String Value Types
Double Data ID
scComSAMLightClientCtrlDoubleDataIdHatchDistance1 37
scComSAMLightClientCtrlDoubleDataIdHatchAngle1 38
scComSAMLightClientCtrlDoubleDataIdHatchMinjump1 39
scComSAMLightClientCtrlDoubleDataIdHatchStartoffset1 40
scComSAMLightClientCtrlDoubleDataIdHatchLinereduct1 41
scComSAMLightClientCtrlDoubleDataIdHatchEndoffset1 42
scComSAMLightClientCtrlDoubleDataIdHatchBeamcompensation1 43
scComSAMLightClientCtrlDoubleDataIdHatchNumloops1 44
scComSAMLightClientCtrlDoubleDataIdHatchDistance2 45
scComSAMLightClientCtrlDoubleDataIdHatchAngle2 46
scComSAMLightClientCtrlDoubleDataIdHatchMinjump2 47
scComSAMLightClientCtrlDoubleDataIdHatchStartoffset2 48
scComSAMLightClientCtrlDoubleDataIdHatchLinereduct2 49
scComSAMLightClientCtrlDoubleDataIdHatchEndoffset2 50
scComSAMLightClientCtrlDoubleDataIdHatchBeamcompensation2 51
scComSAMLightClientCtrlDoubleDataIdHatchNumloops2 52
scComSAMLightClientCtrlDoubleDataIdBarcodeLinereduction 69
scComSAMLightClientCtrlDoubleDataIdMotfOffset 70
scComSAMLightClientCtrlDoubleDataIdEntityRotationAngle 71
scComSAMLightClientCtrlDoubleDataIdDataMatrixCellSizeX 72
scComSAMLightClientCtrlDoubleDataIdDataMatrixCellSizeY 73
scComSAMLightClientCtrlDoubleDataIdSpiral2DInnerRadius 74
scComSAMLightClientCtrlDoubleDataIdSpiral2DOuterRadius 75
scComSAMLightClientCtrlDoubleDataIdSpiral2DRise 76
scComSAMLightClientCtrlDoubleDataIdEllipse2DRadiusX 77
scComSAMLightClientCtrlDoubleDataIdEllipse2DRadiusY 78
scComSAMLightClientCtrlDoubleDataIdEllipse2DCenterX 79
scComSAMLightClientCtrlDoubleDataIdEllipse2DCenterY 80
scComSAMLightClientCtrlDoubleDataIdDataMatrixQuietZoneX 81
scComSAMLightClientCtrlDoubleDataIdDataMatrixQuietZoneY 82
scComSAMLightClientCtrlDoubleDataIdHatchPointOffset1 83
scComSAMLightClientCtrlDoubleDataIdHatchMinLength1 84
scComSAMLightClientCtrlDoubleDataIdHatchPointOffset2 85
scComSAMLightClientCtrlDoubleDataIdHatchMinLength2 86
ScComSAMLightClientCtrlDoubleDataIdDataMatrixDistanceBetweenDots 87
ScComSAMLightClientCtrlDoubleDataIdSecondaryHeadTransformationOffsetX 88
ScComSAMLightClientCtrlDoubleDataIdSecondaryHeadTransformationOffsetY 89
ScComSAMLightClientCtrlDoubleDataIdSecondaryHeadTransformationScaleX 90
ScComSAMLightClientCtrlDoubleDataIdSecondaryHeadTransformationScaleY 91
ScComSAMLightClientCtrlDoubleDataIdSecondaryHeadTransformationRotation 92
ScComSAMLightClientCtrlDoubleDataIdHatchLineIndexStep1 93
Double Data ID
ScComSAMLightClientCtrlDoubleDataIdHatchLineIndexStep2 94
scComSAMLightClientCtrlDoubleDataIdHatchVarAngle1 95
scComSAMLightClientCtrlDoubleDataIdHatchVarAngle2 96
ScComSAMLightClientCtrlDoubleDataIdGetMotionCtrlPos 97
ScComSAMLIghtClientCtrlDoubleDataIdEllipse2DSegmentCount 98
scComSAMLightClientCtrlDoubleDataIdHatchLoopAngle1 99
scComSAMLightClientCtrlDoubleDataIdHatchLoopAngle2 100
scComSAMLightClientCtrlDoubleDataIdHatchLayerSolidUpDownSkinBeamComp 101
scComSAMLightClientCtrlDoubleDataIdHatchLayerSolidMinUpSkinArea 102
scComSAMLightClientCtrlDoubleDataIdHatchLayerSolidMinDownSkinArea 103
scComSAMLightClientCtrlDoubleDataIdHatchLayerSolidReduceUp 104
scComSAMLightClientCtrlDoubleDataIdHatchLayerSolidReduceDown 105
Table 356: Double Data ID
Long Data ID
scComSAMLightClientCtrlLongDataIdEntityArrayCountY 5
scComSAMLightClientCtrlLongDataIdEntityArrayStepX 6
scComSAMLightClientCtrlLongDataIdEntityArrayStepY 7
scComSAMLightClientCtrlLongDataIdEntityArrayOrderFlags 8
scComSAMLightClientCtrlEntityArrayOrderFlagNegX 0x100
scComSAMLightClientCtrlEntityArrayOrderFlagNegY 0x200
scComSAMLightClientCtrlEntityArrayOrderFlagMainDirX 0x400
scComSAMLightClientCtrlEntityArrayOrderFlagBiDir 0x800
scComSAMLightClientCtrlLongDataIdTextCharFlags 9
ScComSAMLightClientCtrlLongDataIdTextCharFlagMonoSpaced 0x3
scComSAMLightClientCtrlLongDataIdTextCharFlagItalic 0x10000
scComSAMLightClientCtrlLongDataIdTextCharFlagRadial 0x20000
scComSAMLightClientCtrlLongDataIdTextCharFlagRadialAlignToCharOutline 0x40000
scComSAMLightClientCtrlLongDataIdTextCharFlagReverseOrder 0x80000
scComSAMLightClientCtrlLongDataIdTextCharFlagMirrorCharOnXAxis 0x100000
scComSAMLightClientCtrlLongDataIdTextCharFlagMirrorCharOnYAxis 0x200000
scComSAMLightClientCtrlLongDataIdTextCharFlagSwapLines 0x400000
scComSAMLightClientCtrlLongDataIdTextCharFlagSetToLimitLength 0x800000
scComSAMLightClientCtrlLongDataIdTextCharFlagSetToLimitHeight 0x100000
0
scComSAMLightClientCtrlLongDataIdTextCharFlagSetToLimitKeepAspect 0x200000
0
scComSAMLightClientCtrlLongDataIdTextCharFlagOrderXDown 0x400000
0
scComSAMLightClientCtrlLongDataIdTextCharFlagOrderYUp 0x800000
0
scComSAMLightClientCtrlLongDataIdTextCharFlagOrderYMainUp 0x10000000
scComSAMLightClientCtrlLongDataIdTextCharFlagOrderBiDir 0x20000000
scComSAMLightClientCtrlLongDataIdTextCharFlagRadialCenterMode 0x40000000
scComSAMLightClientCtrlLongDataIdTextFontAvailable 10
scComSAMLightClientCtrlLongDataIdBitmapMode 49
scComSAMLightClientCtrlLongDataIdBitmapModeInvert 0x1
scComSAMLightClientCtrlLongDataIdBitmapModeGreyscale 0x2
scComSAMLightClientCtrlLongDataIdBitmapModeDrillmode 0x4
scComSAMLightClientCtrlLongDataIdBitmapModeBidirectional 0x8
scComSAMLightClientCtrlLongDataIdBitmapModeStartlastline 0x10
scComSAMLightClientCtrlLongDataIdBitmapModeNolineincr 0x20
scComSAMLightClientCtrlLongDataIdBitmapModeShowBitmap 0x100
scComSAMLightClientCtrlLongDataIdBitmapModeShowScanner 0x200
scComSAMLightClientCtrlLongDataIdBitmapModeScanXDir 0x400
scComSAMLightClientCtrlLongDataIdBitmapModePenFrequency 0x800
scComSAMLightClientCtrlLongDataIdBitmapModeJumpOverBlankPixels 0x1000
scComSAMLightClientCtrlLongDataIdBitmapModeDrillGreyscale 0x2000
Long Data ID
scComSAMLightClientCtrlLongDataIdTextWeight 50
scComCharWeightThin 0x64
scComCharWeightExtraLight 0xC8
scComCharWeightLight 0x12C
scComCharWeightNormal 0x190
scComCharWeightMedium 0x1F1
scComCharWeightSemiBold 0x258
scComCharWeightBold 0x2BC
scComCharWeightExtraBold 0x320
scComCharWeightHeavy 0x384
scComSAMLightClientCtrlLongDataIdEnableHatching1 51
scComSAMLightClientCtrlLongDataIdEnableHatching2 52
scComSAMLightClientCtrlLongDataIdEntityMarkLoopCount 55
scComSAMLightClientCtrlLongDataIdEntityMarkBeatCount 56
scComSAMLightClientCtrlLongDataIdEntityMarkStartCount 57
scComSAMLightClientCtrlLongDataIdEntityMarkFlags 58
scComSAMLightClientCtrlLongDataIdEntityMarkFlagMarkContour 0x1
scComSAMLightClientCtrlLongDataIdEntityMarkFlagMarkHatch 0x2
scComSAMLightClientCtrlLongDataIdEntitySetPen 60
scComSAMLightClientCtrlLongDataIdEntitySetTimerValue 61
scComSAMLightClientCtrlLongDataIdEntitySetInOutValue 62
scComSAMLightClientCtrlLongDataIdEntitySetOutputPulse 64
scComSAMLightClientCtrlLongDataIdEntitySetInOutLevel 65
scComSAMLightClientCtrlLongDataIdEntityGetTimerValue 66
scComSAMLightClientCtrlLongDataIdEntityGetInOutValue 67
scComSAMLightClientCtrlLongDataIdEntityGetOutputPulse 69
scComSAMLightClientCtrlLongDataIdEntityGetInOutLevel 70
scComSAMLightClientCtrlLongDataIdEntitySerialStartValue 71
scComSAMLightClientCtrlLongDataIdEntitySerialIncrValue 72
scComSAMLightClientCtrlLongDataIdEntitySerialCurrValue 73
scComSAMLightClientCtrlLongDataIdEntityGetPen 74
scComSAMLightClientCtrlLongDataIdEntityOpticFlags 75
scComSAMLightClientCtrlLongDataIdEntityOpticFlagContour 0x1
scComSAMLightClientCtrlLongDataIdEntityOpticFlagHatch 0x2
scComSAMLightClientCtrlLongDataIdEntitySplittable 76
scComSAMLightClientCtrlLongDataIdEntitySerialNumLines 77
scComSAMLightClientCtrlLongDataIdEntitySetAsBackgroundEntity 78
scComSAMLightClientCtrlLongDataIdEntitySerialBeatCount 79
scComSAMLightClientCtrlLongDataIdEntitySerialResetCount 80
scComSAMLightClientCtrlLongDataIdSetHatchFlags1 81
scComSAMLightClientCtrlLongDataIdSetHatchFlags2 82
Long Data ID
scComSAMLightClientCtrlLongDataIdClearHatchFlags1 91
scComSAMLightClientCtrlLongDataIdClearHatchFlags2 92
scComSAMLightClientCtrlLongDataIdHatchFlagNoSort 0x100
scComSAMLightClientCtrlLongDataIdHatchFlagAllLines 0x400
scComSAMLightClientCtrlLongDataIdHatchFlagPolyLineBeamComp 0x2000
scComSAMLightClientCtrlLongDataIdHatchFlagDontFillRest 0x4000
scComSAMLightClientCtrlLongDataIdHatchFlagKeepAngle 0x80000
scComSAMLightClientCtrlLongDataIdHatchFlagEqualizeDistance 0x100000
0
scComSAMLightClientCtrlLongDataIdHatchFlagBeamCompLoopReverseOrder 0x200000
0
scComSAMLightClientCtrlLongDataIdBarcodeSetFlags 101
scComSAMLightClientCtrlLongDataIdBarcodeClearFlags 102
scComSAMLightClientCtrlLongDataIdBarcodeFlagVariableLength 0x1
scComSAMLightClientCtrlLongDataIdBarcodeFlagInvert 0x2
scComSAMLightClientCtrlLongDataIdBarcodeFlagDisableAutoQuietZone 0x4
scComSAMLightClientCtrlLongDataIdBarcodeFlagQuietZoneAbsolute 0x8
scComSAMLightClientCtrlLongDataIdBarcodeFlagGenerateCheckCode 0x10
scComSAMLightClientCtrlLongDataIdBarcodeFlagInvertExceptText 0x20
scComSAMLightClientCtrlLongDataIdBarcodeFlagInvertCellMode 0x40
scComSAMLightClientCtrlLongDataIdBarcodeFlagCompactMode 0x80
scComSAMLightClientCtrlLongDataIdDataMatrixSetSymbolMode 103
scComSAMLightClientCtrlLongDataIdDataMatrixClearSymbolMode 104
scComSAMLightClientCtrlLongDataIdDataMatrixExSymbolModeRectangle 0x1
scComSAMLightClientCtrlLongDataIdDataMatrixExSymbolModeAutoSize 0x10000
scComSAMLightClientCtrlLongDataIdDataMatrixExSymbolModeAutoEncodatio 0x20000
n
scComSAMLightClientCtrlLongDataIdDataMatrixExSymbolModeDots 0x40000
scComSAMLightClientCtrlLongDataIdDataMatrixExSymbolModeTilde 0x80000
scComSAMLightClientCtrlLongDataIdDataMatrixExSymbolModeCells 0x100000
scComSAMLightClientCtrlLongDataIdDataMatrixExSymbolModeNoFinderCells 0x200000
scComSAMLightClientCtrlLongDataIdDataMatrixExSymbolModeEllipse 0x400000
scComSAMLightClientCtrlLongDataIdDataMatrixExSymbolModeTextFreelyEdita 0x800000
ble
scComSAMLightClientCtrlLongDataIdDataMatrixSymbolSize 105
scComSAMLightClientCtrlLongDataIdDataMatrixEncoding 106
scComSAMLightClientCtrlLongDataIdDataMatrixExEncodationAscii 0x1
scComSAMLightClientCtrlLongDataIdDataMatrixExEncodationBase256 0x2
scComSAMLightClientCtrlLongDataIdDataMatrixExEncodationC40 0x3
scComSAMLightClientCtrlLongDataIdDataMatrixExEncodationText 0x4
scComSAMLightClientCtrlLongDataIdDataMatrixExEncodationAnsiX12 0x5
scComSAMLightClientCtrlLongDataIdDataMatrixExEncodationEdifact 0x6
scComSAMLightClientCtrlLongDataIdDataBarcodeTextEnable 107
Long Data ID
scComSAMLightClientCtrlLongDataIdDataBarcodeLevel 108
scComSAMLightClientCtrlLongDataIdDataBarcodeMode 109
scComSAMLightClientCtrlLongDataIdDataBarcodeSize 110
scComSAMLightClientCtrlLongDataIdEntityLayerCount 111
scComSAMLightClientCtrlLongDataIdEntitySetAsHiddenEntity 112
scComSAMLightClientCtrlLongDataIdSpiralNumInnerRotations 113
scComSAMLightClientCtrlLongDataIdSpiralNumOuterRotations 114
scComSAMLightClientCtrlLongDataIdSpiralNumOuterSegments 115
scComSAMLightClientCtrlLongDataIdSpiralFlags 116
Clockwise 0x1
Start from Outer 0x2
Set Return Path 0x4
scComSAMLightClientCtrlLongDataIdEntitySerialNumModesFlags 117
scComSerialNumber2DModeText 0x1
scComSerialNumber2DModeBarCode 0x2
scComSerialNumber2DModeASCIIFile 0x4
scComSerialNumber2DModeDateTime 0x8
scComSerialNumber2DModeCustomFormat 0x10
scComSAMLightClientCtrlLongDataIdEntityGroupPenPaths 118
scComSAMLightClientCtrlLongDataIdEntityGroupCluster 119
scComSAMLightClientCtrlLongDataIdEntityMirrorOnPlane 120
scComSAMLightClientCtrlLongDataIdEntityOutputAsBitmap 121
scComSAMLightClientCtrlLongDataIdBitmapBlankThreshold 122
scComSAMLightClientCtrlLongDataIdBitmapLineIndexStep 123
scComSAMLightClientCtrlLongDataIdDataMatrixNumberOfDots 124
scComSAMLightClientCtrlLongDataIdEntityGenerate 125
scComSAMLightClientCtrlLongDataIdEnableControl 126
scComSAMLightClientCtrlLongDataIdQrCodeExSetMode 127
scComSAMLightClientCtrlLongDataIdQrCodeExClearMode 128
scComSAMLightClientCtrlLongDataIdQrCodeExModeDots 0x1
scComSAMLightClientCtrlLongDataIdQrCodeExModeCells 0x100000
scComSAMLightClientCtrlLongDataIdQrCodeExModeTextFreelyEditable 0x800000
scComSAMLightClientCtrlLongDataIdEntityCenter 129
scComSAMLightClientCtrlLongDataIdEntityChangeable 130
scComSAMLightClientCtrlLongDataIdEntityRedpointer 131
scComSAMLightClientCtrlLongDataIdEntityJump 132
scComSAMLightClientCtrlLongDataIdEntitySetToDefaultHatchPair 133
scComSAMLightClientCtrlLongDataIdHatchLoop1 134
scComSAMLightClientCtrlLongDataIdHatchLoop2 135
scComSAMLightClientCtrlLongDataIdHatchLayerSolidNumLoops 136
scComSAMLightClientCtrlLongDataIdHatchLayerSolidPointOffset 137
Long Data ID
scComSAMLightClientCtrlLongDataIdBarcodeFlagsHigh 138
scComSAMLightClientCtrlLongDataIdBarcodeFlagsHighLimitLength 0x1
scComSAMLightClientCtrlLongDataIdBarcodeFlagsHighLimitHeight 0x2
scComSAMLightClientCtrlLongDataIdBarcodeFlagsHighKeepAspect 0x4
scComSAMLightClientCtrlLongDataIdBarcodeFlagsHigh 0x8A
scComSAMLightClientCtrlLongDataIdHatchLayerSolidBeamCompOutToIn 139
scComSAMLightClientCtrlLongDataIdEntityNonMarkableEntity 140
scComSAMLightClientCtrlLongDataIdEntityNonEditableEntity 141
scComSAMLightClientCtrlLongDataIdEntityNonSplittablePre 142
scComSAMLightClientCtrlLongDataIdEntityNonSplittablePost 143
scComSAMLightClientCtrlLongDataIdUseMMForSpacing 144
scComSAMLightClientCtrlLongDataIdUseMMforLineSpacing 145
scComSAMLightClientCtrlLongDataIdEntityIoControlObjectMask 146
scComSAMLightClientCtrlLongDataIdEntityIoControlObjectStates 147
Table 357: Long Data ID
scComSAMLightClientCtrlStringDataIdTranslate 29
scComSAMLightClientCtrlStringDataIdRotate 30
scComSAMLightClientCtrlStringDataIdOutlineAndRotate 31
scComSAMLightClientCtrlStringDataIdBarCodeFormatString 32
scComSAMLightClientCtrlStringDataIdSetMotionCtrlsString 33
scComSAMLightClientCtrlStringDataIdSpecialPenAndMore 34
scComSAMLightClientCtrlStringDataIdExportScannerBmp 36
Table 358: Entity String Data ID
ID String Data ID
15.7 Cmd ID
Cmd ID
Cmd ID
scComSAMLightClientCtrlExecCommandMotionGo 16
scComSAMLightClientCtrlExecCommandMotionSendString 17
scComSAMLightClientCtrlExecCommandMotionUpdatePos 18
scComSAMLightClientCtrlExecCommandStopExecution 19
scComSAMLightClientCtrlExecCommandRedPointerStart 20
scComSAMLightClientCtrlExecCommandRedPointerStop 21
scComSAMLightClientCtrlExecCommandUpdateViewNow 22
scComSAMLightClientCtrlExecCommandIncSerialNumber 23
scComSAMLightClientCtrlExecCommandDecSerialNumber 24
scComSAMLightClientCtrlExecCommandView3DViewIso 26
scComSAMLightClientCtrlExecCommandRehatchAll 28
scComSAMLightClientCtrlExecCommandWizardCreateSinglePenGroup 29
scComSAMLightClientCtrlExecCommandSaveSplitsAsOrigEntities 30
scComSAMLightClientCtrlExecCommandWizardDataReductionRedundantPoints 31
scComSAMLightClientCtrlExecCommandCreateBeamCompedCopy 37
scComSAMLightClientCtrlExecCommandSaveSplitsAsEntities 38
scComSAMLightClientCtrlExecCommandCheckIfJobIsInField 40
scComSAMLightClientCtrlExecCommandExitTriggerMode 41
scComSAMLightClientCtrlExecCommandWizardDataReductionShortLines 42
scComSAMLightClientCtrlExecCommandWizardClipper 43
scComSAMLightClientCtrlExecCommandDisableSplit 44
scComSAMLightClientCtrlExecCommandSetMotfFixed 45
scComSAMLightClientCtrlExecCommandSetMotfBmp 46
scComSAMLightClientCtrlExecCommandLogout 47
scComSAMLightClientCtrlExecCommandOpenMarkDialog 48
scComSAMLightClientCtrlExecCommandCloseMarkDialog 49
scComSAMLightClientCtrlExecCommandCorrectSamLight 50
scComSAMLightClientCtrlExecCommandSaveSettingsNow 51
scComSAMLightClientCtrlExecCommandSortJobByName 52
scComSAMLightClientCtrlExecCommandSetMotf 53
scComSAMLightClientCtrlExecCommandUndo 54
scComSAMLightClientCtrlExecCommandWizardOrder 55
scComSAMLightClientCtrlExecCommandWizardCreateOneGroup 57
scComSAMLightClientCtrlExecCommandStoreFlashSettings 58
scComSAMLightClientCtrlExecCommandGroupEntities 59
scComSAMLightClientCtrlExecCommandUngroupEntities 60
scComSAMLightClientCtrlExecCommandWizardClosePolylines 61
scComSAMLightClientCtrlExecCommandWizardOptimizeJumps 62
scComSAMLightClientCtrlExecCommandWizardCreatePenGroups 63
scComSAMLightClientCtrlExecCommandLoadHeadFromUSC3 64
scComSAMLightClientCtrlExecCommandAddPointToCreateEntityPolyline 65
Cmd ID
scComSAMLightClientCtrlExecCommandAddPolylineToCreateEntityPolyline 66
scComSAMLightClientCtrlExecCommandAutosplitOn 67
scComSAMLightClientCtrlExecCommandAutosplitOff 68
scComSAMLightClientCtrlExecCommandDoAutosplit 69
scComSAMLightClientCtrlExecCommandSetCrop 70
scComSAMLightClientCtrlExecCommandSetBackgroundPoints 71
scComSAMLightClientCtrlExecCommandGetCrop 72
scComSAMLightClientCtrlExecCommandGetBackgroundPoints 73
Table 360: Cmd ID
16 Implementation
In general, CCI can be used with any programming environment of your choice. SAMLight offers three
interfaces for remote control which differ in the configuration, communication and return value handling.
Always configure the remote settings in SAMLight (Settings - System - Remote) for the desired interface
(local function calls, remote TCP or remote ASCII) first. Then, proceed as follows depending on your chosen
interface.
1. OCX
a. Initialize COM
b. Instantiate ActiveX control SCAPS.ScSamlightClientCtrl (as needed by your chosen language)
c. (Optional) connect via ScOpenTCPConnection
d. Call desired functions
2. Plain COM
a. Initialize COM
b. Create instance of SCAPS.ScSamlightClientCtrlEx object
c. (Optional) connect via ScOpenTCPConnection
d. Call desired functions
3. ASCII
a. Connect to configured IP and Port
b. Send commands in the configured codepage, with correct end character
c. Wait for end character in return data, interpret return string
Please find examples for OCX integration in Microsoft Visual Studio and for plain COM integration in
Microsoft Visual Studio in the next chapters.
Further information on end characters for ASCII is also given.
The possible return values of the SAMLight Client Control function calls are normally just 0 or 1, but can
also be a long, double or string value.
With the CCI command NewCciErrorReturn the extended error mode can be enabled. Possible function
error return values for more detailed error analysis are:
Note on versions: sc_samlight_client_ctrl.ocx, since installer 3.3.5 Build 232 to 3.4.5 Build 148 also a 64 bit
version is available: sc_samlight_client_ctrl_x64.ocx. Because of a 8.3 filename convention problem with
sc_samlight_client_ctrl.ocx the name of the 64 bit version was changed to sc_x64_samlight_client_ctrl.ocx
with installer 3.4.5 Build 149.
Figure 2 illustrates how to use SCAPS.ScSamlightClientCtrlEx with Microsoft Visual Studio: SAMLight Client
Control Ex is added via Reference.
The SAMLight Client Control Ex interface uses the same SAMLight Client Control commands and constants
but offers a more detailed error return value for each command.
Please start at the References at the left side and follow the red arrows.
The possible HRESULT function error return values for more detailed error analysis are:
COM CCI HRESULT Name Description
0x80040200 Unknown error please inform SCAPS by e-mail: [email protected]
Under C#, if one of these HRESULT are returned by a ScSamlightClientCtrlEx function, the C# RCW
(runtime callable wrapper) of the function converts this error (facility ITF) into a corresponding .Net COM
Exception, containing the information above.
CCI COM cannot be used in combination with TCP ASCII Communication Mode.
Note on versions: SAMLight Client Control Ex with Ex for Extended, included since installer 3.5.5 Build
0002: 32 bit version sc_ex_samlight_client_ctrl.dll and 64 bit version sc_ex64_samlight_client_ctrl.dll.
ASCII CCI
Command to SAMLight Return from SAMLight
New line End of command New line End of return
\r\n [a] <LF> <CR><LF> [b] <LF>
Table 365: ASCII CCI new line, end of command and end of return control characters.
[a]: \r\n as text, four ASCII chars: 0x5C 0x72 0x5C 0x6E
[b]: For ASCII CCI: It is possible to receive multi-line strings, but only if you wait a certain time until all lines
are received.
16.4 cci.
In our program examples we start our commands always via "cci.". But this is no default setup and has to be
defined in the MS Visual Studio.
During the Implementation (see OCX) you drag and drop the OCX library into the Studio Form1. If you
choose this object and open the properties dialog you can define as name cci.
17 Programming Examples
17.1 Create beam-compensated Copy of Entity
The following examples shows how to create a beam compensated copy of an entity.
//define the original entity from which the copy should be created
cci.ScSetStringValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlStringValueTypeStringPara1, "OriginalEntity" );
// generating fixed size colored View2D screenshots with SAMLight Windows opened in background
cci.ScSetStringValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlStringValueTypeSaveView2D160, path + "\
\ScreenshotView2D160.bmp" );
cci.ScSetStringValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlStringValueTypeSaveView2D320, path + "\
\ScreenshotView2D320.bmp" );
cci.ScSetStringValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlStringValueTypeSaveView2DFull, path + "\
\ScreenshotView2DFull.bmp" );
// generating variable size colored View2D screenshot with SAMLight Windows opened in background
cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapVariableSi
ze, 640 ); // set bitmap size in pixel
cci.ScSetStringValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlStringValueTypeSaveView2DVariableSize,
path + "\\ScreenshotView2DVariableSiz.bmp" );
// generating black and white View2D screenshot with just SAMLight running background
cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapX, 0 ); //
set center in X (like View2D coordinate system)
cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapY, 0 ); //
set center in Y (like View2D coordinate system)
cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapXW,
10 ); // set size in X in mm (like View2D coordinate system)
cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapYW,
10 ); // set size in Y in mm (like View2D coordinate system)
cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeSaveView2DBitmapDPI,
200 ); // set bitmap resolution in DPI
cci.ScSetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeSaveView2DBitmapMode,
0 ); // 0: lines and pixels are drawn normal
cci.ScSetStringValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlStringValueTypeSaveView2DAdjustableDPI,
path + "\\ScreenshotView2DAdjustableDPI_DrawnNormal.bmp" );
// define pixel and line thickness and save the screenshot with a new name
cci.ScSetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeSaveView2DBitmapMode,
1 ); // 1: lines and pixels are drawn thicker
cci.ScSetStringValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlStringValueTypeSaveView2DAdjustableDPI,
path + "\\ScreenshotView2DAdjustableDPI_DrawnThicker.bmp" );
Table 367: Create screenshot of SAMLight View2D
//specify thetext size; this value will be taken, if dim_x = dim_y = 0 in ScCreateEntity,
//otherwise it will be ignored
cci.ScSetEntityDoubleData("ScCreateEntity", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdTextSize, 9);
//create the entity of the type defined above, name it "MyEntity", "" for Father - group(no group),
//apply pen = 3, position its center at(x | y | z) = (0 | 0 | 0)
//in the coordinate system, definethe dimension dim_x = 20, dim_y = 10.The last two
cci.ScCreateEntity("MyEntity", "", 3, 0, 0, 0, 20, 10, 0, "");
Table 368: Create text entity (ScWinTextChars2D)
17.3.2 BarCode
Create barcode entity (ScBarCode12Chars2D)
cci.ScSetEntityStringData("ScCreateEntity", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlStringDataIdSetBarcodeType, "QR Code");
//define the desired mode of the barcode, if available; if this is not defined,
//the first level will be taken as default.Note, that your barcode might not be valid
//for every content in the default mode and will not be created in this case.
cci.ScSetEntityLongData("ScCreateEntity", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLongDataIdDataBarcodeMode, 2);
//define the desired level of the barcode, if avaiable; if this is not defined,
//the first level will be taken as default.Note, that your barcode might not be valid
//for every content with the default level and will not be created in this case.
cci.ScSetEntityLongData("ScCreateEntity", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLongDataIdDataBarcodeLevel, 1);
//create the entity of the type defined above, name it "MyEntity", apply pen = 3,
//position its center at(x | y | z) = (0 | 0 | 0) in the coordinate system,
//deactivate the definition of the dimension with dim_x = 0, dim_y = 0
cci.ScCreateEntity("MyEntity", "", 3, 0, 0, 0, 0, 0, 0, "");
Table 369: Create barcode entity (ScBarCode12Chars2D)
17.3.3 SerialNumber
Create serial number entity (ScSerialNumber2D)
//specify the text size; this value will be taken, if dim_x = dim_y = 0 in ScCreateEntity,
//otherwise it will be ignored
cci.ScSetEntityDoubleData("ScCreateEntity", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdTextSize, 9);
, 12);
//create the entity of the type defined above, name it "MyEntity", apply pen = 4, position its
//center at(x | y | z) = (10 | 50 | 0) in the coordinate system, deactivate the definition
//of the dimension with dim_x = 0, dim_y = 0
cci.ScCreateEntity("MyEntity", "", 4, 10, 50, 0, 0, 0, 0, "");
Table 370: Create serial number entity (ScSerialNumber2D)
17.3.4 Ellipse
Create ellipse/circle entity (ScEllipse 2D)
cci.ScSetStringValue((int)
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlStringValueTypeCreateEntity,"ScEllipse2D");
//create the entity of the type defined above, name it "MyEntity", apply pen = 3,
//position its center at(x | y | z) = (0 | 0 | 0) in the coordinate system,
//deactivate the definition of the dimension with dim_x = 0, dim_y = 0
cci.ScCreateEntity("MyEntity", "", 3, 0, 0, 0, 25, 15, 0, "");
Table 371: Create ellipse/circle entity (ScEllipse 2D)
17.3.5 Rectangle
Create rectangle entity (ScRectangle 2D)
//create the entity of the type defined above, name it "MyEntity", apply pen = 3,
//position its center at(x | y | z) = (0 | 0 | 0) in the coordinate system,
//deactivate the definition of the dimension with dim_x = 0, dim_y = 0
cci.ScCreateEntity("MyEntity", "", 3, 0, 0, 0, 25, 15, 0, "");
Table 372: Create rectangle entity (ScRectangle 2D)
17.3.6 PolyLine
Create polyline entity (ScPolyLine 2D)
//create the entity of the type defined above, name it "MyEntity", apply pen = 3,
//position its center at(x | y | z) = (0 | 0 | 0) in the coordinate system,
//deactivate the definition of the dimension with dim_x = 0, dim_y = 0
cci.ScCreateEntity("MyEntity", "", 3, 0, 0, 0, 25, 15, 0, "");
Table 373: Create polyline entity (ScPolyLine 2D)
Correct ucf
// Execute the correction with <SCAPS>\system\sc_calib_points.txt and apply the new correction file in
SAMLight.
cci.ScExecCommand( ( int )
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandCorrectSamLight );
Table 374: Correct ucf
// deselect all
cci.ScSetEntityLongData( "",
( int ) ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLongDataIdEntitySelected |
( int ) ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLongDataIdFlagDontUpdateView, 0 );
// select
cci.ScSetEntityLongData( EntityName,( int )
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLongDataIdEntitySelected, 1 );
cci.ScExecCommand( ( int )
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandFitViewToSelectedEnt
ities );
Table 375: Fit view to an entity
//Only ask for the documented server stati using a mask combined with & at the end
cci.ScGetLongValue( (int)
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeServerStatus ) & 0x3000B
// Here, the mask 0x3000B ensures only to look for the bits at the position x in binary representation:
00xx 0000 0000 0000 x0xx, which are the documented parameters (1, 2, 8, 65536 and 131072 in decimal
representation) for scComSAMLightClientCtrlLongValueTypeServerStatus.
cci.ScGetLongValue( (int)
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeServerStatus ) & 0x30000
//If you only want to know if the connected device is a USC-1 or USC-2 card, use a mask for the
corresponding values (x in binary representation 00xx 0000 0000 0000 0000, 65536 and 131072 in decimal
representation) which would be 0x30000 in hexadecimal representation.
// a buffer for the ASCII command lines that have to be sent, the its maximum size is defined in
ScCciCommands.h
char msgStr[ SC_CCI_MAX_COMMANDLENGTH ];
// send the initialization string to set up the interface for the ASCII protocol
DoSend( SC_CCI_INITSTRING );
// create the command line that has to be sent, that function call results in a command
"ScCciChangeTextByName("MyEntity", "NewText")\n" that is stored in msgStr
sprintf( msgStr, SC_CCI_CMD_CHANGE_TEXT_BY_NAME, "MyEntity", "NewText" );
// send the command to get the minimum horizontal position of the entities outline
sprintf( msgStr, SC_CCI_CMD_GET_ENTITY_OUTLINE, "MyEntity", 0 );
DoSend( msgStr );
// convert the returned string into a double value; please note: if fetching of the outline value failed,
the returned string is "NaN" (=not a number)
outline_min_x = atof( DoReceive() );
// an alternative possibility to send a command, here all values are statically so that it is not
necessary to "construct" the command using sprintf()
DoSend( "ScCciGetEntityOutline(\"MyEntity\", 3)\n" );
· If the condition markFlags & TriggerFlag == markFlags is satisfied, the WaitForTrigger flag is already
active.
· If the above condition does not hold, the flag is not active.
Deactivate Flag
// Mirror Entity
cci.ScScaleEntity( EntityName, -1, 1, 1 );
cci.ScExecCommand( ( int )
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandMotionGo );
cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeMotionAxisPositionRelative, 100 );
cci.ScSetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeMotionAxis, 1 );
cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeMotionAxisAngle, 720 );
cci.ScExecCommand( ( int )
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandMotionGo );
int axis0 = 1;
int axis1 = 1;
do
{
if( axis0 == 1 )
{
cci.ScSetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeMotionAxis, 0 );
if( cci.ScGetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeMotionMoving ) == 0 )
{
MessageBox.Show( "Motor with axis 0 has stopped." );
axis0 = 0;
}
}
if( axis1 == 1 )
{
cci.ScSetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeMotionAxis, 1 );
if( cci.ScGetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeMotionMoving ) == 0 )
{
MessageBox.Show( "Motor with axis 1 has stopped." );
axis1 = 0;
}
}
} while ( ( axis0 == 1 ) || ( axis1 == 1 ) ) ;
Table 386: Motion Control type 5
// Enable ModeFlagEntityNamesSeparatedBySemicolon
int ModeFlags = 0;
int CciReturn2 = cci.ScGetMode( ref ModeFlags );
Retrieve Entities
// important: the BSTR-pointer has to be initialized, otherwise the COM -interface may crash!
string name = "", type = "";
int i, count;
// step through all available toplevel entities
cci.ScSetMode( ( int )ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagTopLevelOnly );
count = cci.ScGetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeTopLevelEntityNum );
if( count > 0 )
{
for( i = 0; i < count; i++ )
{
// get the name of the entity at the index position "i"
cci.ScGetIDStringData( ( int )
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlStringDataIdGetToplevelEntity, i, ref name );
if( name == "" )
name = "'empty'";
cci.ScGetIDStringData( ( int )
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlStringDataIdGetEntityType, i, ref type );
MessageBox.Show( "entity number: " + ( i + 1 ) + ", entity name: " + name + ",entity type: " +
type, "total number of toplevel entities: " + count.ToString() );
}
}
else
MessageBox.Show( "No top level entities found", "total number of toplevel entities: 0" );
// step through all available entities
cci.ScSetMode( 0 );
count = cci.ScGetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeTotalEntityNum );
if( count > 0 )
{
for( i = 0; i < count; i++ )
{
// get the name and type of the entity at the index position "i"
cci.ScGetIDStringData( ( int )
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlStringDataIdGetEntity_Name, i, ref name );
if( name == "" )
name = "'empty'";
cci.ScGetIDStringData( ( int )
Retrieve Entities
// Rotate the output matrix for 20 degrees around the middle of the entity center and marks again.
This step will be repeated 19 times.
if( cci.ScIsRunning() == 0 )
{
MessageBox.Show( "SAMLight not found", "Warning" );
return;
}
cci.ScExecCommand( ( int)
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandNewJob );
cci.ScExecCommand( ( int )
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandResplitJob ); //
scComSAMLightClientCtrlExecCommandResplitJob = 13
cci.ScSetStringValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlStringValueTypeSaveSplitsJobFileName,
Environment.ExpandEnvironmentVariables( @"%SCAPS_SAM%" ) + "\\jobfiles\
\demo_splitted_as_tiles.sjf" );
cci.ScExecCommand( ( int )
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandSaveSplitsAsEntities
); // scComSAMLightClientCtrlExecCommandSaveSplitsAsEntities = 38
With hard array copy (Menu > Edit > ArrayCopy), the new generated copies are added in entity list.
Hard Array Copy
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlEntityArrayOrderFlagNegX | ( int )
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlEntityArrayOrderFlagNegY | ( int )
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlEntityArrayOrderFlagMainDirX );
int CCI_Return_02 = cci.ScSetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeEntityArrayCountX, 2 );
int CCI_Return_03 = cci.ScSetLongValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlLongValueTypeEntityArrayCountY, 2 );
int CCI_Return_04 = cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeEntityArrayStepX, 9.0 );
int CCI_Return_05 = cci.ScSetDoubleValue( ( int )
ScComSAMLightClientCtrlValueTypes.scComSAMLightClientCtrlDoubleValueTypeEntityArrayStepY, 9.0 );
int CCI_Return_06 = cci.ScSetEntityStringData( "circle", (int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlStringDataIdArrayCopyHard, "circle copy" );
Table 391: Hard Array Copy
With virtual array copy (EntityInfo > Array), the generated copies are not added in entity list, but still will be
marked in sequence. Please pay attention that the unit of the commands for step is [um].
Virtual Array Copy
If there's a need to update the view, you can do it by executiong the UpdateViewNow command:
cci.ScExecCommand((int)
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandUpdateViewNow);
Table 395: Manual view update
Suppress View2D update if you change more than one property of the same entity
at once:
Like mentioned above every entity change will be shown in View2D after any change of its properties. If you
want to change more than one property of the same entity, you can suppress View2D update of the entity.
Then the change of the entity will not be shown after after every call. To do so use:
You will find a detailed example in the chapter Optimize performance: Example 1.
Suppress entity update if you change more than one property of the same entity at
once:
Like mentioned above every entity will be regenerated and updated after any change of its properties. If you
want to change more than one property of the same entity you can suppress this behavior so that the entity
will not be regenerated and updated after after every call.
Please make sure that you are not using this flag at the last change of an entity. Otherwise this
entity will not be regenerated and updated at all.
17.18.1 Example 1
To demonstrate how to use the CI calls properly we want to give an example code.
Consider you have 20 barcode entities in SAMLight with the entity names barcode1, barcode2, ...,
barcode20. We want to change for each barcode:
1. Enable Hatch1 with style 'wavy line without marking the jumps'
2. Enable Hatch2 with style 'zigzag'
A common way to program this changes in C# would be:
This looks fine and will work properly but after every of the 60 CI calls the corresponding entity will get
regenerated and the View2D of SAMLight will be updated. This needs a lot of time.
We will now demonstrate how the same goal can be reached by using 3 CI calls instead of 60. To do so we
create two strings: containing all the entity names and the text for each of them. But we separate every entry
in the string by semicolon and will use the NamesSeparatedBySemicolon flag to change the properties at
once. Furthermore every entity will be regenerated only once and the View2D of SAMLight will only be
updated after the last entity change was completed. This is achieved by using DontUpdateView and
TopLevelOnly flags.
//Generate one string 'all_entity_names' with all entity names separated by ";"
//and generate one string 'all_entity_texts' with all entity textes separated by "\v"
string all_entity_names = "barcode1";
string all_entity_texts = "This is the text of barcode 1";
for (int i = 2; i <= 20; i++)
{
all_entity_names = all_entity_names + ";" + "barcode" + Convert.ToString(i);
all_entity_texts = all_entity_texts + "\v" + "This is the text of barcode" +
Convert.ToString(i);
}
//enable entity name separated by semicolon mode
//disable View2D
//enable top level entities only
cci.ScSetMode((int)
ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagEntity_NamesSeparatedBySemicolon |
(int)ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagDontUpdateView |
(int)ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagTopLevelOnly);
//change all texts of all entities
cci.ScChangeTextByName(all_entity_names, all_entity_texts);
//enable Hatching1 and Hatching2 for all entities, suppress entity update after enabling Hatching 1
//so the entities will be updated after the enabling of Hatching 2 (second call)
cci.ScSetEntityLongData(all_entity_names,
(int)ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLongDataIdEnableHatching1 |
(int)ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlDoubleDataIdFlagDontUpdateEntity, 1);
cci.ScSetEntityLongData(all_entity_names,
(int)ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlLongDataIdEnableHatching2, 6);
//reset ScSetMode
cci.ScSetMode(0);
//manually update View2D
cci.ScExecCommand((int)
ScComSAMLightClientCtrlExecCommandConstants.scComSAMLightClientCtrlExecCommandUpdateViewNow);
17.18.2 Example 2
The following C# example shows and measures how much SAMLight Client Control performance constants
can accelerate the executed SAMLight Client Control commands.
In this case the cursive font, text size, font type and the text content of a Text2D entity with entity name "text
entity" are set 100 times as substitute for 100 different text entities to show how SAMLight Client Control
performance constants can be used.
using SAMLIGHT_CLIENT_CTRL_OCXLib;
using System.Diagnostics;
Table 399: Import necessary namespaces
As first we will change the text entities without introducing the performance increasing flags. We will make
the text in the text entities to be italic and of Arial type, change the size to 20 and change the text of the
entities.
As next we switch on TopLevelOnly and DontUpdateView flags, so that the view is not updated while we
change the entity properties and update the view using UpdateViewNow. It decreases the computation
time approximately by factor 1.5 - 2.0.
We can do even better by suppressing the entity update and the view update, while executing each
particular entity update command. We can do so by accelerating ScSetEntityLongData,
ScSetEntityDoubleData, ScSetEntityStringData directly by using additional flags.
The last command (here: cci.ScChangeTextByName("text entity", "new text")) should not contain
DontUpdateEntity or DontUpdateview flags, otherwise the entity will not be updated at all.
18 Error Codes
The possible return values of the SAMLight Client Control function calls are normally just 0 or 1, but can
also be a long, double or string value. With the CCI command NewCciErrorReturn, more error return values
are activated. The possible function error return values for more detailed error analysis are:
Error Code
Command implemented wrong 0
Command run succesful 1
IDispatch error #17: no named entity found -10000
IDispatch error #18: job is empty -10001
IDispatch error #19: function returned 0 ( not ok ) -10002
IDispatch error #20: not allowed in 3D mode -10003
IDispatch error #22: no valid license -10004
IDispatch error #24: Object Out of Field -10006
Table 403: Error Codes
19 Deprecated commands
This chapter contains all deprecated commands. Some of them should not be used anymore, others have
been replaced.
Drill Dimension
Deprecated Motion Go
Deprecated CW 300
ScSetStringLongValue
ScSetStringLongValue
Table 423: Deprecated Base Functions
Deprecated Remote
Reason Renamed.
Command scComSAMLightClientCtrlDoubleValueTypeSaveView3DBitmapDPI
Use: SaveView2DBitmapDPI
scComSAMLightClientCtrlDoubleValueTypeSaveView3DBitmapVariableSize
Use: SaveView2DBitmapVariableSiz
scComSAMLightClientCtrlDoubleValueTypeSaveView3DBitmapX
Use: SaveView2DBitmapX
scComSAMLightClientCtrlDoubleValueTypeSaveView3DBitmapY
Use: SaveView2DBitmapY
scComSAMLightClientCtrlDoubleValueTypeSaveView3DBitmapXW
Use: SaveView2DBitmapXW
scComSAMLightClientCtrlDoubleValueTypeSaveView3DBitmapYW
Use: SaveView2DBitmapYW
Table 427: Deprecated Save View 3D Bitmap
scComSAMLightClientCtrlDoubleValueTypeBmpAlphaBlendDimYTo
scComSAMLightClientCtrlDoubleValueTypeBmpAlphaBlendPointXTo
scComSAMLightClientCtrlDoubleValueTypeBmpAlphaBlendPointYTo
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendBmpDimX
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendBmpDimY
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendCenterPointX
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendCenterPointY
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendSourceConstantAlpha
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendUpperLeftPointX
scComSAMLightClientCtrlLongValueTypeBmpAlphaBlendUpperLeftPointY
scComSAMLightClientCtrlStringValueTypeBmpAlphaBlendPathBmp
Table 428: Deprecated Alpha Blend
Reason Renamed.
Command scComSAMLightClientCtrlLongValueTypeSpiG3Cw
Use: SpiCw
scComSAMLightClientCtrlLongValueTypeSpiG3Waveform
Use: SpiWaveform
Table 431: Deprecated SPI laser specials