en:software:qview:qview_6:qcl_library:dw31wrcam

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

en:software:qview:qview_6:qcl_library:dw31wrcam [2017/03/24 16:14] – created qem103en:software:qview:qview_6:qcl_library:dw31wrcam [2019/08/29 17:01] (current) – external edit 127.0.0.1
Line 1: Line 1:
 +====== DW31WrCam ======
 +
 +**D = **//Device(CAMMING3, CAMMING4)//
 +
 +**W = **//Writing functions//
 +
 +*** = **//Replaces the function ////**DW30WrCam**//
 +
 +The DW31WrCam function __is used to write the fields to build an electronic cam__. The function you will need to pass as parameters a pointer to start and one of the end which serve to identify the sector where you want to start writing and the area where you want to stop. La funzione scrive 128 settori della camma.
 +
 +===== IMPLEMENTATION =====
 +
 +**DW31WrCam (cmCamma, aslParam, CodeG, CodeM, CodeQm, CodeQs, CodeQma, CodeQsa, Error)**
 +
 +Parameters:
 +
 +^IN/OUT^VARIABLE TYPE^EXAMPLE NAME^DIM^^
 +|  IN  |  CAMMING3\\ CAMMING4  |  cmCamma  |  -  |Type of device to which you can apply the function|
 +|  IN  |  ARRSYS  |  aslParam[1]  |  L  |Sector number of start writing|
 +|  IN  |  SYSTEM  |  aslParam[2]  |  L  |Sector number of end writing (valid only if 'aslParam[3]' is to 0)|
 +|  IN  |  SYSTEM  |  aslParam[3]  |  L  |Number of sectors to write (optional in the case of use 'aslParam[2]')|
 +|  IN  |  SYSTEM  |  aslParam[4]  |  L  |Array element number from which to begin reading values (is you set to 0 start with the first element)|
 +|  IN  |  ARRSYS  |  CodeG  |  W/L  |Array containing Code G calculated|
 +|  IN  |  ARRSYS  |  CodeM  |  W/L  |Array containing Code M calculated|
 +|  IN  |  ARRSYS  |  CodeQm  |  L  |Array containing calculated space Master|
 +|  IN  |  ARRSYS  |  CodeQs  |  L  |Array containing calculated space Slave|
 +|  IN  |  ARRSYS  |  CodeQma  |  L  |Array containing Qma code (auxiliary code)|
 +|  IN  |  ARRSYS  |  CodeQsa  |  L  |Array containing Qsa code (auxiliary code)|
 +|  OUT  |  SYSTEM  |  Errore  |  B  |Error var in the cam writing|
 +
 +==== Use mode ====
 +
 +The "aslParam[1]" parameter (starting sector) indicates the number of the field in which you want to start writing the cam, while "aslParam[4]" (initial array element) indicates the number of the element of the array (CodeG, CodeM, etc..) from which you will start to copy the values in the sectors.\\
 +If the "aslParam[2]" parameter (ending sector) is not set to 0, writing sectors ending with the sector of this number, if the parameter is to 0 the writing continues for the number of sectors set in "aslParam[3]" parameter (number of sectors to write).
 +
 +==== Error ====
 +
 +Once invoked the function if there are errors the error variable assumes certain values, the meaning of these values is described below:\\
 +0 - No errors\\
 +1 - Indices of the start and/or end wrong writing
 +
 +=== Example ===
 +
 +<code QCL>
 +MAIN:
 +
 +IF gfScrittCam
 +    gfScrittCam = 0
 +    aslParam[1] = 1 ;He started writing from 1° sector of the cam
 +    aslParam[4] = 10 ;Start reading from 10th element of the array
 +    DW31WrCam (cmCamma, aslParam, CodeG, CodeM, CodeQm, CodeQs, CodeQma, CodeQsa, Error)
 +    IF sbErrore
 +        JUMP FINE
 +    ENDIF
 +ENDIF
 +</code>