global configuration function added in MainActivity