New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ignored txpower offset on Ubiquiti NanoStation M2 #94

Open
T-X opened this Issue Apr 12, 2014 · 16 comments

Comments

Projects
None yet
9 participants
@T-X
Contributor

T-X commented Apr 12, 2014

It seems that the 12 dBi antenna of the Ubiquiti NanoStation M2 is properly set in the firmware, at least a 12dB txpower offset is noted in iwinfo. However, the txpower is not reduced accordingly:

$ iwinfo
wlan0     ESSID: "luebeck.freifunk.net"
          Access Point: 24:A4:3C:AC:F4:AC
          Mode: Master  Channel: 1 (2.412 GHz)
          Tx-Power: 30 dBm  Link Quality: 40/70
          Signal: -70 dBm  Noise: -89 dBm
          Bit Rate: 43.6 MBit/s
          Encryption: none
          Type: nl80211  HW Mode(s): 802.11bgn
          Hardware: 168C:002A 0777:E012 [Ubiquiti NanoStation M2]
          TX power offset: 12 dB
          Frequency offset: none
          Supports VAPs: yes

wlan0-1   ESSID: "02:d1:11:37:fc:38"
          Access Point: 02:D1:11:37:FC:38
          Mode: Ad-Hoc  Channel: 1 (2.412 GHz)
          Tx-Power: 30 dBm  Link Quality: 69/70
          Signal: -41 dBm  Noise: -89 dBm
          Bit Rate: 102.3 MBit/s
          Encryption: unknown
          Type: nl80211  HW Mode(s): 802.11bgn
          Hardware: 168C:002A 0777:E012 [Ubiquiti NanoStation M2]
          TX power offset: 12 dB
          Frequency offset: none
          Supports VAPs: yes

