Microchip® Advanced Software Framework

bm_utils.h File Reference

BM utility declarations.

Copyright (c) 2018 Microchip Technology Inc. and its subsidiaries.

#include "stdint.h"

Functions

uint8_t calc_chksum_8bit (uint8_t *data, uint16_t length)
 
void format_hex (uint8_t *str, uint16_t val)
 
void format_hex_24bit (uint8_t *str, uint32_t val)
 
void format_hex_bdaddrs (uint8_t *str, uint64_t val)
 
void format_hex_bdaddrs2 (uint8_t *str, uint8_t *val)
 
void format_hex_byte (uint8_t *str, uint8_t val)
 
void format_hex_byte2 (uint8_t *str, uint8_t val)
 
void format_hex_dword (uint8_t *str, uint32_t val)
 
void format_hex_long (uint8_t *str, uint64_t val)
 
uint8_t get_hex (uint8_t *str, uint16_t *val)
 
uint8_t get_hex_24bit (uint8_t *str, uint32_t *val)
 
uint8_t get_hex_bdaddrs (uint8_t *str, uint64_t *val)
 
uint8_t get_hex_byte (uint8_t *str, uint8_t *val)
 
uint8_t get_hex_dword (uint8_t *str, uint32_t *val)
 
uint8_t get_hex_long (uint8_t *str, uint64_t *val)
 
void memcpy_ascii_order (uint8_t *a, uint8_t *b, int len)
 
void memcpy_ascii_reorder (uint8_t *a, uint8_t *b, int len)
 
uint8_t * memcpy_inplace_reorder (uint8_t *data, uint16_t len)
 
uint8_t * memcpy_nibble_inplace_reorder (uint8_t *data, uint16_t len)
 
void memcpy_nibble_reorder (uint8_t *a, uint8_t *b, int len)
 
void memcpy_reorder (uint8_t *a, uint8_t *b, int len)
 
uint8_t set_to_upper (uint8_t lower)
 

uint8_t calc_chksum_8bit ( uint8_t *  data,
uint16_t  length 
)

References data, i, and length.

Referenced by BM_APPLICATION_CmdPkt(), and BM_APPLICATION_Response().

void format_hex ( uint8_t *  str,
uint16_t  val 
)
void format_hex_24bit ( uint8_t *  str,
uint32_t  val 
)
void format_hex_bdaddrs ( uint8_t *  str,
uint64_t  val 
)
void format_hex_bdaddrs2 ( uint8_t *  str,
uint8_t *  val 
)
void format_hex_byte ( uint8_t *  str,
uint8_t  val 
)
void format_hex_byte2 ( uint8_t *  str,
uint8_t  val 
)
void format_hex_dword ( uint8_t *  str,
uint32_t  val 
)
void format_hex_long ( uint8_t *  str,
uint64_t  val 
)
uint8_t get_hex ( uint8_t *  str,
uint16_t *  val 
)

References get_hex_byte().

uint8_t get_hex_24bit ( uint8_t *  str,
uint32_t *  val 
)

References get_hex_byte().

uint8_t get_hex_bdaddrs ( uint8_t *  str,
uint64_t *  val 
)

References get_hex_byte().

uint8_t get_hex_byte ( uint8_t *  str,
uint8_t *  val 
)
uint8_t get_hex_dword ( uint8_t *  str,
uint32_t *  val 
)

References get_hex_byte().

uint8_t get_hex_long ( uint8_t *  str,
uint64_t *  val 
)

References get_hex_byte().

void memcpy_ascii_order ( uint8_t *  a,
uint8_t *  b,
int  len 
)

References format_hex_byte(), and i.

void memcpy_ascii_reorder ( uint8_t *  a,
uint8_t *  b,
int  len 
)

References format_hex_byte(), and i.

uint8_t* memcpy_nibble_inplace_reorder ( uint8_t *  data,
uint16_t  len 
)

References data.

void memcpy_nibble_reorder ( uint8_t *  a,
uint8_t *  b,
int  len 
)

References i.

uint8_t set_to_upper ( uint8_t  lower)

Referenced by get_hex_byte().