Sunday, April 22, 2018

Dev Tips#23 Convert twos complement to decimal value Algorithm and Code ...

Converting a 16 bit twos complements value to decimal value : algorithm and implementation

Converting a 16 bits twos complement value to a decimal value equivalent. In this tutorial a simple algorithm and implementation are shared.

Main sub

Get the sign sub

Converting to decimal value sub

This is just a trick, hope it paved your way out.