Thanks for your replies and pointer to the code that builds. Unfortunately, after I bring it up, it doesn't seem reliable enough to allow connections.
On Mon, Jan 18, 2010 at 07:23:09AM +0000, Hin-Tak Leung wrote: > > gandalfthegrey:/usr/src/zd1211# iwconfig ath1 mode master > > Error for wireless request "Set Mode" (8B06) : > > SET failed on device ath1 ; Invalid > > argument. > > You need to ifconfig up first. Nothing works before ifconfig up. In a nutshell, my phones see the AP. Sometimes I am able to connect to it but not get an IP. Very rarely I get an IP, and my machine usually ends up crashing some time around that. One noticeable thing is that Tx excessive retries in iwconfig shows a few hundred errors per second. Is the AP code working and stable for you? Below is the code I wrote: ---------------------------------------------------------------------------- #!/bin/bash IF=ath1 rmmod zd1211rw sleep 1 modprobe zd1211b killall -STOP NetworkManager for i in 1 2 3 4 5 do echo "bringing $IF up" ifconfig $IF up 2>/dev/null && break sleep 1 done ifconfig $IF up || bash -e "echo \"can't bring interface up\"; exit" iwconfig $IF mode master iwconfig $IF channel 3 ifconfig $IF 192.168.205.6 iwconfig $IF essid magicnet ipmasq iptables -t nat -F POSTROUTING iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE iptables -F FORWARD iptables -A FORWARD -j ACCEPT dhcpd3 -d -cf /etc/dhcp3/dhcpd.conf.hide $IF # hangs here until I stop dhcpd3 echo "cleaning up" rmmod zd1211b iptables -F FORWARD iptables -t nat -F POSTROUTING killall -CONT NetworkManager ---------------------------------------------------------------------------- Output from kernel log: Jan 20 17:57:35 gandalfthegrey kernel: _____ ____ _ ____ Jan 20 17:57:35 gandalfthegrey kernel: |__ / _| _ \ / \ / ___| Jan 20 17:57:35 gandalfthegrey kernel: / / | | | | | |/ _ \ \___ \ Jan 20 17:57:35 gandalfthegrey kernel: / /| |_| | |_| / ___ \ ___) | Jan 20 17:57:35 gandalfthegrey kernel: /____\__, |____/_/ \_\____/ Jan 20 17:57:35 gandalfthegrey kernel: |___/ Jan 20 17:57:35 gandalfthegrey kernel: ZD1211B - version 3.0.0.56 Jan 20 17:57:35 gandalfthegrey kernel: usbcore: registered new interface driver zd1211b Jan 20 17:57:40 gandalfthegrey kernel: usb 3-2: new high speed USB device using ehci_hcd and address 9 Jan 20 17:57:40 gandalfthegrey kernel: usb 3-2: New USB device found, idVendor=0ace, idProduct=1215 Jan 20 17:57:40 gandalfthegrey kernel: usb 3-2: New USB device strings: Mfr=16, Product=32, SerialNumber=0 Jan 20 17:57:40 gandalfthegrey kernel: usb 3-2: Product: USB2.0 WLAN Jan 20 17:57:40 gandalfthegrey kernel: usb 3-2: Manufacturer: ZyDAS Jan 20 17:57:40 gandalfthegrey kernel: usb 3-2: configuration #1 chosen from 1 choice Jan 20 17:57:40 gandalfthegrey kernel: vendor_id = 0ace Jan 20 17:57:40 gandalfthegrey kernel: product_id = 1215 Jan 20 17:57:40 gandalfthegrey kernel: USB 2.0 Host Jan 20 17:57:40 gandalfthegrey kernel: Release Ver = 4810 Jan 20 17:57:40 gandalfthegrey kernel: EEPORM Ver = 4810 Jan 20 17:57:40 gandalfthegrey kernel: Finsih download Firmware. Ready to reboot Jan 20 17:57:40 gandalfthegrey kernel: PA type: 0 Jan 20 17:57:40 gandalfthegrey kernel: PHYNEWLayout = 1 Jan 20 17:57:40 gandalfthegrey kernel: Airoha AL2230S_RF Jan 20 17:57:40 gandalfthegrey kernel: OverWrite CR47 = 0x1C Jan 20 17:57:40 gandalfthegrey kernel: zd1205_config: EEP(HWFeature)=0x580 Jan 20 17:57:40 gandalfthegrey kernel: AllowedChannel = 00011fff Jan 20 17:57:40 gandalfthegrey kernel: Region:48 Jan 20 17:57:40 gandalfthegrey kernel: udev: renamed network interface ath0 to ath1 Jan 20 17:57:41 gandalfthegrey kernel: zd1205_notify_disjoin_event Jan 20 17:57:41 gandalfthegrey kernel: ADDRCONF(NETDEV_UP): ath1: link is not ready Jan 20 17:57:41 gandalfthegrey kernel: Update BCN @ 15522816 Jan 20 17:57:41 gandalfthegrey kernel: Mode: AP_BSS Jan 20 17:57:41 gandalfthegrey kernel: Update BCN @ 15522988 Jan 20 18:00:42 gandalfthegrey kernel: Update BCN @ 15704337 Jan 20 18:00:44 gandalfthegrey kernel: Re_Asoc: 00:23:76:ad:b5:a0, aid=1 Jan 20 18:00:44 gandalfthegrey kernel: ADDRCONF(NETDEV_CHANGE): ath1: link becomes ready Jan 20 18:00:45 gandalfthegrey kernel: In zd_CmdDisasoc Disasoc a Connected STA Jan 20 18:00:45 gandalfthegrey kernel: Update BCN @ 15707018 Jan 20 18:00:45 gandalfthegrey kernel: Send Deasoc Req to 00:23:76:ad:b5:a0 RSN=1 Jan 20 18:00:45 gandalfthegrey kernel: STA_DISASSOCIATED:00:23:76:ad:b5:a0 Jan 20 18:00:46 gandalfthegrey kernel: Re_Asoc: 00:23:76:ad:b5:a0, aid=1 more interesting output (I get this pseudo-randomly): Jan 20 17:47:03 gandalfthegrey kernel: _____ ____ _ ____ Jan 20 17:47:03 gandalfthegrey kernel: |__ / _| _ \ / \ / ___| Jan 20 17:47:03 gandalfthegrey kernel: / / | | | | | |/ _ \ \___ \ Jan 20 17:47:03 gandalfthegrey kernel: / /| |_| | |_| / ___ \ ___) | Jan 20 17:47:03 gandalfthegrey kernel: /____\__, |____/_/ \_\____/ Jan 20 17:47:03 gandalfthegrey kernel: |___/ Jan 20 17:47:03 gandalfthegrey kernel: ZD1211B - version 3.0.0.56 Jan 20 17:47:03 gandalfthegrey kernel: vendor_id = 0ace Jan 20 17:47:03 gandalfthegrey kernel: product_id = 1215 Jan 20 17:47:03 gandalfthegrey kernel: USB 2.0 Host Jan 20 17:47:03 gandalfthegrey kernel: Release Ver = 4810 Jan 20 17:47:03 gandalfthegrey kernel: EEPORM Ver = 4810 Jan 20 17:47:03 gandalfthegrey kernel: Finsih download Firmware. Ready to reboot Jan 20 17:47:03 gandalfthegrey kernel: PA type: 0 Jan 20 17:47:03 gandalfthegrey kernel: PHYNEWLayout = 1 Jan 20 17:47:03 gandalfthegrey kernel: Airoha AL2230S_RF Jan 20 17:47:03 gandalfthegrey kernel: OverWrite CR47 = 0x1C Jan 20 17:47:03 gandalfthegrey kernel: zd1205_config: EEP(HWFeature)=0x580 Jan 20 17:47:03 gandalfthegrey kernel: AllowedChannel = 00011fff Jan 20 17:47:03 gandalfthegrey kernel: Region:48 Jan 20 17:47:03 gandalfthegrey kernel: usbcore: registered new interface driver zd1211b Jan 20 17:47:03 gandalfthegrey kernel: udev: renamed network interface ath0 to ath1 Jan 20 17:47:03 gandalfthegrey kernel: zd1205_notify_disjoin_event Jan 20 17:47:03 gandalfthegrey kernel: ADDRCONF(NETDEV_UP): ath1: link is not ready Jan 20 17:47:03 gandalfthegrey kernel: Get SIOCSIWPMKSA Jan 20 17:47:03 gandalfthegrey kernel: PMK CMD=00000003 Jan 20 17:47:03 gandalfthegrey kernel: BSSID=00 00 00 00 00 00 Jan 20 17:47:03 gandalfthegrey kernel: PMKID=00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 Jan 20 17:47:03 gandalfthegrey kernel: Get SIOCSIWAUTH Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.param.flags = 00000007 Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.param.value = 00000001 Jan 20 17:47:03 gandalfthegrey kernel: WPA=1 Jan 20 17:47:03 gandalfthegrey kernel: Get SIOCSIWENCODEEXT Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.encoding.falgs = 00008401 Jan 20 17:47:03 gandalfthegrey kernel: ext->ext_flags = 00000004 Jan 20 17:47:03 gandalfthegrey kernel: ext->addr.sa_data=ff ff ff ff ff ff Jan 20 17:47:03 gandalfthegrey kernel: ext->key_len=0 Jan 20 17:47:03 gandalfthegrey kernel: Key= Jan 20 17:47:03 gandalfthegrey kernel: ext->alg = 00000000 Jan 20 17:47:03 gandalfthegrey kernel: SET_ENCRYPT_KEY: alg=NONE key_idx=0 set_tx=33793 key_len=0 ,WPAIeLen=0, for ff:ff:ff:ff:ff:ff Jan 20 17:47:03 gandalfthegrey kernel: Get SIOCSIWENCODEEXT Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.encoding.falgs = 00008402 Jan 20 17:47:03 gandalfthegrey kernel: ext->ext_flags = 00000004 Jan 20 17:47:03 gandalfthegrey kernel: ext->addr.sa_data=ff ff ff ff ff ff Jan 20 17:47:03 gandalfthegrey kernel: ext->key_len=0 Jan 20 17:47:03 gandalfthegrey kernel: Key= Jan 20 17:47:03 gandalfthegrey kernel: ext->alg = 00000000 Jan 20 17:47:03 gandalfthegrey kernel: SET_ENCRYPT_KEY: alg=NONE key_idx=1 set_tx=33794 key_len=0 ,WPAIeLen=0, for ff:ff:ff:ff:ff:ff Jan 20 17:47:03 gandalfthegrey kernel: Get SIOCSIWENCODEEXT Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.encoding.falgs = 00008403 Jan 20 17:47:03 gandalfthegrey kernel: ext->ext_flags = 00000004 Jan 20 17:47:03 gandalfthegrey kernel: ext->addr.sa_data=ff ff ff ff ff ff Jan 20 17:47:03 gandalfthegrey kernel: ext->key_len=0 Jan 20 17:47:03 gandalfthegrey kernel: Key= Jan 20 17:47:03 gandalfthegrey kernel: ext->alg = 00000000 Jan 20 17:47:03 gandalfthegrey kernel: SET_ENCRYPT_KEY: alg=NONE key_idx=2 set_tx=33795 key_len=0 ,WPAIeLen=0, for ff:ff:ff:ff:ff:ff Jan 20 17:47:03 gandalfthegrey kernel: Get SIOCSIWENCODEEXT Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.encoding.falgs = 00008404 Jan 20 17:47:03 gandalfthegrey kernel: ext->ext_flags = 00000004 Jan 20 17:47:03 gandalfthegrey kernel: ext->addr.sa_data=ff ff ff ff ff ff Jan 20 17:47:03 gandalfthegrey kernel: ext->key_len=0 Jan 20 17:47:03 gandalfthegrey kernel: Key= Jan 20 17:47:03 gandalfthegrey kernel: ext->alg = 00000000 Jan 20 17:47:03 gandalfthegrey kernel: !? zdparm->u.crypt.idx == 0 Jan 20 17:47:03 gandalfthegrey kernel: SET_ENCRYPT_KEY: alg=NONE key_idx=0 set_tx=33796 key_len=0 ,WPAIeLen=0, for ff:ff:ff:ff:ff:ff Jan 20 17:47:03 gandalfthegrey kernel: Get SIOCSIWAUTH Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.param.flags = 00000004 Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.param.value = 00000000 Jan 20 17:47:03 gandalfthegrey kernel: Get SIOCSIWAUTH Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.param.flags = 00000005 Jan 20 17:47:03 gandalfthegrey kernel: wrq->u.param.value = 00000001 Jan 20 17:47:03 gandalfthegrey kernel: Get SIOCSIWPMKSA Jan 20 17:47:03 gandalfthegrey kernel: PMK CMD=00000003 Jan 20 17:47:03 gandalfthegrey kernel: BSSID=00 00 00 00 00 00 Jan 20 17:47:03 gandalfthegrey kernel: PMKID=00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 Jan 20 17:47:16 gandalfthegrey kernel: Change Mode wait too long Jan 20 17:47:17 gandalfthegrey kernel: Update BCN @ 14899267 Jan 20 17:47:17 gandalfthegrey kernel: Mode: AP_BSS Jan 20 17:47:17 gandalfthegrey kernel: Update BCN @ 14899307 Jan 20 17:47:17 gandalfthegrey kernel: RSSI1=199,RSSI6=139,RSSI11=141,Best Channel = 6 Jan 20 17:47:22 gandalfthegrey kernel: RSSI1=199,RSSI6=139,RSSI11=141,Best Channel = 6 Jan 20 17:47:24 gandalfthegrey kernel: RSSI1=214,RSSI6=148,RSSI11=34,Best Channel = 11 Jan 20 17:48:16 gandalfthegrey kernel: Update BCN @ 14958415 Jan 20 17:48:48 gandalfthegrey kernel: Update BCN @ 14990282 Jan 20 17:48:48 gandalfthegrey kernel: Update BCN @ 14990585 Jan 20 17:49:49 gandalfthegrey kernel: Update BCN @ 15051233 Jan 20 17:49:49 gandalfthegrey kernel: Update BCN @ 15051438 Jan 20 17:49:59 gandalfthegrey kernel: usbcore: deregistering interface driver zd1211b Jan 20 17:49:59 gandalfthegrey kernel: Wrong @ zd1211_rx_comp_cb, status=-108(15061353). Jan 20 17:49:59 gandalfthegrey kernel: Error is ffffff94 Jan 20 17:49:59 gandalfthegrey kernel: zd1211: failed rx_urb Jan 20 17:49:59 gandalfthegrey kernel: Temp Solution here. Need to look detail Jan 20 17:50:00 gandalfthegrey kernel: usb 3-2: reset high speed USB device using ehci_hcd and address 7 Jan 20 17:50:06 gandalfthegrey kernel: bridge-eth1: disabling the bridge -- "A mouse is a device used to point at the xterm you want to type in" - A.S.R. Microsoft is to operating systems & security .... .... what McDonalds is to gourmet cooking Home page: http://marc.merlins.org/ ------------------------------------------------------------------------------ Throughout its 18-year history, RSA Conference consistently attracts the world's best and brightest in the field, creating opportunities for Conference attendees to learn about information security's most important issues through interactions with peers, luminaries and emerging and established companies. http://p.sf.net/sfu/rsaconf-dev2dev _______________________________________________ Zd1211-devs mailing list - http://zd1211.wiki.sourceforge.net/ Unsubscribe: https://lists.sourceforge.net/lists/listinfo/zd1211-devs