Wifi port issue (all works except the backend)

by brucelee » Sat, 19 Mar 2011 08:36:41 GMT


Sponsored Links
 hey, am having a small problem with porting wifi to a my device.

This is my config:

wifi.c (in libhardware_legacy)
    static const char IFACE_DIR[]           = "/data/misc/wifi/
wpa_supplicant";
    static const char SUPP_CONFIG_TEMPLATE[]= "/system/etc/wifi/
wpa_supplicant.conf";
    static const char SUPP_CONFIG_FILE[]    = "/data/misc/wifi/
wpa_supplicant.conf";


wpa_supplicant.conf
    update_config=1
    ctrl_interface=DIR=/data/misc/wifi/wpa_supplicant


init.rc
    mkdir /data/misc/wifi 0770 wifi wifi
    chmod 0770 /data/misc/wifi
    chmod 0660 /data/misc/wifi/wpa_supplicant.conf
    chown wifi wifi /data/misc/wifi/wpa_supplicant.conf

    mkdir /system/etc/wifi 0770 wifi wifi
    chmod 0770 /system/etc/wifi
    chmod 0660 /system/etc/wifi/wpa_supplicant.conf
    chown wifi wifi /system/etc/wifi/wpa_supplicant.conf

    # wpa_supplicant socket (unix socket mode)
    mkdir /data/misc/wifi/wpa_supplicant 0771 wifi wifi
    chmod 0771 /data/misc/wifi/wpa_supplicant
    chown wifi wifi /data/misc/wifi/wpa_supplicant

    service wpa_supplicant /system/bin/wpa_supplicant -dd -Dwext -
ieth0 -c /system/etc/wifi/wpa_supplicant.conf
    group system wifi inet
    disabled
    oneshot

Notes:

- Wifi driver/module loads properly (wifi.c, dmesg, iwconfig say so)
- Logcat reports:
    WifiHW: Unable to open connection to supplicant on "eth0": No such
file or directory (~ 4 times then unloads wifi)
- Manually loading the driver/module and
    > running wpa_supplicant (as the service above) gives not errors &
proper logcat
        although it does make this dmesg entry:
            <4>[735, wpa_supplicant] [ 1479.081526] Enter
wl_control_wl_start
            <4>[735, wpa_supplicant] [ 1479.081567] Exited
wl_control_wl_start

    > running 'wpa_cli -p /data/misc/wifi/wpa_supplicant' gives
        Selected interface 'eth0'
        Could not connect to wpa_supplicant - re-trying
    and forever remains this way

    > running 'iwlist scan' works and shows wi-fi networks

My guess would be that my permissions are wrong, but i have been
double checking with 'ls -l' and they seem ok.
The wpa_supplimentary socket 'eth0' does get created so it exists.
My guess would be that the android wifi backend runs as a specific
user other than wifi!?

-- 



Other Threads

1. What is Mediaplayer.[..] onBufferingUpdate actually telling me?

Hi all

I'm trying to play streamed mp3 from a remote source. basically it
works, but the behaviour of the bufferingupdate listener is a riddle
to me. I either get no calls at all, or updates like 1% , 2% then
nothing more. music is playing already, but the buffering never goes
to 100%.  which i think is the cause for getting "unknown mediaplayer
errors" after calling pause/stop and then start again.

so, ??? ideas ??

zero

--~--~---------~--~----~------------~-------~--~----~

2. Best way to format text on android surface?

I want to have more control over the display of text on a surface than I know 
how to do.

I want to be able to zoom in and out, scroll vertically and horizontally, and 
use different size fonts.

Would I do this with RelativeLayout or is there a better way?

Is there an example code somewhere that shows how to do some or all of this?

I expect that the profusion of devices entering the market this fall will 
increase the need to adjust layouts to multiple screen sizes.  So I would like 
to avoid fixed placement to specific screen locations.

What I am seeking here is an idea how to approach this problem in Android.

Thanks.


--~--~---------~--~----~------------~-------~--~----~

3. What is Donut?

4. How Refresh Updated Contacts in list view using Base adapter

5. Dialer

6. link to an existing app in the market

7. why binder report transaction failed