F_BA_ByteVal

The return value of the F_BA_ByteVal function is created by the structure of type U_BA_ClassValue. The input values nByte1, nByte2, nByte3 and nByte4 are assigned in this structure on the respective values nByteVal[1], nByteVal[2], nByteVal[3] and nByteVal[4]. Due to the data type UNION, whose elements all start from the same memory address, all other values of this structure change as well.
Syntax
FUNCTION F_BA_ByteVal : U_BA_ClassValue
VAR_INPUT
  nByte1    : BYTE;
  nByte2    : BYTE;
  nByte3    : BYTE;
  nByte4    : BYTE;
END_VAR Inputs
 Inputs
| Name | Type | Description | 
|---|---|---|
| nByte1 | BYTE | This value is assigned _nByteVal[1]_to the output structure. | 
| nByte2 | BYTE | This value is assigned _nByteVal[2]_to the output structure. | 
| nByte3 | BYTE | This value is assigned _nByteVal[3]_to the output structure. | 
| nByte4 | BYTE | This value is assigned _nByteVal[4]_to the output structure. | 
Requirements
| Development environment | Required PLC library | 
|---|---|
| TwinCAT 3.1 4024.35 | Tc3_BA2_Common from V2.1.20.0 |