In Examples/User Interface/Calculator.py the button_tapped() function gets the values of label1 and label2.

For your code, you will need to use int(sender.superview['label1']) to get an integer.