Dear all,

I got a question regarding the implementation of a transmitter using C++ and 
UHD. I am working with a N310.


My problem is the following:


I want to implement an OFDM transmitter using C++ and the UHD lib. I already 
implemented the TXRX using the GNURadio framework. However, possible sampling 
rates seem to be restricted on my machine and that's why I want do the 
implementation in C++.


Here, I could already implement the sequence and the IFFT (I used the FFTW3 
libs). However, when I stream the data to the N310 and observe the spectrum I 
get a very strong carrier the rest of the spectrum looks more or less the way I 
expected... This strong carrier does not occur in GNURadio, so hardware should 
not be the issue.


Perhaps you could give me an hint what could cause this behaviour and how to do 
a workaround.


I read something about LO leakage and tried the tune_request_t but this also 
failed...


For the transmission of the sequence to the N310 I used the following code from 
the UHD examples...


std::vector<std::complex<float>> buff(buffer_size, std::complex<float>(0.3, 
0.3));
    for(i=sequence_length-1;i>0;i--)
    {
        
buff.push_back(std::complex<float>(sequence[i].real(),sequence[i].imag()));
    }

std::vector<std::complex<float>*> buffs(channel_nums.size(), &buff.front());

// print pre-test summary
    std::cout << boost::format("[%s] Channel sounding at transmit rate %f Msps 
on %u channels")
                     % NOW() % (usrp->get_tx_rate() / 1e6) % 
tx_stream->get_num_channels()
              << std::endl;

    // Create the metadata, and populate the time spec at the latest possible 
moment
    uhd::tx_metadata_t md;
    md.has_time_spec = true;
    md.start_of_burst = true;
    md.end_of_burst   = false;
    md.time_spec     = usrp->get_time_now() + uhd::time_spec_t(tx_delay);



    while (not burst_timer_elapsed) {
        const size_t num_tx_samps_sent_now =
            tx_stream->send(buffs, buff.size(), md)
            * tx_stream->get_num_channels();

    }



Any help would be highly appreciated!


Best regards,


Anton



Reply via email to