In C, what is the most efficient way to convert a string of hex digits into a binary unsigned int or unsigned long?
For example, if I have
#include "math.h"
#include "stdio.h"
///////////////////////////////////////////////////////////////
// The bits arg represents the bit say:8,16,32...
/////////////////////////////////////////////////////////////
volatile long Hex_To_Int(long Hex,char bits)
{
long Hex_2_Int;
char byte;
Hex_2_Int=0;
for(byte=0;byte