Could you post the code to see what else there might be? Also, have you tried printing out the value from the distance.getAverageVoltage() method to make sure the hardware is working properly?
something like:
Code:
System.out.println(distance.getAverageVoltage());
It should print out the value in the IDE, or you could use NetConsole to read the values.