Radio Tests on nRF52 Series

In this blog, I would like to introduce the method how to test on the RF (Radio) on the NRF5 Series.

It would covers the following topics.

  • nRF Connect RSSI Viewer
  • Simple Radio Test
  • Direct Test Mode

nRF Connect RSSI Viewer

Simple app for nRF Connect that shows a visualization of RSSI data. The app shows dBm per frequency in the 2400-2480 MHz range, and allows the user to tweak settings like sweep delay and animation duration. The app can be installed from the Add/remove apps screen in nRF Connect.

The following devices are supported:

  • PCA10040 nRF52832 Development Kit
  • PCA10059 nRF52840 Dongle

https://github.com/NordicSemiconductor/pc-nrfconnect-rssi

screenshot

Radio Test Example

The Radio Test Example demonstrates how to configure the radio as the constant RX or TX carrier, the modulated TX carrier, or the RX or TX sweep.

https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v15.3.0/nrf_radio_test_example.html

The tests are controlled with Command Line Interface (CLI) by the serial port. At any time during the tests, you can set the radio parameters output power, bit rate, and channel. You can also set the time on each channel in the sweep mode, in steps of 1 millisecond to 99 milliseconds, every 1 millisecond. The application also allows you to send a data pattern to another board.

The application starts with enabling the high frequency crystal oscillator and configuring CLI. Calling a console command causes the appropriate action.

CLI commands

The following table lists the available main CLI commands, in alphabetical order.

CommandArgumentDescription
cancelCancel the sweep or the carrier.
data_rate<sub_cmd>Set the data rate.
end_channel<channel>End the channel for the sweep.
output_power<sub_cmd>Output power set.
parameters_printPrint current delay, channel, and other parameters.
print_rxPrint the received RX payload.
start_channel<channel>Start the channel for the sweep or the channel for the constant carrier.
start_duty_cycle_modulated_tx<duty_cycle>Duty cycle in percent (two decimal digits, between 01 and 99).
start_rxStart RX.
start_rx_sweepStart the RX sweep.
start_tx_carrierStart the TX carrier.
start_tx_modulated_carrierStart the modulated TX carrier.
start_tx_sweepStart the TX sweep.
time_on_channel<time>Time on each channel (between 1 ms and 99 ms).
toggle_dcdc_state<state>Toggle DC/DC converter state.
transmit_pattern<sub_cmd>Set transmission pattern.

You can find the source code and the project file of the example in the following folder: <InstallFolder>\examples\peripheral\radio_test


Direct Test Mode (DTM)

The main function of a production test is to verify that all the components are mounted correctly and have correct values after assembling a device. To perform a production test on a Bluetooth® low energy application, it is preferable to use a builtin function called Direct Test Mode (DTM). The DTM enables testing of the RF parameters and is also used for end-product qualification testing of the RF physical layer (RF PHY). Bluetooth low energy products of Nordic include a UART interface that gives access to the Direct Test Mode (DTM).

The DTM has two main modes of operation; the transmit test mode and the receive test mode. In transmit test mode, the Device Under Test (DUT) generates a predefined set of test packets. In receive test mode, the DUT counts the number of test packets received.

The DTM is specified on the bluetooth core specification (available from this site) in Vol 6, Part F.

In addition, you can have a look at the python scripts that implements DTM from bluetooth v4.0 in nAN-34: 

nAN34 – Setting up production test using DTM

DTM enables a set of RF PHY test cases, which are defined by the Bluetooth Special Interest Group (SIG) in the documents from the sections called “TCRL Release Table” and “Core – Test Requirements for v4.0 or later” found at the beginning of the https://www.bluetooth.com/specifications/qualification-test-requirements web page.
Note: The following information was updated in the first half of 2017. For current information, refer to the newer TCRL 2017-1, that is, to the corresponding 2017-1 TCRLs-1.zip file containing the newer RF-PHY.TS.5.0.1.
The Capability tests (as defined in the standard ISO subgroups) are organized in levels and groups representing protocol services, functional modules, and purposes, the latter being divided in operating conditions for the transmitter and the receiver. All the relevant RF PHY tests are in accordance to the test specifications RF-PHY.TS.4.2.3 or the updated RF-PHY.TS.5.0.0 and are shown in the RFPHY sheet of the Excel file called Core.TCRL.2016-2.xlsx found inside the 2016-2 TCRLs.zip.

