I would like to use the external antenna with BLE, the particle librairie offers this line of code for WIFI => STARTUP(Wifi.selectAntenna(ANT_EXTERNAL));. Can I do the same with BLE?
Since the system manages BLE and WiFi coexistence there is only one shared antenna, so it was always obvious to me that switching on external would switch both subsystems. However, this is a great question. Should we presume that switching WiFi switches BLE implicitly ?
After spending hours on testing the antenna switching. Finally I got the following conclusion:
Since the Duo does NOT solder the antenna switch on-board, so
WiFi.selectAntenna( ... )is not applicable for Duo. It has been documented here.
To use on-board chip antenna, nothing need to be changed. It is used by default when you got the Duo.
To use external antenna via the RF connector, you need to remove the components being figured out below:
If you do not remove the components while keep attaching an external antenna to the RF connector, both antenna will work, but the TX power and RX sensitivity will decrease.
It is sure that both Bluetooth and Wi-Fi share the same antenna whichever you choose to enable.
Thanks for the information. I was wondering why adding and selecting the external antenna made things worse.
Your comment “It has been documented here” only means 6 hours ago you updated the doc, correct? It does not mean that this is what RedBear Labs hardware engineers originally intended?
But I am still confused. Why is RedBear selling an external antenna for the Duo
and why does the Duo have an external antenna connector?
It seems a bit much to ask users to cut components off boards. What if their requirements change and they no longer need an external antenna?
In your testing, did you check both WiFI and BLE sensitivity? Was there an improvement for BLE?
I got better results on the BLE side when DUO is inserted in poor man breadboards.
RF is black magic tho
You’re right. The AP6212A module does not offer a control pin to control RF switch, which is different from the module on Photon. And it’s a pity that we didn’t pay much attention to the RF switching characteristic before production.
But it doesn’t mean that the Duo can not use an external antenna. We solder a RF connector so that you can use it with some additional changes to the board as stated above. I know it means a lot to some software developers. . I think there is little chance that application need to switch the external/internal antenna frequently.
Since both WiFi and BLE share the same antenna, when the antenna works in its best state, both the TX power and RX sensitivity of WiFi and BLE are in best performance. While you should know that the antenna is responsible for converting the high frequency on-board signal to wireless electromagnetic wave and vice versa, the power amplifier (PA) in the wireless chip determines the strongest strength of RF signal. And the PA of WiFi and BLE is independent in the wireless chip, so even the antenna works in its best state, the TX power and RX sensitivity may be different. Please figure me out if I phrase incorrectly.
Following is the framework of the wireless chip:
Thank you for the clarification and extra details.
I agree that switching from internal to external and back is not likely, but once the components are removed, I can’t repurpose the board sometime later to use internal, if needed. I have a soldering iron, but do not have a SMT rework station.
Maybe RedBear could offer a board with the extra components already removed for software developers.
So, based on your feedback, I am going to remove the components for now and pray I do not screw up the board.
I removed the two components and I am now seeing about a 5-6db improvement and an extended range of about 50 feet.
Thank you all for the appreciated info. Great community! Cheers to you all! After the very appreciated info from guohui, I was thinking about removing the components for the antenna chip but I am now wondering if removing the antenna chip itself would do the same? If the effect is the same, it would be a lot easier for software developers to remove the chip antenna than the tiny smd components.
@mrbig, you have to remove those tiny components rather than the chip antenna, since the impedance matching is 50 Ω from the module to the RF connector, as well as from the module to chip antenna, if you don’t remove those tiny components to totally cut off the circuit starting from RF connector, the impedance from module to RF connector mismatches , which will result to worse RF quality.
I have wifi signal problems so I decided to buy an external antenna to connect to my DUO, as you wrote in your Step 4 if we don’t remove those components the antenna should work but TX-RX sensitivity will decrease, could you verify this?
I’ve connected the external antenna and the results are the same than with the internal antenna.
I would prefer no cut anything but let me know how to fix it.
Yes I have verified this. There is no way to fix the external antenna issue unless you remove those tiny components.
Wow, what a difference ! Tried now and sensitivity is so much higher than on chip antenna !
I should blame RB engineers for this desoldering annoyance
Tell me a thing, @guohui: is it possible to damage the RF section if I forget to plug the external antenna after components removal ?
Thanks as usual
Not at all. Just decreases the RF RX sensitivity and TX power.
I’ve finally decided to remove those components but signal is worst than the beginning, i don’t know what is happening but when i’m 5 meters close to my router it is working more or less well but when I am more than 6/7 meters is not connecting anymore.
Hi @llcllc21, Make sure the external antenna is well attached and then perform a hardware reset to try again.
BTW, where did you buy the external antenna?
Can some body tell me the exact connector for the external antenna?
??? to sma female.
@guohui , I have bought a new antenna on amazon:
I’ve just checked it out but there is no connection, it continues blinking in green, when I put the antenna at 1 meter of the router it works fine. I attach an image.
Let me say, I am very disappointed because I cannot understand why with a cheaper device I have, ( oak by digistump 10$ ), I don’t have any problems with at least 20 meters through walls but with this redbear I cannot connect directly to 5 meters, but even more if I put this giant antenna of 20db I have the same problem so there is something wrong with my device??