hypery2k / cordova-hotspot-plugin

A Cordova plugin for managing HotSpot networks on Android
MIT License
37 stars 49 forks source link

Scan Wi-Fi return an empty array - Cordova android 5.1.1 #33

Closed webmaster-imaginet closed 8 years ago

webmaster-imaginet commented 8 years ago

Hi,

I install the new plugin version 1.2.1 on the test app that I shared with this link: https://www.dropbox.com/s/qdtgdr0g0cg6szy/android-debug.apk?dl=0

Scan Wi-Fi return an empty array

image

hypery2k commented 8 years ago

The issue is that the function fails if wifi is turned off or if an hotspot is already active. I've add workaround for this and published a new release

webmaster-imaginet commented 8 years ago

Hi,

I install ver 1.2.2

image

I tested it again with the sample app in 3 different conditions - all of them return an empty array 1) Wi-Fi off & Hotspot off 2) Wi-Fi on & Hotspot off 3) Wi-Fi off & Hotspot on

image

hypery2k commented 8 years ago

Strange, Works for me

webmaster-imaginet commented 8 years ago

Are you using the latest cordova version 5.1.1 ?

hypery2k commented 8 years ago

yes, using 5.1.1 and just called scanWifi

webmaster-imaginet commented 8 years ago

Me too (-:

image

Can you test it with the sample app? https://www.dropbox.com/s/qdtgdr0g0cg6szy/android-debug.apk?dl=0

hypery2k commented 8 years ago

getting scan results with your test app

webmaster-imaginet commented 8 years ago

very strange. Have an idea how we get different results on the same device & android system with the same app ?

hypery2k commented 8 years ago

Not really. Can you try to complete remove the app and install it again? Then just call the scanWifi function

webmaster-imaginet commented 8 years ago

I test it again as you asked. I had to confirm twice before scan occur

image

image

Still got empty array

image

@dudeofawesome can you please test the "Scan Wi-Fi" with the sample app on your 6.x device? https://www.dropbox.com/s/qdtgdr0g0cg6szy/android-debug.apk?dl=0 then just check the chrome console to see the results.

hypery2k commented 8 years ago

With cordova 5.1.1 on Android 5 and Android 6 all is working fine: developer_tools_-_file____android_asset_www_index_html

NeoLSN commented 6 years ago

I got the same issue on Samsung phone at Android 6.0.1. Seems this issue only happens on Samsung phone. @hypery2k Do you have any idea about this?

global packages:

    cordova (Cordova CLI) : 7.1.0

local packages:

    @ionic/app-scripts : 3.0.1
    Cordova Platforms  : android 6.3.0 ios 4.5.2
    Ionic Framework    : ionic-angular 3.6.1

System:

    Android SDK Tools : 26.1.1
    ios-deploy        : 1.9.2
    ios-sim           : 6.1.2
    Node              : v9.0.0
    npm               : 5.5.1
    OS                : macOS High Sierra
    Xcode             : Xcode 9.1 Build version 9B55

Phone information image