LP PHY PAPD Cal TXpwr
- Create lpphy_txcalgains structures named txgains and oldgains
- Read PHY Register 0xA4, mask with 0xE000, and save as oldpower
Set oldoverride to ((PHY Register 0x43B & 0x0040) != 0)
- If oldoverride is not zero
Call LP PHY Get TX Gain with oldgains as argument
Set oldrf to PHY Register 0x4D3 & 0x00FF
Set oldbbmult to the value returned by LP PHY Get BB Mult
Call LP PHY Set TX Power Control with 0 as argument
- Store 1 at the useindex member of txgains
- If this is a 4325 AND the chip revision is 0
- Store 30 at the index member of txgains
- Otherwise
- Store 65 at the index member of txgains
Call LP PHY PAPD Cal with arguments &txgains and 0
- If oldoverride not zero
Call LP PHY Set TX Gain with oldgains as argument
Call LP PHY Set BB Mult with oldbbmult as argument
Call LP PHY Set TX Power Control with oldpower as argument
- Maskset PHY Register 0x4D3 with mask 0xFF00 and set with oldrf