[USRP-users] Compiling own code in Visual Studio 2010, 64bit

Emanuel.Staudinger at dlr.de Emanuel.Staudinger at dlr.de
Thu Dec 18 09:19:48 EST 2014

Hi all,

I read through so many different pages and approaches how to build your own code using the UHD API, but I did not manage to run everything successfully. Maybe somebody has a hint :)
That's what I have right now:

*         USRP X310 connected via GigE or PCIe

*         Installed the lates UHD 64bit release, installed visual studio professional 2010

*         Boost library is installed as binary with the correct Visual Studio 2010 64bit Version (as I'm using Win7 64bit)
I tested the uhd_find_device and the uhd_usrp_probe exe-files provided in the UHD installation directory: both worked fine and showed correct results.

I wanted a simple program: Starting with the thread safe uhd main, and then simply calling ....multi_usrp::make(""); as the USRP is currently connected via Ethernet.
I set up Visual Studio as follows:

*         Starting with an empty Win32 console project and changing configuration to X64 (Debug)

*         In the C++ configuration I add the UHD and Boost include directories

*         In the Linker configuration I add the UHD lib and the Boost lib as additional library directories

*         I also add uhd.lib in the "Additional Dependencies" tab
Everything compiles fine without errors. The Linker also does not through any errors. So far so good. Next, I copied the uhd.dll from the UHD installation directory (bin folder) to where by generated exe lies.
I start my program and when I reach the ::make statement in my C++ code, I get an access violation. The uhd.dll is found, otherwise my program complains about not finding the dll right at startup.

Why do I get an access violation? Is it the wrong uhd.dll?

Best regards,

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ettus.com/pipermail/usrp-users_lists.ettus.com/attachments/20141218/584a395f/attachment-0002.html>

More information about the USRP-users mailing list