Use constructor library on Raspberry Pi using VisualGDB :

Sysprogs forums Forums VisualGDB Use constructor library on Raspberry Pi using VisualGDB :

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #7498
    yfourel
    Participant

    Hello, it’s the first time I write on this forum. To present me, I’m 23, and in my new company, I need to use VisualGDB.

    I have to do GUI with Visual and use library allowing me to control cameras (for exemple to display the image of the camera on my Qt application, capture an image, detect a movement, zoom in…).

    Lat week, I used Visual Studio to make this application on Windows and it works (by using “Cameralib.h”, “Cameralib.lib” and “Cameralib.dll”).

    Now I want to do the same application on a Raspberry Pi. With VisualGDB, I made a sucess to display on my raspberry a simple window. So, my toolchain is Ok, and I can send by SSH my application to my raspberry.

    But now, I need to add the control of my cameras in the application on my Raspberry Pi. And I’m totally lost concerning what I have to do with my library. Do a compilation on Windows with the same .H, .lib and .dll, and add the .a and .so on my Raspberry ? Or do the application on Windows with the .a and .so ? Have I to add some informations in my “VisualGDB project properties” ?

    I think a lot of persons have to use constructor library on Windows applications, and Arm (processor of my Raspberry), and do this step on VisualGDB, but I found no information on the Internet.

    Thank you very much for your help, and I hope that my explanations are understandable.

    yfourel

    #7518
    support
    Keymaster

    Hi,

    Not sure what do you mean by the constructor library, but we actually have a tutorial showing how to access Raspberry Pi camera from your VisualGDB projects: http://visualgdb.com/tutorials/raspberry/camera/

    And another one with OpenCV: http://visualgdb.com/tutorials/raspberry/opencv/camera/

    Consider following those to get basic understanding of using external libraries with VisualGDB.

    #7526
    yfourel
    Participant

    Thanks a lot, it should help me.

    The company which sells us cameras supplies me a .so and a .a, and I put it on my sysroot and on my raspberry as you say in

    https://sysprogs.com/w/forums/topic/visualgdb-cant-debug-parts-of-a-library/

    Thank you again !

    #7536
    support
    Keymaster

    Hi,

    Then we would recommend asking the camera vendor for a C++ project example showing how to use their library. You can then import that example into a VisualGDB project and step through it to understand how it works.

    #7538
    yfourel
    Participant

    Ok, I’ll do it !

    Thanks again !

    #7547
    yfourel
    Participant

    Just for confirmation, I placed my .so and .a in usr/local/lib and the .h in usr/local/include.

    After that I have done my “Synchronize sysroot” (after that I find my .so, .a, .h in my SysGCC on Windows).

    I indicate the name of my library and the directories (in qmake project setting) and when I apply, I obtain this problem :

    ../arm-linux-gnueabihf/bin/ld.exe: skipping incompatible c:\sysgcc\raspberry\bin\../arm-linux-gnueabihf/sysroot/usr/local/lib/MyLib.so

    The same error for MyLib.a.

     

    On Raspberry, if i do on the consol : file /MyLib.so, I see that the library is for Intel, so I think that’s the problem.

    I had windows sdk, then I ask linux_sdk for Raspberry, but apparently I need an other .so and .a, for Arm processor ?

    If you could juste confirm that to me before I ask the constructor other sdk…

    (in your WiringPi example, we install directly the library since the raspberry, so it must be Arm library I suppose ?)

     

    Thanks a lot ! 🙂

     

    #7557
    support
    Keymaster

    Hi,

    Yes, the library should be suited for ARM devices. Furthermore, it should be compiled with the matching CPU type, ABI and floating point settings.

    Please ask the vendor for a specific library for Raspberry Pi or the library sources so that you can build it yourself.

    #7567
    yfourel
    Participant

    Thank you. It’s ok now !

    Have a good end of week !

    #7574
    support
    Keymaster

    No problem. Let us know if you run into further problems.

Viewing 9 posts - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.