Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. external links
Qt 6.11 is out! See what's new in the release blog

external links

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 3 Posters 1.8k Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    Bob W
    wrote on last edited by
    #1

    I am trying to upgrade an existing and working c program that communicates to a device via usbhid program.
    I have all the QT GUI stuff working fine, but now I need to add the additional links to all the usb programs.
    It is open source, so I can see all the code.
    I tracked back all the links and libraries needed and get NO errors.
    I also get no verified communications.
    I recreated the header files directly in the QT headers and copy/pasted the code just to make it part of the code instead of a link.

    Any suggestions on the proper linking and debugging to verify?

    I know this is vague, but I am looking more about QT style and prefered programming for C++.

    jsulmJ 1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by mrjj
      #2

      Hi
      Not sure what you are after so forgive if total miss :
      You can add external files via the .pro file.
      note the ALLPO paths. ( its sample so bit ugly)
      those points to a folder above the project folder with some common files.
      It could be anywhere on your PC. But it will get messy soon :)
      And then i would set some breakpoints into the "old" code at
      critical functions and see if all get up and running.

      SOURCES += main.cpp\
          mainwindow.cpp \
          pxstyler.cpp \  
          ../AllPO/Source/Common/Platform/Trace/Terminal.cpp \
       ...
      HEADERS  += mainwindow.h \
          configuration_dialog.h \
          ../AllPO/Source/Common/Platform/Trace/Trace.h \
      ....
      INCLUDEPATH += $$PWD/../AllPO/Source/Common/Platform/Trace \
          $$PWD/../AllPO/Source/Common/Platform/Trace \
      ....
      
      1 Reply Last reply
      0
      • B Bob W

        I am trying to upgrade an existing and working c program that communicates to a device via usbhid program.
        I have all the QT GUI stuff working fine, but now I need to add the additional links to all the usb programs.
        It is open source, so I can see all the code.
        I tracked back all the links and libraries needed and get NO errors.
        I also get no verified communications.
        I recreated the header files directly in the QT headers and copy/pasted the code just to make it part of the code instead of a link.

        Any suggestions on the proper linking and debugging to verify?

        I know this is vague, but I am looking more about QT style and prefered programming for C++.

        jsulmJ Offline
        jsulmJ Offline
        jsulm
        Lifetime Qt Champion
        wrote on last edited by
        #3

        @Bob-W said in external links:

        I also get no verified communications.

        If I understand you correctly you already can build your app with UI and that C code, right? So, you have an executable? But the communication does not work? In this case you need to debug your app to see what happens. Does your UI already call this C stuff?

        https://forum.qt.io/topic/113070/qt-code-of-conduct

        B 1 Reply Last reply
        0
        • jsulmJ jsulm

          @Bob-W said in external links:

          I also get no verified communications.

          If I understand you correctly you already can build your app with UI and that C code, right? So, you have an executable? But the communication does not work? In this case you need to debug your app to see what happens. Does your UI already call this C stuff?

          B Offline
          B Offline
          Bob W
          wrote on last edited by
          #4

          @jsulm
          NO, I already have a terminal based c program that works fine.
          Now I want to transfer the functionality to QT for the GUI interface.

          I have a #include " program.h" in the main program that does not trigger a break in the program.h in the headers.

          jsulmJ 1 Reply Last reply
          0
          • B Bob W

            @jsulm
            NO, I already have a terminal based c program that works fine.
            Now I want to transfer the functionality to QT for the GUI interface.

            I have a #include " program.h" in the main program that does not trigger a break in the program.h in the headers.

            jsulmJ Offline
            jsulmJ Offline
            jsulm
            Lifetime Qt Champion
            wrote on last edited by
            #5

            @Bob-W said in external links:

            I have a #include " program.h" in the main program that does not trigger a break in the program.h in the headers.

            It's not enough to include the header - you should use that code. For me its not clear what you did and what does not work.

            https://forum.qt.io/topic/113070/qt-code-of-conduct

            1 Reply Last reply
            0

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved