Convert 2 bytes of hexadecimal to 1 byte of decimal

res=((USART2_BT_BUF[4]<<8)|USART2_BT_BUF[3])

USART2_BT_BUF[3] is the high eight bits

USART2_BT_BUF[4] is the bottom eight bits

Guess you like

Origin blog.csdn.net/qq_62392385/article/details/130515453