SMDFSizeOfFieldData

Returns the size information in data size format 2 for a given data size.

Syntax

  #include <smsutapi.h> 
   
  int SMDFSizeOfFieldData ( 
     UINT64  dataSize, 
     UINT8   dataSizeMap);
  

Parameters

dataSize

(IN) Specifies the size of the data size descriptor.

dataSizeMap

(OUT) Specifies a size format 2 descriptor that indicates the number of size bytes that should follow the descriptor.

Return Values

The following table lists the return values associated with the function.

0x0

Invalid data size value. The data’s size is between 0 and 127 bytes (size format 1 should be used).

0x1

The data size value will occupy one byte.

0x2

The data size value will occupy 2 bytes.

0x4

The data size value will occupy 4 bytes.

0x8

The data size value will occupy 8 bytes.

Remarks

For data size values that fall within the range of Size Format 2, SMDFSizeOfFieldData returns a size descriptor and indicates the number of bytes the data size value will occupy. These values are used to fill in the data size values of an SIDF field.

dataSizeMap returns one of the following values: