A tutorial describing general PCB guidelines for nRF51 have previously been written. It can be found here. But parts of this tutorial is not applicable to nRF52 since there are some differences. The biggest change is that nRF52 have an internal balun which make the matching different. A bigger part of this post is the same as the previous mentioned tutorial, but it is repeated here for completeness, with updated links to nRF52 documentation.
When designing a high frequency PCB there are some rules that should be followed in order to get a good working radio/system. Below are some general PCB guidelines presented. These guidelines should be followed to maximize the performance of the system. It is also recommended to read about PCB guidelines in the reference circuitry page on infocenter.
The RF part of the schematic and layout should be a copy of our reference design. It means that not only the component values, but also the geometry, relative placement of the components with respect to each other, and the lengths of the transmission lines should be the same as in our reference design. The reference design for nRF52832 (altium and pdf) can be downloaded in the infocenter page.
When the frequency get high electronic circuits behave differently. This is because the wavelength of the signal gets comparable with the size of the electronic, meaning that there will be a phase difference on lines etc. Impedance matching is to design the electronics so that the impedance in each point of the circuit give maximum power transfer. If matching is bad power is lost and unwanted behavior can be experienced. The physics describing electronic behavior is not the scope of this report, but a lot can be found by searching for impedance matching. Here both the output of the chip and the antenna will be matched to a 50 ohm reference point.
Matching to 50 ohm: The output impedance of the chip is not 50 ohm. Therefore a matching network needs to be inserted between the chip and the reference point. Please note that this matching is NOT the same as with nRF51.
The figure above show parts of the pinout of nRF52. Note that there is only one antenna pin (nRF51 have two). nRF52 have an internal balun which make matching easier to accomplish.
One example of the matching network is found in the reference design. The pcb layout (pad size, lines etc) is a part of the matching so make sure that your design is an exact copy of the reference design. The matching is done with two components, L1 and C3. These components also form a low pass filter which will suppress harmonics which are needed for the design to pass various regulatory standards. The whitepaper "Regulatory and Compliance Standards for RF Device" sums up the most common regulatory standards. If tuning is needed (because the performance, i.e. range, is not as expected) the whitepaper "Tuning the nRF24xx matching network" can be used. Please note that this is written for nRF24LE1, but the principles are the same.
Matching the antenna to 50 ohm: There are basically two types of antenna matching networks; pi-network and a matching network consisting of one shunt component only. The type of antenna decides which matching network to use. If using a PCB antenna, the matching network should consist of one shunt component, and if using a chip antenna, the matching network should be a pi-network. The value(s) of the component(s) in the matching network will have to be found during tuning, by doing measurements using a network analyzer. The reason for this is that the impedance of the antenna depends on its close environment; it means that the measurements on a device should be performed when the device is placed in its final housing, in a similar environment to where it is supposed to be used. It is not possible to calculate the value(s) for the component(s) in the matching network, because there are too many parameters to take into account. The "Antenna tuning" whitepaper explains more about why tune the antenna, and how to do it.
Below is an example of the matching between the chip and a PCB antenna.
There are two types of antennas that can be used, a PCB antenna or a chip antenna. Under optimal conditions, the performance of a PCB antenna and a chip antenna will be more or less the same.
PCB antenna: The whitepaper "Quarterwave printed monopole antenna for 2.4GHz" explains how to design a PCB antenna.
Chip antenna: Any 2.4 GHz antenna can be used. In order to obtain good performance, it is important to place the antenna according to its datasheet. The antenna datasheet will also contain information about the bandwidth of the antenna.
A typical design consists of two ground planes; a top ground plane and a bottom ground plane. Both ground planes should preferably be as large and solid as possible. Ground is the reference of the system, the impedance of the antenna should for example be 50 Ohm with respect to ground. The larger the ground planes are, the more it takes to disturb them. The two ground planes should be connected using a lot of via holes. Our reference designs show what the distribution of the via holes may look like.
##Crystal and load capacitors
Crystal: On nRF52 an external 32 MHz crystal is mandatory, and an external 32 kHz crystal is optional. The benefits of including the 32 kHz crystal are discussed here. When choosing a crystal it is important that it is within the specifications. Specifications for 32 MHz clock oscillator is found in table "64 MHz crystal oscillator (HFXO)", for the 32 kHz crystal it is found in "Low frequency crystal oscillator (LFXO)".
Load capacitors: The load capacitors are the capacitors connected to the crystal, C1 and C2 connected to the 32 MHz crystal in our reference design, and C13 and C14 for the 32 kHz crystal.The value of these capacitors can be found using the following formula:
C1 = C2 = 2Cl - C_pcb - C_pin
Cl: Load capacitance of the crystal (found in the crystal datasheet)
C_pcb + C_pin is approximately 4 pF.
Details can be found in the whitepaper "Crystal Oscillator Design Considerations". Please note that this paper is written for older chips (not nRF51/52) and that the input capacitance is ~4pF for nRF52 (not 1pF as stated).
Measuring the frequency of the 32 MHz crystal should be done by measuring the carrier frequency of the radio. If the carrier frequency of the radio is within the specifications, the 32 MHz crystal is also within the specifications. If trying to probe the crystal directly, the frequency of the crystal will drift, because the probe possesses a capacitance, and this will effectively change the total value(s) of the load capacitors.