title: Matlab to Python; Converting a hex-address to a decimal numpy array
body: <p>Its probably done in a few lines but im currently stuck on the following problem:</p>
  
  <p>I want to transfer a matlab operation to python. Matlab looks like this:</p>
  
  <pre><code>startAddress = hex2dec('00D00000');
  address = hex2dec(flipud((reshape(dec2hex(address, 8), 2, 4))'));
  </code></pre>
  
  <p>So i get a 2D-vector with decimal numbers out of this. The closest i got to transfer this to python is the following:</p>
  
  <pre><code>import numpy as np
  
  startAddress = int('00D00000', 16)
  address = startAddress.to_bytes(8, 'little')
  address = np.frombuffer(addressMsg, dtype=np.uint8)
  address = address[0:4].reshape(4,1)
  </code></pre>
  
  <p>Is this equivalent? The rest of my code doesnt work properly and its quite complex so i wanted to figure out if my mistake is here or somewhere deeper.</p>