measure mobile device orientation and resolution