Run SPARK_WLAN_Setup() after class constructors i.e. inside main()