
native rM2M_GetPacked(const data{}, pos, &{Float,Fixed,_}:value, size=4, bool:bigendian=false);
Supplies the value that is located at the specified position in an array
Important note:
Although this function will still be supported for the purpose of downward
compatibility, it should no longer be used for new projects as the unsigned data types might lead
to problems. The „rM2M_Pack()" function should be used as an alternative.
Parameter
Explanation
data
Array that should be used as a data area for a data record or a configuration
pos
Byte offset within the array to determine the position from which the data should
be read
value
Variable to store the data to be read
size
Number of bytes that should be read
bigendian
Specifies how the packed data must be interpreted:
true: The data is saved in "Big endian" format in the array.
false: The data is saved in "Little endian" format in the array.
Explanation
Return value
l
OK, if successful
l
< OK, if an error occurs (see "Return codes for general purposes" in
chapter "Constants" on page 118)
Note:
Additional explanation on the byte sequence:
In the following example, the whole number 439.041.101 is saved as a 32-bit integer value from memory
address 10000.
Big endian
Little endian
Addresses
Hex
Dez
Binary
Hex
Dez
Binary
10000
1A
26
00011010
4D
77
01001101
10001
2B
43
00101011
3C
60
00111100
10002
3C
60
00111100
2B
43
00101011
10003
4D
77
01001101
1A
26
00011010
144
Rev. 05
Summary of Contents for myDatalogEASY V3
Page 2: ......
Page 13: ...Chapter 2 Declaration of conformity Chapter 2 Declaration of conformity Rev 05 13 ...
Page 14: ......
Page 42: ......
Page 76: ......
Page 88: ......
Page 102: ......
Page 110: ......
Page 116: ......
Page 234: ......
Page 244: ......
Page 252: ......
Page 254: ......
Page 266: ......
Page 276: ......