Fix for compatibility with 2.x devices

Implemented general fixes to maintain compatibility with android 2.x devices