Connecting P1i to FreeBSD
Sepherosa Ziehau
sepherosa at gmail.com
Fri Apr 25 06:54:25 UTC 2008
On Fri, Apr 25, 2008 at 7:41 AM, Ivan Voras <ivoras at freebsd.org> wrote:
> Hi,
>
> I'd like to connect SE P1i (a "smartphone" device) to FreeBSD, in any
> possible way, via wireless (WLAN). The symptoms are that it just reports
> "Connection failed" no matter what I do.
>
> Acquired data so far:
>
> 0) I'm trying adhoc mode without any authorization, for now, just to get it
> working
> 1) The same wifi adapter (USB, D-Link DWL-G122) works ok with Windows XP
> with adhoc mode (i.e. the device connects/associates to the computer, can
> exchange network traffic, etc; in Windows I can bridge the wifi device to
> the network card, etc. - in effect, no problems)
> 2) There's no way the same devices succeeds in talking when the wifi
> adapter is on FreeBSD. The adapter is run via the rum driver.
> 2a) The "scan network" action on the device lists the WLAN SSID on the
> computer; also "ifconfig rum0 list sta" on FreeBSD shows the device's MAC.
> 3) A third machine, a laptop, can connect to the FreeBSD machine,
> everything works.
> 3a) Apparently SE P1i is quirky with its WLAN support, but somehow it knows
> how to talk to Windows.
>
> Here's a debug trace from the FreeBSD machine (wlandebug -i rum0 +debug
> +scan +assoc +node +xrate +rate +input +output +auth) during the
> unsuccessful connection attempt. The "...1d" MAC is from the P1i.
>
> rum0: received probe_req from 00:1c:a4:75:63:1d rssi 27
> rum0: [00:1c:a4:75:63:1d] recv probe req
> rum0: ieee80211_ref_node (ieee80211_send_mgmt:1574)
> 0xc250b000<00:1c:a4:75:63:1d> refcnt 3
> [00:1c:a4:75:63:1d] send probe_resp on channel 6
> rum0: received probe_req from 00:1c:a4:75:63:1d rssi 27
> rum0: [00:1c:a4:75:63:1d] recv probe req
> rum0: ieee80211_ref_node (ieee80211_send_mgmt:1574)
> 0xc250b000<00:1c:a4:75:63:1d> refcnt 3
> [00:1c:a4:75:63:1d] send probe_resp on channel 6
> rum0: received probe_req from 00:1c:a4:75:63:1d rssi 25
> rum0: [00:1c:a4:75:63:1d] recv probe req
> rum0: ieee80211_ref_node (ieee80211_send_mgmt:1574)
> 0xc250b000<00:1c:a4:75:63:1d> refcnt 3
> [00:1c:a4:75:63:1d] send probe_resp on channel 6
> rum0: received probe_req from 00:1c:a4:75:63:1d rssi 25
> rum0: [00:1c:a4:75:63:1d] recv probe req
> rum0: ieee80211_ref_node (ieee80211_send_mgmt:1574)
> 0xc250b000<00:1c:a4:75:63:1d> refcnt 3
> [00:1c:a4:75:63:1d] send probe_resp on channel 6
> rum0: received probe_req from 00:1c:a4:75:63:1d rssi 25
> rum0: [00:1c:a4:75:63:1d] recv probe req
> rum0: ieee80211_ref_node (ieee80211_send_mgmt:1574)
> 0xc250b000<00:1c:a4:75:63:1d> refcnt 3
> [00:1c:a4:75:63:1d] send probe_resp on channel 6
> rum0: received probe_req from 00:1c:a4:75:63:1d rssi 25
> rum0: [00:1c:a4:75:63:1d] recv probe req
> rum0: ieee80211_ref_node (ieee80211_send_mgmt:1574)
> 0xc250b000<00:1c:a4:75:63:1d> refcnt 3
> [00:1c:a4:75:63:1d] send probe_resp on channel 6
> rum0: received probe_req from 00:1c:a4:75:63:1d rssi 25
> rum0: [00:1c:a4:75:63:1d] recv probe req
> rum0: ieee80211_ref_node (ieee80211_send_mgmt:1574)
> 0xc250b000<00:1c:a4:75:63:1d> refcnt 3
> [00:1c:a4:75:63:1d] send probe_resp on channel 6
> rum0: received probe_req from 00:1c:a4:75:63:1d rssi 25
> rum0: [00:1c:a4:75:63:1d] recv probe req
> rum0: ieee80211_ref_node (ieee80211_send_mgmt:1574)
> 0xc250b000<00:1c:a4:75:63:1d> refcnt 3
> [00:1c:a4:75:63:1d] send probe_resp on channel 6
> rum0: [00:1c:a4:75:63:1d] probe station due to inactivity
> rum0: [00:1c:a4:75:63:1d] send null data frame on channel 6, pwr mgt dis
> rum0: [00:1c:a4:75:63:1d] probe station due to inactivity
> rum0: [00:1c:a4:75:63:1d] send null data frame on channel 6, pwr mgt dis
> rum0: [00:1c:a4:75:63:1d] station timed out due to inactivity (refcnt 1)
> rum0: [00:1c:a4:75:63:1d] station with aid 0 leaves
> rum0: node_reclaim: remove 0xc250b000<00:1c:a4:75:63:1d> from neighbor
> table, refcnt 1
> rum0: _ieee80211_free_node 0xc250b000<00:1c:a4:75:63:1d> in <gone> table
>
> The last 8 messages appear long after the device itself has stopped trying
> and declared it unconnectable.
>
> I don't know enough of wifi implementation to draw solid conclusions but
> this seems to me like the device is ignoring information given to it by the
> FreeBSD-run adapter and is retrying several times until it gives up.
>
> Here's ifconfig for rum0:
>
> rum0: flags=108843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST,NEEDSGIANT>
> metric 0 mtu 1500
> ether 00:1c:f0:9d:08:b3
> inet 10.0.0.3 netmask 0xffffff00 broadcast 10.0.0.255
> media: IEEE 802.11 Wireless Ethernet autoselect <adhoc> (autoselect
> <adhoc>)
> status: associated
> ssid C1 channel 6 (2437 Mhz 11g) bssid 9a:04:a0:16:24:54
> authmode OPEN privacy OFF txpower 50 scanvalid 60 bgscan
> bgscanintvl 300 bgscanidle 250 roam:rssi11g 7 roam:rate11g 5
> protmode CTS
>
> here's "ifconfig rum0 list sta":
>
> ADDR AID CHAN RATE RSSI IDLE TXSEQ RXSEQ CAPS FLAG
> 00:1c:f0:9d:08:b3 0 6 1M 15.5 0 0 80 I A
> 00:1c:a4:75:63:1d 0 6 1M 14.5 0 2 96 A
Are you sure that your device works under IBSS mode?
BTW, it looks like you have third machine that is equipped with
wireless device, so would you please grab a 802_11 tap when your
device tries to connect to rum on your freebsd box:
tcpdump -ni your_third_wlan_iface -y ieee802_11 -w dump.bin
Best Regards,
sephe
--
Live Free or Die
More information about the freebsd-net
mailing list