The "Tx-Power" field seems to include the tx power offset (https://dev.openwrt.org/browser/branches/attitude_adjustment/package/iwinfo/src/iwinfo_cli.c?rev=36121#L433). However it should say "Tx-Power: 20 dBm".

The reg domain is set correctly, too:

$ iw reg get
country DE:
        (2400 - 2483 @ 40), (N/A, 20)
        (5150 - 5250 @ 80), (N/A, 20), NO-OUTDOOR
        (5250 - 5350 @ 80), (N/A, 20), NO-OUTDOOR, DFS
        (5470 - 5725 @ 80), (N/A, 27), DFS
        (57240 - 65880 @ 2160), (N/A, 40), NO-OUTDOOR
$ iwinfo wlan0-1 txpowerlist
  12 dBm (  15 mW)
  13 dBm (  19 mW)
  14 dBm (  25 mW)
  15 dBm (  31 mW)
  16 dBm (  39 mW)
  17 dBm (  50 mW)
  18 dBm (  63 mW)
  19 dBm (  79 mW)
  20 dBm ( 100 mW)
  21 dBm ( 125 mW)
  22 dBm ( 158 mW)
  23 dBm ( 199 mW)
  24 dBm ( 251 mW)
  25 dBm ( 316 mW)
  26 dBm ( 398 mW)
  27 dBm ( 501 mW)
  28 dBm ( 630 mW)
  29 dBm ( 794 mW)
* 30 dBm (1000 mW)

@T-X T-X added the bug label Apr 12, 2014

@ohrensessel

This comment has been minimized.

Show comment
Hide comment
@ohrensessel

ohrensessel Jun 8, 2014

Contributor

Is there a fix for this bug on the horizon? Or is this an openwrt issue?

Contributor

ohrensessel commented Jun 8, 2014

Is there a fix for this bug on the horizon? Or is this an openwrt issue?

@tcatm

This comment has been minimized.

Show comment
Hide comment
@tcatm

tcatm Jun 9, 2014

All OpenWRT builds for Ubiquiti devices are affected so it would be best to fix it upstream.

tcatm commented Jun 9, 2014

All OpenWRT builds for Ubiquiti devices are affected so it would be best to fix it upstream.

@ohrensessel

This comment has been minimized.

Show comment
Hide comment
@ohrensessel

ohrensessel Jun 9, 2014

Contributor

is there an openwrt bug report already or should we create one?

Contributor

ohrensessel commented Jun 9, 2014

is there an openwrt bug report already or should we create one?

@T-X

This comment has been minimized.

Show comment
Hide comment
@T-X

T-X Jun 9, 2014

Contributor

Sorry, had forgotten to forward it to OpenWRT, here it is now: https://dev.openwrt.org/ticket/16744

Contributor

T-X commented Jun 9, 2014

Sorry, had forgotten to forward it to OpenWRT, here it is now: https://dev.openwrt.org/ticket/16744

@corny

This comment has been minimized.

Show comment
Hide comment
@corny

corny Jun 19, 2014

Contributor

This problem does also appear on my Ubiquiti PicoStation M2. Probably more Ubiquiti devices are affected.

Contributor

corny commented Jun 19, 2014

This problem does also appear on my Ubiquiti PicoStation M2. Probably more Ubiquiti devices are affected.

@NeoRaider NeoRaider added this to the 2014.3 milestone Jul 2, 2014

@tcatm tcatm added the upstream label Jul 11, 2014

@NeoRaider NeoRaider modified the milestones: 2014.3, 2014.4 Jul 29, 2014

@NeoRaider NeoRaider modified the milestones: 2015.1, 2014.4 Dec 14, 2014

@tcatm

This comment has been minimized.

Show comment
Hide comment
@tcatm

tcatm Feb 16, 2015

Upstream has changed the issue to "wontfix" a few days ago. Any suggestions on what do to next?

tcatm commented Feb 16, 2015

Upstream has changed the issue to "wontfix" a few days ago. Any suggestions on what do to next?

@ohrensessel

This comment has been minimized.

Show comment
Hide comment
@ohrensessel

ohrensessel Feb 19, 2015

Contributor

bekommen wir das nicht gelöst, in dem wir $irgendwie für die betroffenen geräte die sendeleistung manuell festlegen, ohne uns auf upstream zu verlassen?

ähnlich zu https://github.com/freifunk-gluon/gluon/wiki/Commandline-administration#sendeleistung-auf-nanostation-m2

Contributor

ohrensessel commented Feb 19, 2015

bekommen wir das nicht gelöst, in dem wir $irgendwie für die betroffenen geräte die sendeleistung manuell festlegen, ohne uns auf upstream zu verlassen?

ähnlich zu https://github.com/freifunk-gluon/gluon/wiki/Commandline-administration#sendeleistung-auf-nanostation-m2

@tcatm

This comment has been minimized.

Show comment
Hide comment
@tcatm

tcatm Feb 19, 2015

Wenn wir das tun, können wir den Patch auch gleich Upstream einreichen. Im Endeffekt läuft es ja wirklich nur auf eine Liste mit den Verstärkungsfaktoren der Geräte hinaus.

tcatm commented Feb 19, 2015

Wenn wir das tun, können wir den Patch auch gleich Upstream einreichen. Im Endeffekt läuft es ja wirklich nur auf eine Liste mit den Verstärkungsfaktoren der Geräte hinaus.

@NeoRaider

This comment has been minimized.

Show comment
Hide comment
@NeoRaider

NeoRaider Feb 19, 2015

Member

Such a list does exist in libiwinfo (although entries for many Ubiquiti devices are missing at the moment).

We'd just need to think of a nice way to use this list for the default settings.

Member

NeoRaider commented Feb 19, 2015

Such a list does exist in libiwinfo (although entries for many Ubiquiti devices are missing at the moment).

We'd just need to think of a nice way to use this list for the default settings.

@NeoRaider

This comment has been minimized.

Show comment
Hide comment
@NeoRaider

NeoRaider May 4, 2015

Member

I've added some updated offsets for the NanoStation M2, M5 and Loco M2. The txpower offsets should be included in the values in the new wifi-config LuCI module, so hopefully those values are accurate now. In particular, the NanoStation M5 value was updated from 5 to 16 dBi.

Please test if the new values make any sense; if they do, we might start to think about ways to base the default txpower setting on them.

Member

NeoRaider commented May 4, 2015

I've added some updated offsets for the NanoStation M2, M5 and Loco M2. The txpower offsets should be included in the values in the new wifi-config LuCI module, so hopefully those values are accurate now. In particular, the NanoStation M5 value was updated from 5 to 16 dBi.

Please test if the new values make any sense; if they do, we might start to think about ways to base the default txpower setting on them.

@NeoRaider

This comment has been minimized.

Show comment
Hide comment
@NeoRaider

NeoRaider Mar 2, 2016

Member

Okay, I've found a way to set the correct txpower offsets by default. Still, we need to find out what the correct offsets are.

The current data file can be found at: http://git.openwrt.org/?p=project/iwinfo.git;a=blob;f=hardware.txt;h=4cac0a1258e266e6d2f5de0f601274f3cd11e31a;hb=HEAD

As you can see, only a few devices of the Airmax series have txpower offsets defined. The hardware IDs (the first 4 columns) can be found out using the iwinfo command.

We will need the correct offsets for the following devices:

  • NanoStation
  • NanoStation Loco
  • PicoStation
  • M2/M5, XM/XW for all of these if they exist
  • Other variants like Ti?

The bullet and the rocket are a bit special as they don't come with an antenna, but getting the offsets between AirOS and OpenWrt with the same antenna would be interesting here too.

We are not sure if the offsets are just antenna gain, or if there is an additional offset. The most effective way to determine this offset is setting the device to maximum power on OpenWrt while measuring the received signal on another device, and then repeating this from AirOS, setting the same power that iwinfo reported on OpenWrt. The difference between the measured signal levels is the offset.

To get the best results, the test setup should be as reproducible as possible, but it is also advisable to repeat this test with different setups and at different times.

Member

NeoRaider commented Mar 2, 2016

Okay, I've found a way to set the correct txpower offsets by default. Still, we need to find out what the correct offsets are.

The current data file can be found at: http://git.openwrt.org/?p=project/iwinfo.git;a=blob;f=hardware.txt;h=4cac0a1258e266e6d2f5de0f601274f3cd11e31a;hb=HEAD

As you can see, only a few devices of the Airmax series have txpower offsets defined. The hardware IDs (the first 4 columns) can be found out using the iwinfo command.

We will need the correct offsets for the following devices:

  • NanoStation
  • NanoStation Loco
  • PicoStation
  • M2/M5, XM/XW for all of these if they exist
  • Other variants like Ti?

The bullet and the rocket are a bit special as they don't come with an antenna, but getting the offsets between AirOS and OpenWrt with the same antenna would be interesting here too.

We are not sure if the offsets are just antenna gain, or if there is an additional offset. The most effective way to determine this offset is setting the device to maximum power on OpenWrt while measuring the received signal on another device, and then repeating this from AirOS, setting the same power that iwinfo reported on OpenWrt. The difference between the measured signal levels is the offset.

To get the best results, the test setup should be as reproducible as possible, but it is also advisable to repeat this test with different setups and at different times.

@rotanid

This comment has been minimized.

Show comment
Hide comment
@rotanid

rotanid Mar 14, 2016

Member

hierzu gekürztes Zitat aus dem IRC-Channel vom 4. März:

01:25 < rotanid> also eine NSM2 mit firmware 5.6.3 zeigt im webinterface bei germany an 9dbm max. leistung, 11dbi antenne. aus einer messposition hat das smartphone -20dbm angezeigt
01:25 < rotanid> mit gluon 2016.1.1 zeigt das smartphone an der selben Position -8dBm an
01:27 < rotanid> iwinfo sagt: Tx-Power: 29 dBm, TX power offset: 11 dB
[...]
01:29 @NeoRaider Was sagt denn iwinfo txpowerlist als unterstützte Werte? Und welche Regdom hast du eingestellt?
01:29 < rotanid> 11 bis 29 werden aufgelistet, regdom DE ist eingestellt
01:32 @NeoRaider Okay, dann sind die da schon drin, und die 11 bis 29 entsprechen 0 bis 18 als tatsächliche Einstellung der WLAN-Karte, vermute ich
[...]
01:34 @NeoRaider Ok, dann kommt das Offest von 12, was OpenWrt da hat, ja sogar besser hin als die 11, die wir in Gluon benutzen. Aber zumindest liegen beide Werte nicht völlig daneben
01:36 @NeoRaider Vielleicht.
01:36 @NeoRaider Andererseits würden die 11 der Antenne entsprechen.

Member

rotanid commented Mar 14, 2016

hierzu gekürztes Zitat aus dem IRC-Channel vom 4. März:

01:25 < rotanid> also eine NSM2 mit firmware 5.6.3 zeigt im webinterface bei germany an 9dbm max. leistung, 11dbi antenne. aus einer messposition hat das smartphone -20dbm angezeigt
01:25 < rotanid> mit gluon 2016.1.1 zeigt das smartphone an der selben Position -8dBm an
01:27 < rotanid> iwinfo sagt: Tx-Power: 29 dBm, TX power offset: 11 dB
[...]
01:29 @NeoRaider Was sagt denn iwinfo txpowerlist als unterstützte Werte? Und welche Regdom hast du eingestellt?
01:29 < rotanid> 11 bis 29 werden aufgelistet, regdom DE ist eingestellt
01:32 @NeoRaider Okay, dann sind die da schon drin, und die 11 bis 29 entsprechen 0 bis 18 als tatsächliche Einstellung der WLAN-Karte, vermute ich
[...]
01:34 @NeoRaider Ok, dann kommt das Offest von 12, was OpenWrt da hat, ja sogar besser hin als die 11, die wir in Gluon benutzen. Aber zumindest liegen beide Werte nicht völlig daneben
01:36 @NeoRaider Vielleicht.
01:36 @NeoRaider Andererseits würden die 11 der Antenne entsprechen.

@yanosz

This comment has been minimized.

Show comment
Hide comment
@yanosz

yanosz Mar 22, 2016

I do have access to some hardware at our hackerspace, but no idea how to measure the correct(!) offset - can I help somehow?

I'm somewhat missing details on that issue - all is very confusing.

And there are some bugs:

Are you aware of any errata page, here? What is your proposal for operating Ubnt-HW using OpenWRT.

Thanks,
yanosz

yanosz commented Mar 22, 2016

I do have access to some hardware at our hackerspace, but no idea how to measure the correct(!) offset - can I help somehow?

I'm somewhat missing details on that issue - all is very confusing.

And there are some bugs:

Are you aware of any errata page, here? What is your proposal for operating Ubnt-HW using OpenWRT.

Thanks,
yanosz

@rotanid

This comment has been minimized.

Show comment
Hide comment
@rotanid

rotanid Apr 4, 2016

Member

da wurde auch schon ein wenig dokumentiert zu dem Thema, fand ich gerade:
https://www.freifunk-gera-greiz.de/wiki/-/wiki/Allgemein/Sendeleistung

Member

rotanid commented Apr 4, 2016

da wurde auch schon ein wenig dokumentiert zu dem Thema, fand ich gerade:
https://www.freifunk-gera-greiz.de/wiki/-/wiki/Allgemein/Sendeleistung

@DaCHRIS

This comment has been minimized.

Show comment
Hide comment
@DaCHRIS

DaCHRIS Apr 4, 2016

Rocket M2 only shows up ('iw list') with 18dbm on all channels instead of 28dbm.

                Frequencies:
                        * 2412 MHz [1] (18.0 dBm)
                        * 2417 MHz [2] (18.0 dBm)
                        * 2422 MHz [3] (18.0 dBm)
                        * 2427 MHz [4] (18.0 dBm)
                        * 2432 MHz [5] (18.0 dBm)
                        * 2437 MHz [6] (18.0 dBm)
                        * 2442 MHz [7] (18.0 dBm)
                        * 2447 MHz [8] (18.0 dBm)
                        * 2452 MHz [9] (18.0 dBm)
                        * 2457 MHz [10] (18.0 dBm)
                        * 2462 MHz [11] (18.0 dBm)
                        * 2467 MHz [12] (18.0 dBm)
                        * 2472 MHz [13] (18.0 dBm)
                        * 2484 MHz [14] (disabled)

DaCHRIS commented Apr 4, 2016

Rocket M2 only shows up ('iw list') with 18dbm on all channels instead of 28dbm.

                Frequencies:
                        * 2412 MHz [1] (18.0 dBm)
                        * 2417 MHz [2] (18.0 dBm)
                        * 2422 MHz [3] (18.0 dBm)
                        * 2427 MHz [4] (18.0 dBm)
                        * 2432 MHz [5] (18.0 dBm)
                        * 2437 MHz [6] (18.0 dBm)
                        * 2442 MHz [7] (18.0 dBm)
                        * 2447 MHz [8] (18.0 dBm)
                        * 2452 MHz [9] (18.0 dBm)
                        * 2457 MHz [10] (18.0 dBm)
                        * 2462 MHz [11] (18.0 dBm)
                        * 2467 MHz [12] (18.0 dBm)
                        * 2472 MHz [13] (18.0 dBm)
                        * 2484 MHz [14] (disabled)

@NeoRaider NeoRaider modified the milestones: 2016.3, next Dec 18, 2016

@NeoRaider NeoRaider modified the milestones: next, 2017.1 Feb 8, 2017

@rotanid rotanid added the known issue label Jun 5, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment