Microchip® Advanced Software Framework

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SHA204 Service - command marshaling functions

Modules

 

Functions

uint8_t sha204m_check_mac (struct sha204_check_mac_parameters *args)
 This function sends a CheckMAC command to the device and receives its response. More...
 
uint8_t sha204m_derive_key (struct sha204_derive_key_parameters *args)
 This function sends a DeriveKey command to the device and receives its response. More...
 
uint8_t sha204m_dev_rev (struct sha204_dev_rev_parameters *args)
 This function sends a DevRev command to the device and receives its response. More...
 
uint8_t sha204m_execute (struct sha204_command_parameters *args)
 This function creates a command packet, sends it, and receives its response. More...
 
uint8_t sha204m_gen_dig (struct sha204_gen_dig_parameters *args)
 This function sends a GenDig command to the device and receives its response. More...
 
uint8_t sha204m_hmac (struct sha204_hmac_parameters *args)
 This function sends an HMAC command to the device and receives its response. More...
 
uint8_t sha204m_lock (struct sha204_lock_parameters *args)
 This function sends a Lock command to the device and receives its response. More...
 
uint8_t sha204m_mac (struct sha204_mac_parameters *args)
 This function sends a MAC command to the device and receives its response. More...
 
uint8_t sha204m_nonce (struct sha204_nonce_parameters *args)
 This function sends a Nonce command to the device and receives its response. More...
 
uint8_t sha204m_pause (struct sha204_pause_parameters *args)
 This function sends a Pause command to SWI devices and receives a response from the selected device. More...
 
uint8_t sha204m_random (struct sha204_random_parameters *args)
 This function sends a Random command to the device and receives its response. More...
 
uint8_t sha204m_read (struct sha204_read_parameters *args)
 This function sends a Read command to the device and receives its response. More...
 
uint8_t sha204m_update_extra (struct sha204_update_extra_parameters *args)
 This function sends an UpdateExtra command to the device and receives its response. More...
 
uint8_t sha204m_write (struct sha204_write_parameters *args)
 This function sends a Write command to the device and receives its response. More...
 

uint8_t sha204m_dev_rev ( struct sha204_dev_rev_parameters args)

This function sends a DevRev command to the device and receives its response.

Parameters
[in,out]argspointer to parameter structure
Returns
status of the operation

References DEVREV_COUNT, DEVREV_DELAY, DEVREV_EXEC_MAX, DEVREV_PARAM1_IDX, DEVREV_PARAM2_IDX, DEVREV_RSP_SIZE, sha204_dev_rev_parameters::rx_buffer, SHA204_BAD_PARAM, SHA204_COUNT_IDX, SHA204_DEVREV, SHA204_OPCODE_IDX, sha204c_send_and_receive(), sha204_send_and_receive_parameters::tx_buffer, and sha204_dev_rev_parameters::tx_buffer.

Referenced by main().

uint8_t sha204m_execute ( struct sha204_command_parameters args)

This function creates a command packet, sends it, and receives its response.

Parameters
[in,out]argspointer to parameter structure
Returns
status of the operation

References CHECKMAC_DELAY, CHECKMAC_EXEC_MAX, CHECKMAC_RSP_SIZE, sha204_command_parameters::data_1, sha204_command_parameters::data_2, sha204_command_parameters::data_3, sha204_command_parameters::data_len_1, sha204_command_parameters::data_len_2, sha204_command_parameters::data_len_3, DERIVE_KEY_DELAY, DERIVE_KEY_EXEC_MAX, DERIVE_KEY_RSP_SIZE, DEVREV_DELAY, DEVREV_EXEC_MAX, DEVREV_RSP_SIZE, GENDIG_DELAY, GENDIG_EXEC_MAX, GENDIG_RSP_SIZE, HMAC_DELAY, HMAC_EXEC_MAX, HMAC_RSP_SIZE, LOCK_DELAY, LOCK_EXEC_MAX, LOCK_RSP_SIZE, MAC_DELAY, MAC_EXEC_MAX, MAC_RSP_SIZE, NONCE_DELAY, NONCE_EXEC_MAX, NONCE_MODE_PASSTHROUGH, NONCE_RSP_SIZE_LONG, NONCE_RSP_SIZE_SHORT, sha204_command_parameters::op_code, sha204_command_parameters::param_1, sha204_command_parameters::param_2, PAUSE_DELAY, PAUSE_EXEC_MAX, PAUSE_RSP_SIZE, sha204_send_and_receive_parameters::poll_delay, sha204_send_and_receive_parameters::poll_timeout, RANDOM_DELAY, RANDOM_EXEC_MAX, RANDOM_RSP_SIZE, READ_32_RSP_SIZE, READ_4_RSP_SIZE, READ_DELAY, READ_EXEC_MAX, sha204_command_parameters::rx_buffer, sha204_send_and_receive_parameters::rx_size, sha204_command_parameters::rx_size, SHA204_CHECKMAC, SHA204_CMD_SIZE_MIN, SHA204_COMMAND_EXEC_MAX, SHA204_CRC_SIZE, SHA204_DERIVE_KEY, SHA204_DEVREV, SHA204_GENDIG, SHA204_HMAC, SHA204_LOCK, SHA204_MAC, SHA204_NONCE, SHA204_PAUSE, SHA204_RANDOM, SHA204_READ, SHA204_SUCCESS, SHA204_UPDATE_EXTRA, SHA204_WRITE, SHA204_ZONE_COUNT_FLAG, sha204c_calculate_crc(), sha204c_send_and_receive(), sha204m_check_parameters(), sha204_send_and_receive_parameters::tx_buffer, sha204_command_parameters::tx_buffer, UPDATE_DELAY, UPDATE_EXEC_MAX, UPDATE_RSP_SIZE, WRITE_DELAY, WRITE_EXEC_MAX, and WRITE_RSP_SIZE.

uint8_t sha204m_hmac ( struct sha204_hmac_parameters args)
uint8_t sha204m_pause ( struct sha204_pause_parameters args)

This function sends a Pause command to SWI devices and receives a response from the selected device.

    All others pause.
Parameters
[in,out]argspointer to parameter structure
Returns
status of the operation

References PAUSE_COUNT, PAUSE_DELAY, PAUSE_EXEC_MAX, PAUSE_PARAM2_IDX, PAUSE_RSP_SIZE, PAUSE_SELECT_IDX, sha204_pause_parameters::rx_buffer, sha204_pause_parameters::selector, SHA204_BAD_PARAM, SHA204_COUNT_IDX, SHA204_OPCODE_IDX, SHA204_PAUSE, sha204c_send_and_receive(), sha204_send_and_receive_parameters::tx_buffer, and sha204_pause_parameters::tx_buffer.

uint8_t sha204m_random ( struct sha204_random_parameters args)