N PHY RX Core Set State (u8 maskbits)
- Establish a 16-element u16 buffer
Set phyrxchain to maskbits
If clk is zero
- Return
- Suspend the MAC
If phyhang_avoid
Call N PHY staying in carrier search with argument 1
Maskset PHY Register 0xA2 with 0xFF0F and set with (maskbits & 0x3) << 4
If maskbits & 3 not equal to 3
- Write 1 to PHY Register 0x20E
If PHY Revision >= 3
If rx2tx_biasentry equals -1
- Read the N PHY table with ID 7, length 16, offset 80, width 16, and the buffer as data pointer
- Loop 16 times with i as the loop index
- If the i'th entry in the table buffer is 0xF
Set rx2tx_biasentry to i
- Write the N PHY table with ID 7, length 1, offset i, width 16, and data 0
- break
- Else if the i'th entry in the table buffer is 0x1F
- Break
- If the i'th entry in the table buffer is 0xF
- Otherwise
- Write 0x001E to PHY Register 0x20E
If PHY Revision >= 3
If rx2tx_biasentry not equal to -1
Write the N PHY table with ID 7, length 1, offset rx2tx_biasentry, width 16, and data 0xF
Set rx2tx_biasentry to -1
Call N PHY Force RF Sequence with argument 2
If phyhang_avoid
Call N PHY staying in carrier search with argument 0
- Enable the MAC