bcm-v4

[Specification

Setting the TX Antenna

To define which antenna will transmit, the values above must be used in the PHY Transmit control word. It also must be written to the three control words in the shared memory that are used for beacons, probe responses and ack/cts frames.

RX Antenna Diversity Settings

It appears that the chipset uses only spatial diversity techniques for improving reception (which makes sense as a common configuration is two identical antennas). The settings allowed by the driver are:

Antenna Diversity Value

Setting

0

Force use of antenna 0 (Main)

1

Force use of antenna 1 (Auxillary)

2

Automatic Antenna Selection, starting with 1

3

Automatic Antenna Selection, starting with 0

Setting the Antenna Diversity

  1. Temporarily clear the antenna diversity host flag
  2. For A or G PHYs,
    1. Write the selected antenna diversity value (or automatic start 0 if automatic start 1 is selected) to the appropriate bits in the OFDM PHY baseband config register
    2. If automatic antenna selection will be enabled, set or clear the automatic rx diversity start antenna bit in the antenna dwell OFDM PHY register appropriately depending on the starting antenna, otherwise just leave it

    3. For G PHYs:
      1. set the automatic rx diversity enabled bit in the antenna WR settle OFDM PHY register appropriately

      2. If the PHY Revision is 2 or higher
        1. OR the OFDM PHY Register 0x61 with 0x10

        2. set the lower 8 bits of the OFDM PHY register 0xAD to 0x15

        3. If the PHY Revision is 2
          1. write 8 to OFDM PHY register 0x27

        4. Otherwise
          1. set the lower 8 bits of the OFDM PHY register 0x27 to 8

      3. If the PHY Revision is 6 or higher
        1. Write 0xDC to OFDM PHY register 0x9B

    4. for A PHYs:
      1. If the PHY Revision is less than 3
        1. set the lower 8 bits of the OFDM PHY register 0x2B to 0x24

      2. Otherwise
        1. Bitwise OR the OFDM PHY register 0x61 with 0x10

        2. If the PHY Version is 3
          1. Write 0x1D to PHY register 0x93

          2. Write 8 to OFDM PHY register 0x27

        3. Otherwise
          1. Write 0x3A to PHY register 0x93

          2. set the lower 8 bits of the OFDM PHY register 0x27 to 8

  3. for B PHYs, write the selected antenna diversity setting to the PHY baseband config register (in the regular Registers!), but use automatic start 0 if automatic start 1 is selected
  4. set the antenna diversity host flag again

Getting the Antenna Diversity

Simply take the value from the PHY baseband config register (from regular Registers or OFDM PHY Registers). Make sure that the microcode is not allowed to access the PHY Registers during that time, i.e. lock them.


Exported/Archived from the wiki to HTML on 2016-10-27