Below are examples of test cases for the Physical Layer Conformance. They are referred to by their identifiers, where TP stands for
Test Purpose and TRM-LE and RCV-LE stand for LE Transmitter and LE Receiver test respectively.
• TP/TRM-LE/CA/BV-01-C [Maximum peak and average output power]
• TP/TRM-LE/CA/BV-03-C [In-band spectral emissions]
• TP/TRM-LE/CA/BV-05-C [Modulation Characteristics]
• TP/TRM-LE/CA/BV-06-C [Carrier frequency offset and carrier drift]
• TP/RCV-LE/CA/BV-01-C [Receiver sensitivity]
• TP/RCV-LE/CA/BV-03-C [C/I and Receiver Selectivity Performance] [Additional blocker needed to generate co-/adjacent channel interference]
• TP/RCV-LE/CA/BV-04-C [Blocking Performance] [Additional blocker needed to generate interference outside the 2400MHz –
2483.5MHz band]
• TP/RCV-LE/CA/BV-05-C [Intermodulation Performance] [2 x additional blocker needed to generate both a sinusoidal/un-modulated
and a continuous/modulated carrier]
• TP/RCV-LE/CA/BV-06-C [Maximum input signal level]
• TP/RCV-LE/CA/BV-07-C [PER Report Integrity]

Additional test cases have been introduced since the release of Bluetooth 5. A few examples of the many new test cases are listed
below:
• TP/TRM-LE/CA/BV-08-C [In-band emissions at 2 Ms/s]
• TP/TRM-LE/CA/BV-10-C [Modulation Characteristics at 2 Ms/s]
• TP/RCV-LE/CA/BV-08-C [Receiver sensitivity at 2 Ms/s]
• TP/RCV-LE/CA/BV-10-C [Blocking performance at 2 Ms/s]


Two Wire Commands through DTM

Command Packet

Command packet test setup

Command Packet – TX / RX (and Nordic Vendor Specify)

TX Power on NRF52832

2-Wire Event Packet

Test Status Response

Example command on the UART for DTM

Basic commands

  • RESET: 0x00 0x00
  • TEST END: 0xC0 0x00

Transmit test

  • Channel 0, i.e. 2402MHz pure carrier
    • 0x00 0x00 0x80 0x07
  • Channel 19, i.e. 2440MHz 10 byte PRBS9 payload
    • 0x00 0x00 0x93 0x28

The above commands will send packets until TEST END is received

To sweep channels, make a loop of RF channel increment.

Receive test

  • Channel 19, i.e. 2440MHz
    • 0x00 0x00 0x53 0x00

The above command receives all types of payload continuously until TEST END command is received.

Bluetooth 5 Example (DTM)

Nordic Specific

Basic commands

  • RESET: 0x00 0x00
  • TEST END: 0xC0 0x00

Transmit Test:

Channel 19, i.e. 2440MHz 10 bytes PRBS9 payload

  • 0x00 0x00 0x09 0x28

Set TX Power +4dBm

  • 0x84 0x0B

Channel 0 i.e. 2402MHz carrier

  • 0x80 0x03

Channel 19 37bytes PRBS9 payload

  • 0x93 0x94

Check feature supported

  • 0x04 0x00

Set 2Mbps mode

  • 0x93 0x94

Receive test:

Channel 19, i.e. 2440MHz

  • 0x00 0x00 0x53 0x000

If you need to get the tool on PC for DTM, you can download it from https://github.com/olleheugene/nRF-DTM.

The nRF_DTM is UI based test tool that helping to RF test by easy control

  • UI based RF test tool
  • Support Bluetooth 5 features (2Mbps/Coded S8/Coded S2/1Mbps)
  • Support 3 Different channels testing (High/Mid/Low)
  • Configurable Tx Power
  • Support PER measurement
  • Support configurable log level in order to check test sequence and detiails
  • Support direct command on terminal and command line interface on shell

