FB_PowerMeasurement_TcPfw()
![FB_PowerMeasurement_TcPfw() 1:](Images/png/13247915787__Web.png)
This function block must be called in the application. It organizes internally the complete temperature control.
Syntax
VAR_INPUT
pPowerInput : POINTER TO BYTE;
pPowerOutput : POINTER TO BYTE;
stPowerCtrl : ST_TcPfw_PowerMeasurment_Ctrl;
stPowerCfg : ST_TcPfw_PowerMeasurement_Cfg;
fCycleTime : LREAL:=0.025;
END_VAR
VAR_OUTPUT
stPowerState : ST_TcPfw_xL3403_State;
END_VAR
Inputs
Name | Type | Description |
---|---|---|
pPowerInput | POINTER TO BYTE | Pointer to the input structure of the power measurement terminal. |
pPowerOutput | POINTER TO BYTE | Pointer to the output structure of the power measurement terminal. |
stPowerCtrl | ST_TcPfw_PowerMeasurment_Ctrl | Allows the current voltage to be read out separately. |
stPowerCfg | ST_TcPfw_PowerMeasurement_Cfg | Configuration of the power measurement terminal. |
fCycleTime | LREAL | Transfer of the cycle time for this function block. |
Outputs
Name | Type | Description |
---|---|---|
stPowerState | ST_TcPfw_xL3403_State | Here the current power, current and error states are reported back. |
Behavior of the function block:
This function block must be called cyclically by the application. The function block receives the mapping interface from the application as a pointer via pPowerInput and pPowerOutput. Depending on the selected power measurement terminal in stPowerCfg the pointer addresses are interpreted. Depending on the supply line, the function block distributes the measured services to the individual SupplyLines.
![]() | The pointer address and the stored terminal type must match at all times. Otherwise there will be wrong memory accesses. |
![]() | When measuring power with the EL3403, the increased filter time must also be taken into account. |