Difference between revisions of "MC-Basic:COMMON SHARED ... AS PLS"
m |
m |
||
Line 2: | Line 2: | ||
{{MC-Basic | {{MC-Basic | ||
+ | |DESCRIPTION= | ||
+ | <big><span style="color: purple">Updated 2018-10</span></big> | ||
− | + | This command declares a programmable limit switch (PLS) variable. | |
− | This command declares a programmable limit switch (PLS) variable. | + | |
+ | The declaration specifies the name of the axis and the output associated with the PLS. | ||
− | + | The PLS output may be a digital output (SYSTEM.DOUT.x) or a virtual output (SYSTEM.VOUT.x). | |
− | |||
− | |||
− | |||
− | |||
− | + | After this command is issued, the PLS exists but is disabled. The PLS property <pls>.PLSENABLE is used to enable the PLS. | |
− | + | After PLS is declared, the following default PLS properties are in effect: | |
+ | * The initial output polarity is 0. | ||
+ | * The repetition interval is 0. | ||
+ | * The hysteresis is 0. | ||
+ | * A single PLS position set as 0. | ||
+ | These properties can be set explicitly only when the PLS is disabled. | ||
|SYNTAX= | |SYNTAX= |
Revision as of 13:54, 8 October 2018
Language: | [[::MC-Basic:COMMON SHARED ... AS PLS|English]] • [[::MC-Basic:COMMON SHARED ... AS PLS/zh-hans|中文(简体)]] |
---|
Updated 2018-10
This command declares a programmable limit switch (PLS) variable.
The declaration specifies the name of the axis and the output associated with the PLS.
The PLS output may be a digital output (SYSTEM.DOUT.x) or a virtual output (SYSTEM.VOUT.x).
After this command is issued, the PLS exists but is disabled. The PLS property <pls>.PLSENABLE is used to enable the PLS.
After PLS is declared, the following default PLS properties are in effect:
- The initial output polarity is 0.
- The repetition interval is 0.
- The hysteresis is 0.
- A single PLS position set as 0.
These properties can be set explicitly only when the PLS is disabled.
Syntax
COMMON SHARED <pls>As Pls <axis> <output> {HWAssistance = TRUE/FALSE }
Availability
HWAssistance: Since Version 4.1.11 / 4.2.16 firmware with 8.7.1 Altera version </font>
Type
<pls>:string
<axis>: string
Range
<axis>: a valid axis name
<output>: the name of a system output. System outputs are specified by
- System.DOut.x, for digital outputs, or
- System.VOut.x, for virtual outputs.
- System.DOut.x, for digital outputs, or
The hardware assisted PLS works with System.DOut from 1 to 8
<HWAssistance>: TRUE - starts the hardware assisted PLS mode
FALSE
The value xidentifies the specific output to be used. It may be explicitly given or it may be an expression. The expression must evaluate to an integer ranging from 1 to 20 for digital outputs or from 1 to 32 for virtual outputs.
Scope
Configuration or Terminal .
Since Version 4.5.17 the global (common shared) declaration is also possible from the Library or Task contexts. In those contexts all three parameters of PLS (axis name, system output and HWassistance flag) can be reassigned during the reloading the declaring task or library.
Limitations
Write only
HWAssistance feature works for Digital Logic Pentium III CPU with 8.7.1 Altera version only !
Examples
Common Shared Pls1 as PLS x_axis SYSTEM.Dout.4
Common Shared Pls2 as PLS x_axis SYS.Dout.8 HWAssistance = TRUE
Common Shared Pls3 as PLS x_axis SYS.Dout.3 HWAssistance = FALSE