title: Parsing string containing ascii codes to float
body: <p>I'm using <a href="http://pyvisa.sourceforge.net/" rel="nofollow">pyvisa</a> to control a Signal recovery sr7225 lockin amplifier. Almost everything works as expected. There is only one problem, when the queried value is exactly zero and one queries in the floating point mode the following is returned</p>
  
  <pre><code>&gt;&gt;&gt;import visa
  &gt;&gt;&gt;lockin = visa.instrument('GPIB::08')
  &gt;&gt;&gt;lockin.ask('X.') # Query X value in floating point mode
  0.0E+00\x00
  </code></pre>
  
  <p>An ascii value is appended to the response string. I guess the appended ascii value of <code>\x00</code> is a bug, but it means that I cannot use <code>float()</code> to convert the string response to float. How would you handle this?</p>