Closed
Bug 991025
Opened 11 years ago
Closed 11 years ago
Enable WiFi test on emulator
Categories
(Firefox OS Graveyard :: Wifi, defect)
Tracking
(tracking-b2g:backlog)
People
(Reporter: hchang, Assigned: hchang)
References
Details
Attachments
(5 files, 3 obsolete files)
We do need wifi API test on emulator. This is a bug for tracking necessary modification on different repos and different versions of emulator.
Assignee | ||
Comment 1•11 years ago
|
||
Assignee | ||
Comment 2•11 years ago
|
||
WIP on ICS emulator:
$ git clone https://github.com/mozilla-b2g/B2G b2g-emu-wifi
$ cd b2g-emu-wifi
$ GITREPO=git://github.com/elefant/b2g-manifest BRANCH=dev/emu-wifi ./config.sh emulator
Patch attachment 8400557 [details] [diff] [review] on hardware/libhardware_legacy/wifi/wifi.c
$ ./build.sh
$ ./mach marionette-webapi gecko/dom/wifi/test/marionette/test_wifi.js
Assignee | ||
Comment 3•11 years ago
|
||
(In reply to Henry Chang [:henry] from comment #2)
> WIP on ICS emulator:
>
> $ git clone https://github.com/mozilla-b2g/B2G b2g-emu-wifi
> $ cd b2g-emu-wifi
> $ GITREPO=git://github.com/elefant/b2g-manifest BRANCH=dev/emu-wifi
> ./config.sh emulator
>
> Patch attachment 8400557 [details] [diff] [review] on
> hardware/libhardware_legacy/wifi/wifi.c
>
> $ ./build.sh
> $ ./mach marionette-webapi gecko/dom/wifi/test/marionette/test_wifi.js
Patching wifi.c is no longer needed because of
https://github.com/elefant/device_generic_goldfish/commit/b39af9d668b0e612af85dade4b75312258b07b02
So the steps become:
$ git clone https://github.com/mozilla-b2g/B2G b2g-emu-wifi
$ cd b2g-emu-wifi
$ GITREPO=git://github.com/elefant/b2g-manifest BRANCH=dev/emu-wifi
> ./config.sh emulator
$ ./build.sh
$ ./mach marionette-webapi gecko/dom/wifi/test/marionette/test_wifi.js
Assignee | ||
Comment 4•11 years ago
|
||
The third step should be
$ GITREPO=git://github.com/elefant/b2g-manifest BRANCH=dev/emu-wifi ./config.sh emulator
Assignee | ||
Updated•11 years ago
|
Attachment #8400557 -
Attachment is obsolete: true
Assignee | ||
Comment 5•11 years ago
|
||
Gecko's patch if you are using custom gecko.
Assignee | ||
Comment 6•11 years ago
|
||
Try server result with modified test case and qemu patch.
https://tbpl.mozilla.org/?tree=Try&rev=f538b5f8cf49
Assignee | ||
Comment 7•11 years ago
|
||
Try server result with no qemu patch: https://tbpl.mozilla.org/?tree=Try&rev=3ae1de1ffc76
Updated•11 years ago
|
blocking-b2g: --- → backlog
Assignee | ||
Comment 9•11 years ago
|
||
Latest try server result:
https://tbpl.mozilla.org/?tree=Try&rev=db3cc1883852
Assignee | ||
Updated•11 years ago
|
Assignee: nobody → hchang
Assignee | ||
Comment 10•11 years ago
|
||
Attachment #8402562 -
Attachment is obsolete: true
Assignee | ||
Updated•11 years ago
|
Attachment #8407613 -
Attachment description: Add hostap to emulator.xml → b2g-manifest - Add hostap to emulator.xml
Assignee | ||
Comment 11•11 years ago
|
||
Assignee | ||
Comment 12•11 years ago
|
||
Assignee | ||
Comment 13•11 years ago
|
||
Assignee | ||
Updated•11 years ago
|
Attachment #8407613 -
Attachment description: b2g-manifest - Add hostap to emulator.xml → Part 1: b2g-manifest - Add hostap to emulator.xml
Assignee | ||
Updated•11 years ago
|
Attachment #8407615 -
Attachment description: platform_build - Modify BoradConfig.mk to build wpa_supplicant and hostapd → Part 2: platform_build - Modify BoradConfig.mk to build wpa_supplicant and hostapd
Assignee | ||
Updated•11 years ago
|
Attachment #8407617 -
Attachment description: device_generic_goldfish - Add wpa_supplicant service and related scripts → Part 3: device_generic_goldfish - Add wpa_supplicant service and related scripts
Assignee | ||
Updated•11 years ago
|
Attachment #8407618 -
Attachment description: qemu - Add network interface "wlan0" → Part 4: qemu - Add network interface "wlan0"
Assignee | ||
Comment 14•11 years ago
|
||
All the PRs for wifi test on ICS emulator:
#1: https://github.com/mozilla-b2g/b2g-manifest/pull/166:
#2: https://github.com/mozilla-b2g/platform_build/pull/46
#3: https://github.com/mozilla-b2g/device_generic_goldfish/pull/13
#4: https://github.com/mozilla-b2g/platform_external_qemu/pull/71
#1 works with #2 for ICS emulator to checkout and build "hostap", where #1 add
repo "hostap" to emulator.xml and #2 add build config to BoardConfig.mk to build
wpa_supplicant and hostapd with test driver.
#3 adds services and creates directories we need while #4 modifies qemu to add an
additional network interface "wlan0" for wifi and DHCP use.
Assignee | ||
Updated•11 years ago
|
Attachment #8407613 -
Flags: review?(vyang)
Assignee | ||
Updated•11 years ago
|
Attachment #8407615 -
Flags: review?(vyang)
Assignee | ||
Updated•11 years ago
|
Attachment #8407617 -
Flags: review?(vyang)
Assignee | ||
Updated•11 years ago
|
Attachment #8407618 -
Flags: review?(vyang)
Comment 15•11 years ago
|
||
Depends on: 871475
Updated•11 years ago
|
Attachment #8407618 -
Flags: review?(vyang) → review+
Comment 20•11 years ago
|
||
Comment on attachment 8407613 [details] [review]
Part 1: b2g-manifest - Add hostap to emulator.xml
We can reuse existing external/wpa_supplicant_8.
Attachment #8407613 -
Flags: review?(vyang)
Updated•11 years ago
|
Attachment #8407613 -
Attachment is obsolete: true
Comment 21•11 years ago
|
||
Comment on attachment 8407615 [details] [review]
Part 2: platform_build - Modify BoradConfig.mk to build wpa_supplicant and hostapd
nit: WPA_SUPPLICANT_VERSION := VER_0_8_X
Attachment #8407615 -
Flags: review?(vyang) → review+
Updated•11 years ago
|
Attachment #8407617 -
Flags: review?(vyang) → review+
Assignee | ||
Comment 22•11 years ago
|
||
How to use:
$ adb push ap1.conf /data/misc/wifi/hostapd && adb shell hostapd -B /data/misc/wifi/hostapd/ap1.conf
Comment 23•11 years ago
|
||
Try emulator all: https://tbpl.mozilla.org/?tree=Try&rev=44bb1d8b72f2
Comment 24•11 years ago
|
||
Comment 25•11 years ago
|
||
mochitest-4 again with m-c tip: https://tbpl.mozilla.org/?tree=Try&rev=db003e978d6c
Comment 26•11 years ago
|
||
(In reply to Vicamo Yang [:vicamo][:vyang] from comment #24)
> Created attachment 8409503 [details]
> crash-mochitest-chunk-4.txt
Can't replicate locally.
Assignee | ||
Comment 27•11 years ago
|
||
The log appears that all failed cases have a running wpa_supplicant....
Comment 28•11 years ago
|
||
(In reply to Vicamo Yang [:vicamo][:vyang] from comment #25)
> mochitest-4 again with m-c tip:
> https://tbpl.mozilla.org/?tree=Try&rev=db003e978d6c
Looks like it's really the known intermittent failure bug 996487. Going to land.
Comment 29•11 years ago
|
||
Comment 30•11 years ago
|
||
Comment 31•11 years ago
|
||
Hi Henry,
I suppose once this bug is landed, we could connect to the "goldfish" Wifi AP in the emulator, right?
My question is, do we still have to set the first DNS server to enable network connectivity to the Internet on the emulator?
e.g.
adb shell setprop net.dns1 10.0.2.3
or
adb shell ndc resolver setifdns eth0 10.0.0.0 10.0.2.3
Assignee | ||
Comment 32•11 years ago
|
||
(In reply to Ethan Tseng [:ethan] from comment #31)
> Hi Henry,
> I suppose once this bug is landed, we could connect to the "goldfish" Wifi
> AP in the emulator, right?
>
> My question is, do we still have to set the first DNS server to enable
> network connectivity to the Internet on the emulator?
> e.g.
> adb shell setprop net.dns1 10.0.2.3
> or
> adb shell ndc resolver setifdns eth0 10.0.0.0 10.0.2.3
If we successfully connect to a wifi AP or 3G network, the B2G network management component would set DNS for you. Therefore you don't need to do it by yourself!
Comment 33•11 years ago
|
||
(In reply to Henry Chang [:henry] from comment #32)
> If we successfully connect to a wifi AP or 3G network, the B2G network
> management component would set DNS for you. Therefore you don't need to do
> it by yourself!
That's great!
This information is helpful to update our MDN article. :)
https://developer.mozilla.org/en-US/Firefox_OS/Using_the_B2G_emulators#Network_Connectivity
Comment 34•11 years ago
|
||
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → 1.4 S6 (25apr)
Updated•11 years ago
|
Blocks: emulator_wifi
Updated•10 years ago
|
blocking-b2g: backlog → ---
tracking-b2g:
--- → backlog
You need to log in
before you can comment on or make changes to this bug.
Description
•