51 thoughts on “Radio Tests on nRF52 Series

  1. Thanks for ones marvelous posting! I definitely enjoyed reading it, you will be
    a great author.I will ensure that I bookmark your blog and will coe back down the road.
    I want to encourage continue your great posts,
    have a nice morning!

    Like

  2. Hey! This is my first visit tto your blog! We are a team
    of volunteers and starting a new initiative in a community
    in the same niche. Your blog provided us valuable information to work on. You have
    done a marvellous job!

    Like

  3. I like the valuable information you provide for your articles.
    I wikll bookmark your blog and take a look at again here regularly.
    I am slightly certain I’ll bee informed plenty of new stuff right right here!

    Goodd luck for the next!

    Like

  4. I have been surfing online more than three hours today,
    yet I never found any interesting aticle like yours.
    It is pretty worth enough for me. In my opinion, if
    all site owners and bloggers made god content as you did, the web will be a lot more usefuil than ever before.

    Like

  5. I’m now not certain where you are getting your information, however
    good topic. I must spend some time learning much more or understanding more.
    Thank you for wonderful info I used to be on the lookout for this info for my mission.

    Like

  6. I have been surfing on-line more than 3 hours as of late, but I never
    discovered any fascinating article like yours.

    It is lovely worth sufficient for me. Personally, if all
    site owners and bloggers made just right content material as you probably did, the net can be a lot more helpful than ever
    before.

    Like

  7. Greate post. Keep posting such kind of info on your site.
    Im really impressed by your site.
    Hey there, You have performed a great job. I’ll definitely digg it and
    for my part suggest to my friends. I’m sure they’ll
    be benefited from this website.

    Like

  8. I think this is among the most vital info for me.
    And i’m glad reading your article. But should remark on some general
    things, The web site style is wonderful, the articles
    is really nice : D. Good job, cheers

    Like

  9. great issues altogether, you simply won a emblem new
    reader. What could you recommend about your put up that you simply made some days in the past?
    Any positive?

    Like

  10. Wonderful goods from you, man. I have understand your stuff previous to
    and you’re just too excellent. I really like what you have acquired here, really like what
    you are stating and the way in which you say it.
    You make it enjoyable and you still care for to keep it smart.

    I can not wait to read far more from you. This is really a terrific
    website.

    Like

  11. After going over a few of the blog articles on your website, I really like your way of blogging.
    I added it to my bookmark webpage list and will be checking back soon. Please check out my web site too and let me know how you feel.

    Like

  12. Thanks for a marvelous posting! I certainly enjoyed
    reading it, you happen to be a great author.I will make sure to bookmark your blog and may come back
    in the future. I want to encourage you to ultimately continue your great writing,
    have a nice day!

    Like

  13. Hi there! I’m at work surfing around your blog from my new iphone 4!
    Just wanted to say I love reading your blog and look forward to all your
    posts! Keep up the excellent work!

    Like

  14. Hi Jimmy! Thank you for the awesome write-up and the nRF-DTM PC utility.
    I tested with nrf51822 controller (onboard PA / LNA) that I have, I am facing an issue when I put the transmitter in Constant Carrier mode then PER is 100% on the receiver but for other Payload models it is working fine. What could be the issue?
    PS: It work for me couple of times and then stopped all of a sudden.
    Thanks in advance for your help.

    Like

  15. Hi Jimmy! Thank your for the awesome blog and nRF-DTM software for PC.
    I tested this with nRF51822 controller (with onboard PA/ LNA) that I have. All the Payload models are working fine except for Constant Carrier, with Constant Carrier the PER is 100% on the receiver end. Any pointers on what could be the issue?
    Thanks for your help in advance.

    Like

    1. Hi,
      If you are using constant carrier, it means that the radio packet doesnt consist of any data ‘0’ or ‘1’. PER is 100%. This is in expectation.

      Like

      1. Noted! Thanks for quick response.
        There is one more thing, I am getting “ERROR> (Set Tx power) Event Error” whenever I set Tx power to negative value (-4dBm or lower).

        Like

  16. Have you ever considered about adding a little bit more than just your articles?
    I mean, what you say is fundamental and everything. Nevertheless think of if you
    added some great pictures or videos to give your posts more, “pop”!
    Your content is excellent but with images and clips,
    this website could certainly be one of the very best in its field.
    Very good blog!

    Like

  17. Hello! I could have sworn I’ve been to your blog before but after looking at some of the posts
    I realized it’s new to me. Regardless, I’m certainly happy I discovered it and I’ll be book-marking it and
    checking back regularly!

    Like

  18. Hey there! I’ve been following your web site for a long time now and finally got the courage to go
    ahead and give you a shout out from Houston Tx! Just wanted to say keep up the great job!

    Like

  19. hi ,

    i m testing my nrf52832 by dtm.
    I m flashing dtm code with rx tx pin changes.
    By using DTM tool. i transmit the signal.
    i m getting exactly what u have posted in gif.But in lab, they said not getting any signal.
    I dont know what is the issue ?
    kindly help me

    Like

      1. thanks for quick reply
        I tested two boards (one is transmitter and other one is receiver)in my office . I can able to receive packets which same as your gif.
        But in the lab ,they said not receiving signal from the board.

        Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.