📄 bspuicc_lnk_msgutil.h
字号:
* These macros are used to set and get the bits from the
* Parameter3 field of a Command APDU
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Parameter 1 |
| P3 |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_APDU_P3_NUM_OCTETS 1
#define BSP_UICC_LNK_MSG_UTIL_APDU_P3_OCTET_OFFSET 4
#define BSP_UICC_LNK_MSG_UTIL_APDU_P3_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_APDU_P3_BIT_WIDTH 8
#define BSP_UICC_LNK_MSG_UTIL_APDU_P3_CASE1_VALUE 0x0
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* SW1 field of a Response APDU
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Status Byte |
| SW1 |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW1_NUM_OCTETS 1
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW1_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW1_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW1_BIT_WIDTH 8
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW1_MORE_DATA_PROC_VALUE 0x61
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW1_CORRECT_LEN_PROC_VALUE 0x6C
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW1_WRONG_LEN_PROC_VALUE 0x67
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW1_MORE_DATA_GSM_PROC_VALUE 0x9F
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* SW2 field of a Response APDU
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Status Byte |
| SW2 |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW2_NUM_OCTETS 1
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW2_OCTET_OFFSET 1
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW2_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_APDU_SW2_BIT_WIDTH 8
/*===========================================================================
* Description:
* Message Utilities specific to BSP_UICC generic commands
*/
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P1 field of the Select File command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Selection Control |
| |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P1_SEL_TYPE_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P1_SEL_TYPE_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P1_SEL_TYPE_BIT_WIDTH 8
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P1_SEL_TYPE_FILE_ID_VALUE 0x0
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P1_SEL_TYPE_AID_VALUE 0x4
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P2 field of the Select File command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Return Result Data |
| |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P2_RET_TYPE_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P2_RET_TYPE_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P2_RET_TYPE_BIT_WIDTH 8
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P2_RET_TYPE_FCP_VALUE 0x4
#define BSP_UICC_LNK_MSG_UTIL_SELECT_P2_RET_TYPE_NO_FCP_VALUE 0x5
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P1 field of the Status command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Application Indication |
| |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_STATUS_P1_APP_IND_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_STATUS_P1_APP_IND_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_STATUS_P1_APP_IND_BIT_WIDTH 8
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P2 field of the Status command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Return Result Data |
| |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_STATUS_P2_RET_TYPE_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_STATUS_P2_RET_TYPE_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_STATUS_P2_RET_TYPE_BIT_WIDTH 8
#define BSP_UICC_LNK_MSG_UTIL_STATUS_P2_RET_TYPE_FCP_VALUE 0x4
#define BSP_UICC_LNK_MSG_UTIL_STATUS_P2_RET_TYPE_NO_FCP_VALUE 0x5
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P1 field of the Read Binary command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| SFI | Offset |
| Ref. | to read the first byte |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_READ_BINARY_P1_OFFSET_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_READ_BINARY_P1_OFFSET_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_READ_BINARY_P1_OFFSET_BIT_WIDTH 7
#define BSP_UICC_LNK_MSG_UTIL_READ_BINARY_P1_SFI_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_READ_BINARY_P1_SFI_BIT_OFFSET 7
#define BSP_UICC_LNK_MSG_UTIL_READ_BINARY_P1_SFI_BIT_WIDTH 1
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P1 field of the Read Record command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Record Number |
| |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P1_REC_NUM_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P1_REC_NUM_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P1_REC_NUM_BIT_WIDTH 8
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P2 field of the Read Record command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| File Id | Read Mode |
| | |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P2_READ_MODE_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P2_READ_MODE_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P2_READ_MODE_BIT_WIDTH 3
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P2_FILE_ID_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P2_FILE_ID_BIT_OFFSET 3
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P2_FILE_ID_BIT_WIDTH 5
#define BSP_UICC_LNK_MSG_UTIL_READ_RECORD_P2_CURRENT_FILE_VALUE 0x00
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P1 field of the Update Record command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Record Number |
| |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_UPDATE_RECORD_P1_REC_NUM_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_UPDATE_RECORD_P1_REC_NUM_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_UPDATE_RECORD_P1_REC_NUM_BIT_WIDTH 8
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P2 field of the Update Record command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| xxxxx | Mode |
| | |
-----------------------------------------------------------------
*/
#define BSP_UICC_LNK_MSG_UTIL_UPDATE_RECORD_P2_MODE_OCTET_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_UPDATE_RECORD_P2_MODE_BIT_OFFSET 0
#define BSP_UICC_LNK_MSG_UTIL_UPDATE_RECORD_P2_MODE_BIT_WIDTH 3
/*===========================================================================
* Description:
* These macros are used to set and get the bits from the
* P2 field of the Verify PIN command
-----------------------------------------------------------------
| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 |
-----------------------------------------------------------------
| Pin | | Ref Data |
| Qual | | |
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -