Measure voltage of battery in NXT brick
This block measures the voltage of the battery located in the NXT brick, and outputs the value in millivolts. For example, when the six 1.5 volt batteries are fully charged, the output value is approximately 9000.
If you run a simulation of a model that contains this block without the target hardware, this block outputs zeroes. See Block Produces Zeros or Does Nothing in Simulation.
Measure the voltage of the batteries in the NXT brick.
Open the legonxtlib block library and copy the blocks shown to a new model.
Connect the Battery block to the LCD block, as shown.
Prepare and run the model on the NXT brick.
Observe the battery voltage, shown in millivolts, on the LCD display.
Detect and Fix Task Overruns on NXT Brick | Install Support for LEGO MINDSTORMS NXT Hardware | LEGO MINDSTORMS NXT Battery | LEGO MINDSTORMS NXT Button | LEGO MINDSTORMS NXT LCD | LEGO MINDSTORMS NXT Speaker | LEGO MINDSTORMS NXT Timer