Android Question WiFi Mac address?

Discussion in 'Android Questions' started by techknight, Apr 1, 2015.

  1. techknight

    techknight Well-Known Member Licensed User

    How do I obtain the mac address to the WiFi radio?

    I know there is a library ABWifi, but according to the author, just about all functions were dropped in 2.0 and he claims there are "better" libraries out there.

    But I am not seeing any? any ideas?
  2. walterf25

    walterf25 Well-Known Member Licensed User

    You can do it like this:
    Log("Mac Address: " & Get_Mac)

    Sub Get_Mac As String
    Dim R As Reflector
    R.Target = R.GetContext
    R.Target = R.RunMethod2(
    R.Target = R.RunMethod(
    Return R.RunMethod("getMacAddress")
    End Sub
    Hope this helps.
    KZero, Peter Simpson and DonManfred like this.
  3. techknight

    techknight Well-Known Member Licensed User

    Thats better. Hopefully this doenst throw up the precision location permission flag. ABWifi does and that can scare some people off...
  4. Peter Simpson

    Peter Simpson Expert Licensed User

    DonManfred likes this.
  5. FrankBerra

    FrankBerra Active Member Licensed User

    Actually I am using ABWifi to perform scans periodically (every 10 minutes) but seems it is draining too much battery.
    So i want to try different approaches: How to obtain the list of MAC/BSSID of the accespoints nearby with getScanResults () ?

    Thanks in advance
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice