Libtropic API
SDK for the TROPIC01 secure element
Version: master (latest)
Loading...
Searching...
No Matches
1.1. Libtropic API: Helpers

These functions are usually wrappers around one or more TROPIC01 commands, beside lt_ret_verbose() and lt_print_bytes(). More...

Macros

#define LT_CHIP_ID_FIELD_MAX_SIZE   35
 Upper bound for CHIP_ID fields as hex string (used in lt_print_chip_id()).
 

Functions

const char * lt_ret_verbose (lt_ret_t ret)
 Prints out a name of the returned value.
 
lt_ret_t lt_write_whole_R_config (lt_handle_t *h, const struct lt_config_t *config)
 Writes the whole R-Config with the passed config.
 
lt_ret_t lt_read_whole_R_config (lt_handle_t *h, struct lt_config_t *config)
 Reads all of the R-Config objects into config.
 
lt_ret_t lt_read_whole_I_config (lt_handle_t *h, struct lt_config_t *config)
 Reads all of the I-Config objects into config.
 
lt_ret_t lt_write_whole_I_config (lt_handle_t *h, const struct lt_config_t *config)
 Writes the whole I-Config with the passed config.
 
lt_ret_t lt_verify_chip_and_start_secure_session (lt_handle_t *h, const uint8_t *shipriv, const uint8_t *shipub, const lt_pkey_index_t pkey_index)
 Establishes a secure channel between host MCU and TROPIC01.
 
lt_ret_t lt_print_bytes (const uint8_t *bytes, const size_t bytes_cnt, char *out_buf, const size_t out_buf_size)
 Prints bytes in hex format to the given output buffer.
 
lt_ret_t lt_print_chip_id (const struct lt_chip_id_t *chip_id, int(*print_func)(const char *format,...))
 Interprets fields of CHIP_ID and prints them using the passed printf-like function.
 
lt_ret_t lt_print_fw_header (lt_handle_t *h, const lt_bank_id_t bank_id, int(*print_func)(const char *format,...))
 Prints interpreted firmware header of the given bank using the passed printf-like function.
 
lt_ret_t lt_do_mutable_fw_update (lt_handle_t *h, const uint8_t *update_data, const uint16_t update_data_size, const lt_bank_id_t bank_id)
 Performs mutable firmware update on ABAB and ACAB silicon revisions.
 

Variables

struct lt_config_obj_desc_t cfg_desc_table [LT_CONFIG_OBJ_CNT]
 Helper structure, holding string name and address for each configuration object.
 

Detailed Description