Hi,
We're working on a development project using nRF52832, SDK 15.2 and s132_nrf52_6.1.0_softdevice. I'm trying to use the radio test example from the SDK to certify the device, but since our hardware is physically closed, there's no way to flash a different application or command it via UART. We do have an SPI connection from a different microcontroller, so I took radio_test.c and implemented SPI commands to call each of the functions found there. However, the rest of our application must remain there. My current strategy is to call sd_softdevice_disable when a specific SPI command to begin the radio test is received and then call the radio test function when the matching SPI command is received. When the radio test is completed, the nRF is reset and regular BLE operation resumes.
This works for the TX carrier and TX Sweep. I can see it on the RSSI viewer from another board when the command is received. However TX modulated data and RX data don't work. If I transmit from our device, the dev kit will not receive anything. If I transmit from the dev kit, our device receives something but it seems to be completely incorrect. For the transmission pattern 1111000, y expect to receive a packet filled with 0xF0 (which I do when using 2 devkits, one for TX and one for RX). Here I get: 0x04, 0x00, 0x20, 0xE9, 0x08, 0x00, 0x00, 0x7D, 0x05.... The contents seem fairly random, but they're always the same. Even if I listen on another channel where I'm not transmitting.
When transmitting, the received data on the dev kit is all 0.
Is it enough to call sd_softdevice_disable before calling the functions exported in radio_test.h or do I need to do something else? Is it possible at all to unload and disable the BLE stack to run the radio test or should I restart and run a different initialization?
I tend to think that it must be related to the unloading of the soft device because it's the most obvious difference, but perhaps it's something else. What else could be the issue? I'm not sure how to debug this, BLE works ok out of test mode.