mirror of
https://github.com/pascallanger/DIY-Multiprotocol-TX-Module.git
synced 2025-02-10 13:18:12 +00:00
FiX AFHDS2A RX LNA switch
This commit is contained in:
parent
edb7729b35
commit
6848fab873
@ -73,7 +73,7 @@ uint16_t initAFHDS2A_Rx()
|
|||||||
packet_count = 0;
|
packet_count = 0;
|
||||||
afhds2a_rx_data_started = 0;
|
afhds2a_rx_data_started = 0;
|
||||||
afhds2a_rx_disable_lna = IS_POWER_FLAG_on;
|
afhds2a_rx_disable_lna = IS_POWER_FLAG_on;
|
||||||
CC2500_SetTxRxMode(afhds2a_rx_disable_lna ? TXRX_OFF : RX_EN);
|
A7105_SetTxRxMode(afhds2a_rx_disable_lna ? TXRX_OFF : RX_EN);
|
||||||
A7105_Strobe(A7105_RX);
|
A7105_Strobe(A7105_RX);
|
||||||
|
|
||||||
if (IS_BIND_IN_PROGRESS) {
|
if (IS_BIND_IN_PROGRESS) {
|
||||||
@ -105,7 +105,7 @@ uint16_t AFHDS2A_Rx_callback()
|
|||||||
#endif
|
#endif
|
||||||
if (afhds2a_rx_disable_lna != IS_POWER_FLAG_on) {
|
if (afhds2a_rx_disable_lna != IS_POWER_FLAG_on) {
|
||||||
afhds2a_rx_disable_lna = IS_POWER_FLAG_on;
|
afhds2a_rx_disable_lna = IS_POWER_FLAG_on;
|
||||||
CC2500_SetTxRxMode(afhds2a_rx_disable_lna ? TXRX_OFF : RX_EN);
|
A7105_SetTxRxMode(afhds2a_rx_disable_lna ? TXRX_OFF : RX_EN);
|
||||||
}
|
}
|
||||||
|
|
||||||
switch(phase) {
|
switch(phase) {
|
||||||
@ -156,7 +156,7 @@ uint16_t AFHDS2A_Rx_callback()
|
|||||||
case AFHDS2A_RX_BIND2 | AFHDS2A_RX_WAIT_WRITE:
|
case AFHDS2A_RX_BIND2 | AFHDS2A_RX_WAIT_WRITE:
|
||||||
//Wait for TX completion
|
//Wait for TX completion
|
||||||
pps_timer = micros();
|
pps_timer = micros();
|
||||||
while (micros() - pps_timer < 700) // Wait max 700µs, using serial+telemetry exit in about 120µs
|
while (micros() - pps_timer < 700) // Wait max 700µs, using serial+telemetry exit in about 120µs
|
||||||
if (!(A7105_ReadReg(A7105_00_MODE) & 0x01))
|
if (!(A7105_ReadReg(A7105_00_MODE) & 0x01))
|
||||||
break;
|
break;
|
||||||
A7105_Strobe(A7105_RX);
|
A7105_Strobe(A7105_RX);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user