Modified main file to reflect changes to recursive routines.
They return sum of barometer as well, this is needed to properly keep track of counter without using global variables.