Difference between revisions of "MC-Basic:BUS.CYCLETIME"

From SoftMC-Wiki
Jump to: navigation, search
m (Text replace - "|AVAILABILITY= Version 4.9.11" to "|AVAILABILITY= Since Version 4.9.11")
 
(6 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 +
{{Languages|MC-Basic:BUS.CYCLETIME}}
 
{{MC-Basic
 
{{MC-Basic
 
|SHORT FORM=
 
|SHORT FORM=
Line 7: Line 8:
  
 
|AVAILABILITY=
 
|AVAILABILITY=
Since Version 4.9.11
+
Since Version 4.9.11<br>
 +
Since Version 4.15.5 bus #0 is reserved for EtherCAT, bus #1 is reserved for CAN.<br>
 +
Bus[0] provides master clock period, while bus[1] is slave to bus[0] and accepts only integer multiplication of cycle time of bus[0].<br>
 +
For instance, if bus[0].cycletime is set to 2000, bus[1].cycletime can be set to 2000, 4000, 6000, 8000 uSecs.<br>
  
 
|DESCRIPTION=
 
|DESCRIPTION=
 +
Set or query automation bus cycle time.
  
 
|TYPE=
 
|TYPE=
Line 29: Line 34:
  
 
|LIMITATIONS=
 
|LIMITATIONS=
 
+
EtherCAT: Object 0x60c2 shall be updated according to Master Cycle Time use [[EtherCAT:EC_SET_CYCLETIME]] to control cycle time. <br>
 +
CANopen: Object 0x60c2 shall be updated according to Master Cycle Time.<br>
 +
'''Bus[0].cycletime must be set before Bus[1].cycletime.'''
 
|EXAMPLE=
 
|EXAMPLE=
 
?BUS[0].Cycletime<br>
 
?BUS[0].Cycletime<br>
BUS[0].Cycletime = 2000
+
BUS[0].Cycletime = 2000<br>
 +
BUS[1].Cycletime = 2000<br>
  
 
|SEE ALSO=
 
|SEE ALSO=

Latest revision as of 07:20, 24 April 2017

Language: English  • 中文(简体)‎

Set or query automation bus cycle time.

Syntax

?BUS[<bus_number>].Cycletime
BUS[<bus_number>].Cycletime = <expression>

Availability

Since Version 4.9.11
Since Version 4.15.5 bus #0 is reserved for EtherCAT, bus #1 is reserved for CAN.
Bus[0] provides master clock period, while bus[1] is slave to bus[0] and accepts only integer multiplication of cycle time of bus[0].
For instance, if bus[0].cycletime is set to 2000, bus[1].cycletime can be set to 2000, 4000, 6000, 8000 uSecs.

Type

<return value>: Long
<bus_number>: Long
<expression>: Long, Double

Units

Microseconds

Scope

Configuration, Task or Terminal

Limitations

EtherCAT: Object 0x60c2 shall be updated according to Master Cycle Time use EtherCAT:EC_SET_CYCLETIME to control cycle time.
CANopen: Object 0x60c2 shall be updated according to Master Cycle Time.
Bus[0].cycletime must be set before Bus[1].cycletime.

Examples

?BUS[0].Cycletime
BUS[0].Cycletime = 2000
BUS[1].Cycletime = 2000