托盘区块必须有一个电源扇区引用(功能块输入 "PowerSec")。该扇区引用的类型为Mc6DPowerSecType。
布局配置中定义的每个扇区都会创建一个扇区参照。使用MC_BR_AsmGetPowerSec_Acp6D 调用扇区参考。输出 "PowerSec "的地址可直接用于其他功能块。
也可将此功率扇区引用存储在Mc6DPowerSecType 类型的过程变量中,以便日后使用。
ST code:
IF(MC_BR_AsmGetPowerSec_Acp6D_0.Valid == TRUE) THEN
MC_BR_PowerSecDeactivate_Acp6D_0.PowerSec := ADR(MC_BR_AsmGetPowerSec_Acp6D_0.PowerSec);
or
Var file:
VAR
PowerSecRef: Mc6DPowerSecType;
END_VAR
ST code:
PowerSecRef:= MC_BR_AsmGetPowerSec_Acp6D_0.PowerSec;
MC_BR_PowerSecDeactivate_Acp6D_0.PowerSec := ADR(PowerSecRef);
The shuttle blocks must have a reference to a power sector (function block input "PowerSec"). This power sector reference is of type Mc6DPowerSecType.
A power sector reference is created for each power sector defined in the layout configuration. The power sector reference is called with MC_BR_AsmGetPowerSec_Acp6D. The address of output "PowerSec" can be used directly with other function blocks.
This power sector reference can also be stored in a process variable of type Mc6DPowerSecType and used at a later time.
ST code:
IF(MC_BR_AsmGetPowerSec_Acp6D_0.Valid == TRUE) THEN
MC_BR_PowerSecDeactivate_Acp6D_0.PowerSec := ADR(MC_BR_AsmGetPowerSec_Acp6D_0.PowerSec);
or
Var file:
VAR
PowerSecRef: Mc6DPowerSecType;
END_VAR
ST code:
PowerSecRef:= MC_BR_AsmGetPowerSec_Acp6D_0.PowerSec;
MC_BR_PowerSecDeactivate_Acp6D_0.PowerSec := ADR(PowerSecRef);