Please or Register to create posts and topics.

AARTSAAPI_StopDevice & AARTSAAPI_StartDevice

Page 1 of 2Next

Good morning,

We are having a little bit strange issue when using sweep mode with values extended from 3e7 to 6e9 using filter auto extended.

We have a loop to start/stop the meetering from the device, at first round it runs smoothly but when we stop the process using AARTSAAPI_StopDevice and we start it again with AARTSAAPI_StopDevice  it inmediatly starts to return empty values. (AARTSAAPI_GetPacket(&deviceHandler, 0, 0, &_packet2) =1 instead of 0).

when setting  main/stopfreq value to 80e6 it runs fine. We do not understand why this is happening. Can you help us?


Thanks in advance.



May this code help to reproduce the issue:

AARTSAAPI_Result res;

// Initialize library for medium memory usage


// Open a library handle for use by this application


if ((res = AARTSAAPI_Open(&h)) == AARTSAAPI_OK)
// Rescan all devices controlled by the aaronia library and update
// the firmware if required.

if ((res = AARTSAAPI_RescanDevices(&h, 2000)) == AARTSAAPI_OK)
// Get the serial number of the first V6 in the system

AARTSAAPI_DeviceInfo dinfo = { sizeof(AARTSAAPI_DeviceInfo) };

if ((res = AARTSAAPI_EnumDevice(&h, L"spectranv6", 0, &dinfo)) == AARTSAAPI_OK)
// Try to open the first V6 in the system in sweep mode


if ((res = AARTSAAPI_OpenDevice(&h, &d, L"spectranv6/sweepsa", dinfo.serialNumber)) == AARTSAAPI_OK)
// Begin configuration, get root of configuration tree

AARTSAAPI_Config config, root;

if (AARTSAAPI_ConfigRoot(&d, &root) == AARTSAAPI_OK)
// Select the first receiver channel

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"device/receiverchannel") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetString(&d, &config, L"Rx1");

// Use fast receiver clock

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"device/receiverclock") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetString(&d, &config, L"245MHz");

// La magia
if (AARTSAAPI_ConfigFind(&d, &root, &config, L"calibration/rffilter") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetString(&d, &config, L"Auto Extended");

// Start frequency at 75MHz

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"main/startfreq") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetFloat(&d, &config, 30e6);

// Stop frequency at 6000MHz

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"main/stopfreq") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetFloat(&d, &config, 6000e6);

// Set RBW frequency to 1MHz

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"main/rbwfreq") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetFloat(&d, &config, 1.0e6);

// Reference level at -20dBm

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"main/reflevel") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetFloat(&d, &config, 10.0);


// Select iq as output format

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"device/outputformat") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetString(&d, &config, L"iq");

// Set decimation to 1/64

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"main/decimation") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetString(&d, &config, L"1 / 64");

// Connect to the physical device

if ((res = AARTSAAPI_ConnectDevice(&d)) == AARTSAAPI_OK)
for (int n = 0; n < 50000; n++) {
// Start the receiver

if (AARTSAAPI_StartDevice(&d) == AARTSAAPI_OK)
// Receive some spectra
std::cout << "---------[" << n << "]" << "\n";

// Stop the receiver


// Release the hardware

std::wcerr << "AARTSAAPI_ConnectDevice failed : " << std::hex << res << std::endl;

// Close the device handle

AARTSAAPI_CloseDevice(&h, &d);
std::wcerr << "AARTSAAPI_OpenDevice failed : " << std::hex << res << std::endl;
std::wcerr << "AARTSAAPI_EnumDevice failed : " << std::hex << res << std::endl;
std::wcerr << "AARTSAAPI_RescanDevices failed : " << std::hex << res << std::endl;

// Close the library handle

std::wcerr << "AARTSAAPI_Open failed : " << std::hex << res << std::endl;

// Shutdown library, release resources

std::wcerr << "AARTSAAPI_Init failed : " << std::hex << res << std::endl;

Also the following configuration leads to a Access Violation Reading exception:

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"main/startfreq") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetFloat(&d, &config, 5e9);

if (AARTSAAPI_ConfigFind(&d, &root, &config, L"main/stopfreq") == AARTSAAPI_OK)
AARTSAAPI_ConfigSetFloat(&d, &config, 6e9);


This is fixed from build 10056 on. Thanks for the report!

My pleasure , thank you very much for confirming and fixing.

Sorry, It's probably my fault, but from where can I download this build? I am totally unable to find it out, and  just see the RTSA-Suite PRO - Stable (Windows) at the download page.


Please send us a mail to get a link for the latest BETA.

MiguelAngel.DiazDelaCampa has reacted to this post.

done, sent to [email protected]

vielen dank für die gute arbeit !!

Good morning, got the link by email but sadly seems I am not allowed to download it :


Ray ID: 6c0181cebec4718a • 2021-12-19 15:01:35 UTC

Access denied

What happened?

This website is using a security service to protect itself from online attacks.


Please ensure that you've enabled cookies for that site, else the CDN provider might block access. Also it might help to clear the browser cache and delete existing cookies, and/or use a different browser (see ). If that doesn't fix the error please contact [email protected] again.

Page 1 of 2Next