Name

number_hex2bin — Converts an hexadecimal string into a binary string.

Calling Sequence

   binstr = number_hex2binary ( hexstr )
   
   

Parameters

hexstr :

a matrix of strings

binstr :

a matrix of strings

Description

Returns the binary string corresponding to the given hexadecimal string.

Examples

hexstr = "3FE54B3504C6B4A3";
binstr = number_hex2bin (hexstr);
expected = "0011111111100101010010110011010100000100110001101011010010100011"

// Lower case also works
hexstr = "3fe54b3504c6b4a3";
binstr = number_hex2bin (hexstr);
expected = "0011111111100101010010110011010100000100110001101011010010100011"

   

Authors

Copyright (C) 2010 - DIGITEO - Michael Baudin