My customer is trying to use the KW40Z in their ZigBee products.
And they need to add external power amplifier and LNA to extend the RF Range for the product. However, they have encountered a problem on this part.
They use single antenna configuration and use only one GPIO PTC2 to control the TX/RX switch of the FEM (Front End Module).
Refer to the chapter 31 (FEM) and chapter 51 (ZLL) of the reference manual (Document Number: MKW40Z160RM Rev. 1.2, 10/2015):
Register/Field Name | Setting1 (Use TSM) | Setting 2 (Use FAD) |
PTC2 | Output GPIO (MUX=1) | MUX = 4 |
ZLL_FAD_CTRL Register: | ||
FAD_EN | 0 | 1 |
ANTX | 0 | 0 |
FAD_NOT_GPIO | 0 | 1 |
ANTX_EN | 01 | 01 |
ANTX_HZ | 0 | 0 |
ANTX_CTRLMODE | 0 | 0 |
ANTX_POL | 0 | 0 |
TSM Registers: | ||
TSM_TIMING42 | Have tried the following values with the above FAD Control Register value: 0x00000000 0xFFFFFFFF 0x01010101 0x03030303 0xFFFF0000 0xFFFF0303 | 0xFFFFFFFF |
Base on the above settings, the PTC2 always stays low even when the KW40Z transmitting and receiving data.
Also the gpio pin mapping shown in page 1036 and page 1408 of the reference manual are not consistent.
Can anyone advise the correct setting to enable the TX/RX Switch pin (PTC2) for 802.15.4.
Thank you very much!
Hi Alberto,
Thanks for the information. Customer have try the FAD setting accordingly and change the GPIO MUX to ALT2. However, we still cannot see the TX_SWITCH pin and RX_SWITCH pin switching according to the TX/RX operation in application.
Do we have any tested example code can show that FAD operation?
Register/Field Name | (Use FAD) |
PTC2 | Output |
ZLL_FAD_CTRL | |
FAD_EN | 1 |
ANTX | 0 |
FAD_NOT_GPIO | 1 |
ANTX_EN | 01 |
ANTX_HZ | 0 |
ANTX_CTRLMODE | 0 |
ANTX_POL | 0 |
Thanks and Best Regards,
WS
For the FAD TX SWITCH issue, please add below extra function call.
XcvrFadLppsControl(FAD_ENABLED);
HI,
I have custom KW41Z with FEM single module interface for FAD antenna.
Here we are using Openthread stack for implementation.
I'm not able to get the FAD enabling using the Openthread source code.
Please help providing some example source code.
Thanks & Regards,
Ramya
Hi Haidong,
Thanks for the information and issue cleared.
Thanks, WS
Hi Alberto
Is there any reference registers setting for K40 work with external PA + external antenna switch by using the FAD (TX_SWITCH and RX_SWITCH pins only) control that automatically?
If we do not use the FAD but use GPIO to control that switching manually, how can we sync up the external circuit switching with the internal transceiver for auto ACK after valid package received?
Thanks and Best Regards,
WS Wong
Hi WS Wong,
To use TX_SWITCH and RX_SWITCH, ANTX_EN (ZLL_FAD_CTRL) needs to be configured as: 01 only RX/TX_SWITCH enabled, also mentioned on chapter 31.1.4.3.
From the comment of keli, I can see that PTC2 (TX_SWITCH) is being configured as GPIO.
Register/Field Name | Setting1 (Use TSM) | Setting 2 (Use FAD) |
PTC2 | Output GPIO (MUX=1) | MUX = 4 |
ZLL_FAD_CTRL Register: | ||
FAD_EN | 0 | 1 |
ANTX | 0 | 0 |
FAD_NOT_GPIO | 0 | 1 |
ANTX_EN | 01 | 01 |
ANTX_HZ | 0 | 0 |
ANTX_CTRLMODE | 0 | 0 |
ANTX_POL | 0 | 0 |
TSM Registers: | ||
TSM_TIMING42 | Have tried the following values with the above FAD Control Register value: 0x00000000 0xFFFFFFFF 0x01010101 0x03030303 0xFFFF0000 0xFFFF0303 | 0xFFFFFFFF |
This is the reason because it stays low. To use TX_SWITCH and RX_SWITCH output, the pin mux of PTC2 and PTC3 must be configured as alternative 2 (please refer to KW40 Reference Manual, Chapter 2).
Best Regards,
Alberto
Alberto:
As the same configuration logic on the KW24x, TX_SWITCH and RX_SWITCH pad signal could be seen toggled when data been transmitted and received.
So have done the verification on KW40 ?
Thanks!
Hi keli, TX_SWITCH (PTC2) and RX_SWITCH (PTC3) are mainly used by Fast Antenna Diversity feature. If I understand, your client is trying to extend their range using a PA with a single antenna configuration. In this case, it is not necessary to configure these pins neither FAD. They can control the PA to switch between TX and RX using a GPIO.
Regards,
Alberto