add support for autodetect miuiv5