{*------------------------------------------------
十六进制转换成十进制函数
@param
@return
-------------------------------------------------}
function HexToInt(str:string; var Value: integer): word;
var
I, L: Integer;
begin
L := length(str);
for I := 1 to L do
begin
case str[i] of
'f', 'F':
Value := 15;
'e', 'E':
Value := 14;
'd', 'D':
Value := 13;
'c', 'C':
Value := 12;
'b', 'B':
Value := 11;
'a', 'A':
Value := 10;
'0'..'9':
Value := Ord(Str[I]) - Ord('0');
end;
end;
end;