PASAHO Short Info Command Macros
[PA/SA/Host Macros]

PASAHO Short Info Command Macros

Macros used by the PASAHO Short Info Command



#define PASAHO_SINFO_READ_CMDID(x)   PASAHO_READ_BITFIELD((x)->word0,29,3)
#define PASAHO_SINFO_RESD_PAYLOAD_OFFSET(x)   PASAHO_READ_BITFIELD((x)->word0,16,8)
#define PASAHO_SINFO_READ_PAYLOAD_LENGTH(x)   PASAHO_READ_BITFIELD((x)->word0,0,16)
#define PASAHO_SINFO_SET_PAYLOAD_OFFSET(x, v)   PASAHO_SET_BITFIELD((x)->word0, (v), 16, 8)
#define PASAHO_SINFO_SET_PAYLOAD_LENGTH(x, v)   PASAHO_SET_BITFIELD((x)->word0, (v), 0, 16)
#define PASAHO_SINFO_FORMAT_CMD(offset, len)   (((offset) << 16) | (len) | (PASAHO_SA_SHORT_INFO << 29))

Define Documentation

#define PASAHO_SINFO_FORMAT_CMD ( offset,
len   )     (((offset) << 16) | (len) | (PASAHO_SA_SHORT_INFO << 29))

Format the entire short info command

#define PASAHO_SINFO_READ_CMDID (  )     PASAHO_READ_BITFIELD((x)->word0,29,3)

Extract the command ID defined at PA/SA/Host Commands

#define PASAHO_SINFO_READ_PAYLOAD_LENGTH (  )     PASAHO_READ_BITFIELD((x)->word0,0,16)

Extract the byte length of the payload

#define PASAHO_SINFO_RESD_PAYLOAD_OFFSET (  )     PASAHO_READ_BITFIELD((x)->word0,16,8)

Extract the offset to the packet payload

#define PASAHO_SINFO_SET_PAYLOAD_LENGTH ( x,
 )     PASAHO_SET_BITFIELD((x)->word0, (v), 0, 16)

Set the payload length

#define PASAHO_SINFO_SET_PAYLOAD_OFFSET ( x,
 )     PASAHO_SET_BITFIELD((x)->word0, (v), 16, 8)

Set the offset to the payload


Copyright 2012, Texas Instruments Incorporated