The radio transceiver provides the interrupts
TRX_IRQ_PLL_LOCK and
TRX_IRQ_PLL_UNLOCK which indicate locking and unlocking events of the PLL, respectively. The behaviour of these interrupts is described in detail in the section
section 7.8.5 (Interrupt Handling) of the AT86RF212 datasheet and in section
PLL Handling. Since the interrupts depend on each other, it is recommended to enable both of them in order to get notified about the most recent PLL event that happened.
- Note:
- A consecutive TRX_IRQ_PLL_LOCK interrupt clears a preceding TRX_IRQ_PLL_UNLOCK interrupt and vice versa.
Use Cases:
If the
TRX_IRQ_PLL_LOCK interrupt occurs in one of the
[PLL_ACTIVE] states, the PLL has locked and a transmission or reception of frames is possible.
- Code example
The
TRX_IRQ_PLL_UNLOCK interrupt indicates that the PLL has unlocked and is not able to generate the desired frequency. Unless followed by an
TRX_IRQ_PLL_LOCK interrupt within
tLockCrit, this is a
critical error (see
PHY_UNLOCK_PLL). In this case, the radio transceiver is neither able to receive nor to transmit.
- Note:
- If an TRX_IRQ_PLL_LOCK or TRX_IRQ_PLL_UNLOCK interrupt occurs in one of the RX_AACK or TX_ARET states, it is recommended to check the functionality of the PLL by reading the sub register SR_PLL_LOCK_CP. If the value 0 is read, do a transition to state TRX_OFF and execute PHY_UNLOCK_PLL or do a calibration of the PLL (see PHY_CALIBRATE_PLL).
- Code example
-