The card's txpower, sensitivity, rate and retry count can be set with iwconfig. These settings only seem to work in master (AP) mode. Further, the card often resets spontaneously, and these values are lost even in the master mode. This patch tries to solve these (and many realated) problems. problem: txpower/rate/sens/retry settings lost spontaneously solution: fixed by automatically re-setting these values after card resets Note that the default values may be different than what you are used to. Set them up with iwconfig. problem: txpower/rate/sens/retry settings not working in managed mode solution: In managed mode, these values not only got lost after resets, but also after each asssociatin/disassociation with the AP. The patch seems to correct this at least for the txpower. I don't know how to check the remaining three values. The power stays where it should when the client is asociated with an AP. I don't know how to force this when it is not associated. problem: txpower stays on automatic setting (ALC=1), even after an "iwconfig ... txpower .. fixed" solution: the driver would not set the ALC to 0 if it _thought_ it was set to 0 already. This is now fixed. "iwconfig .... txpower nnn" sets a fixed power of nnn "iwconfig .... txpower auto" sets ALC to 1 Do not adjust the txpower by writing the card's registers directly (iwpriv ... writemif 62 ... ) - the driver does not know about this and will lose the settings eventually. problem: iwconfig prints a different txpower than is actually stored in the register, read by "iwpriv ... readmif 62" solution: fixed, now these values are the same hack: The values of txpower entered and output to/by iwconfig claim to be in dBm. This is not true, they're just a very rough estimate. I disabled the conversion from/to dBm to/from the internal units. The parameters to iwconfig txpower, and the values printed as txpower by iwconfig, are now the same values you may have used already with readmif 62 / writemif 62 These are somewhat unfriendly, but at least they don't give you a false feeling of reasonable settings The meaning of these values depend on the model of your card. We have a calibration for ZCOM XI-626 and Alphawave here: http://www.czfree.net/forum/showthread.php?s=&threadid=2882 Indipendent of the actual card model, a value of 128 is always the maximum power ... increasing the value towards 255 will decrease the txpower ... then if you overflow to 0, the txpower decreases further as you approach 127. 127 is the minimum txpower. This is the default value set by this patch: !!! the default txpower is set to minimum power (127). Don't expect the connection to work well with this setting. Determine an appropriate value and set it using iwconfig .... txpower x !!! If you want the old and confusing conversion, uncomment the line #define PRISM2_DBM_CONVERSION in driver/modules/hostap_config.h
All testing and debugging I have done so far was on 1.5.6, so this is what I recommend. I don't have time nor hardware to test with different versions.
People also reported that with 1.7.4 a and 1.8.0 the txpower restore did not work. Again ... use 1.5.6 :) Update: on Jan 22 2004 I flashed my cards to 1.7.4, and the patch really doesn't work. I will try to fix it in the future.
Unpack the hostap package. Change to the directory extracted from the
archive and do:
patch -p1 <path_to_the_downloaded_patch_file
version 0.2:
- on my system, setting rate, sens or retry after resets severely decreased
stability. Your mileage may vary. Restoring txpower is the original
purpose of the patch and it seems to work well. What should and should
not be restored can be specified at the end of hostap_config.h. The
default is to restore the txpower only.
- restoring txpower after association in managed mode did not work in
0.1. It should be fixed now, rate and sens will never be restored
after association anymore, as this caused the trouble.
- fixed a minor bug in prism2_ioctl_siwtxpow
- in hostap-0.0.4, txpower control is disabled by default. The patch
enables it by #defining RAW_TXPOWER_SETTING in hostap_config.h
hostap-0.0.1-psrrr-0.2.patch
(tested)
hostap-0.0.2-psrrr-0.2.patch
(tested)
hostap-0.0.3-psrrr-0.2.patch
(tested)
hostap-0.0.4-psrrr-0.2.patch
(tested)
hostap-2003-09-24-psrr-0.2.patch (for a cvs snapshot - tested)
hostap-driver-0.1.0-psrrr-0.2.patch
(tested)
hostap-driver-0.2.0-psrrr-0.2.patch
(tested)
hostap-driver-0.3.7-psrrr-0.2.patch
(Thanks to Jakub Horky)
hostap-2.6.14.3-psrrr-0.2.patch
(against the whole kernel tree)
hostap-2.6.17.6-psrrr-0.2.patch
(against the whole kernel tree)
version 0.1:
This is the first released version.
hostap-2002-10-12-psrrr-0.1.patch
hostap-0.0.1-psrrr-0.1.patch
If you alter it for other versions of hostap, you can mail it to me and I'll post it here.
Fri Dec 17 20:32:35 CET 2004