How would you do it manually?
Take the digit characters one at a time from the left and get their hex value and use those hex values to build the int value.
First problem is converting a digit...