v2.0 added connectivity detection