title: Measure input voltage of Raspberry Pi B+ running Ubuntu
body: <p>I just learned that <a href="https://raspberrypi.stackexchange.com/a/24674/31439">a red flashing LED indicates voltage below 4.63V</a> on a <a href="https://www.raspberrypi.org/products/model-b-plus/" rel="nofollow noreferrer">Raspberry Pi Model B+</a>.</p>
  
  <p>Is there a command to determine the voltage programmatically?</p>
  
  <p>I tried <code>vcgencmd measure_volts</code>. But it yields 1.2000V, independent of the input source and the LED status. And it doesn't seem to be related to the 4.63V mentioned above.</p>
  
  <h3>Update</h3>
  
  <p>Let me describe the situation in a bit more detail:</p>
  
  <p>I'm powering the Raspberry Pi with a lead-acid battery built into a moving robot. After operating the robot for a while, the voltage seams to drop below a critical minimum, causing potential damage to the file system. Therefore, I'd like to detect low voltage automatically (and trigger the robot to return to the charging station).</p>
  
  <p>I'm asking here in StackOverflow, since I assume the solution not to be robotic-specific, but generally applicable to other machines.</p>