Pulldata for meter reading

I am developing an ODK questionnaire for collection of monthly electricity meter readings. The meter reading is continuous. How can I develop an ODK Xlsform that will be used to collect the current meter reading and calculate the amount of energy used for the month by subtracting the previous month reading from the present reading. This will be continuous for one year. This will populate the details of the meter before the new reading will be recorded.

Please see the documentation on 'Multiple encounters with the same entity (longitudinal)', specifically the section on Multiple encounters across different submissions. It has details on using data from previous encounters.

Once you have both data points, you can do math in calculations. See the docs on form operators and functions.