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. How to include pico-sdk in Qt
Forum Updated to NodeBB v4.3 + New Features

How to include pico-sdk in Qt

Scheduled Pinned Locked Moved Solved General and Desktop
6 Posts 3 Posters 2.2k Views 1 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.
  • J Offline
    J Offline
    jenya7
    wrote on 16 Dec 2021, 10:55 last edited by jenya7
    #1

    It's a quite specific question but may be someone can help me.
    I installed pico-sdk on Raspbian (/home/pi/pico/pico-sdk). How can I include it in Qt IDE?
    Inside a lot of folders and I see no include folder I can refer.

    J 1 Reply Last reply 16 Dec 2021, 12:02
    0
    • J jenya7
      16 Dec 2021, 10:55

      It's a quite specific question but may be someone can help me.
      I installed pico-sdk on Raspbian (/home/pi/pico/pico-sdk). How can I include it in Qt IDE?
      Inside a lot of folders and I see no include folder I can refer.

      J Offline
      J Offline
      jsulm
      Lifetime Qt Champion
      wrote on 16 Dec 2021, 12:02 last edited by
      #2

      @jenya7 This Pico-SDK is a C/C++ SDK. A collection of libraries and CMake files. So, you can use it like any other C/C++ framework.
      Read its documentation:

      • https://github.com/raspberrypi/pico-sdk
      • https://datasheets.raspberrypi.com/pico/raspberry-pi-pico-c-sdk.pdf
        Looks like you will need to use CMake as build system which is also supported by Qt (https://doc.qt.io/qt-5/cmake-manual.html).

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

      J 1 Reply Last reply 16 Dec 2021, 12:29
      0
      • J jsulm
        16 Dec 2021, 12:02

        @jenya7 This Pico-SDK is a C/C++ SDK. A collection of libraries and CMake files. So, you can use it like any other C/C++ framework.
        Read its documentation:

        • https://github.com/raspberrypi/pico-sdk
        • https://datasheets.raspberrypi.com/pico/raspberry-pi-pico-c-sdk.pdf
          Looks like you will need to use CMake as build system which is also supported by Qt (https://doc.qt.io/qt-5/cmake-manual.html).
        J Offline
        J Offline
        jenya7
        wrote on 16 Dec 2021, 12:29 last edited by jenya7
        #3

        @jsulm
        I was hoping I can work with it like with a library.
        For example I install

        sudo apt-get install libgpiod-dev

        and the I add in Qt

        LIBS += -lgpiod

        And I work and compile from Qt.

        In the getting started document it explained how to build from a command line. I'd love to integrate it in Qt.

        If I provide all paths like

        LIB+= "/pico-sdk/hardware_timer"
        

        it's c and h files eventually. It can be build with Qt build like other sources, I think...

        My doubt how this get compiled

        #define uart0_hw ((uart_hw_t *const)UART0_BASE)
        #define uart1_hw ((uart_hw_t *const)UART1_BASE)
        

        It's actually real registers pointers.

        P 1 Reply Last reply 16 Dec 2021, 13:27
        0
        • J jenya7
          16 Dec 2021, 12:29

          @jsulm
          I was hoping I can work with it like with a library.
          For example I install

          sudo apt-get install libgpiod-dev

          and the I add in Qt

          LIBS += -lgpiod

          And I work and compile from Qt.

          In the getting started document it explained how to build from a command line. I'd love to integrate it in Qt.

          If I provide all paths like

          LIB+= "/pico-sdk/hardware_timer"
          

          it's c and h files eventually. It can be build with Qt build like other sources, I think...

          My doubt how this get compiled

          #define uart0_hw ((uart_hw_t *const)UART0_BASE)
          #define uart1_hw ((uart_hw_t *const)UART1_BASE)
          

          It's actually real registers pointers.

          P Offline
          P Offline
          Pablo J. Rogina
          wrote on 16 Dec 2021, 13:27 last edited by
          #4

          @jenya7 said in How to include pico-sdk in Qt:

          I was hoping I can work with it like with a library.

          It looks like to me that you might be mixing things here.

          From the pico-sdk github site:
          The Raspberry Pi Pico SDK (henceforth the SDK) provides the headers, libraries and build system necessary to write programs for the RP2040-based devices such as the Raspberry Pi Pico in C, C++ or assembly language.

          And I'm not aware that there's a port of Qt framefork for such MCU architecture yet, so having a Qt app running on Raspberry Pico is unlikely...

          However, if you only plan to use Qt Creator as the IDE to develop RP2040 specific applications, then I'd say to look at the Bare Metal option while configure a kit for such devices.

          Upvote the answer(s) that helped you solve the issue
          Use "Topic Tools" button to mark your post as Solved
          Add screenshots via postimage.org
          Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

          J 1 Reply Last reply 16 Dec 2021, 15:12
          0
          • P Pablo J. Rogina
            16 Dec 2021, 13:27

            @jenya7 said in How to include pico-sdk in Qt:

            I was hoping I can work with it like with a library.

            It looks like to me that you might be mixing things here.

            From the pico-sdk github site:
            The Raspberry Pi Pico SDK (henceforth the SDK) provides the headers, libraries and build system necessary to write programs for the RP2040-based devices such as the Raspberry Pi Pico in C, C++ or assembly language.

            And I'm not aware that there's a port of Qt framefork for such MCU architecture yet, so having a Qt app running on Raspberry Pico is unlikely...

            However, if you only plan to use Qt Creator as the IDE to develop RP2040 specific applications, then I'd say to look at the Bare Metal option while configure a kit for such devices.

            J Offline
            J Offline
            jenya7
            wrote on 16 Dec 2021, 15:12 last edited by
            #5

            @Pablo-J-Rogina
            Yeah. But today with Qt I operate WIFI and BLE modules on Raspberry Pi. It also operates GPIO (hardware pins) with a third party lib. So I wouldn't be surprised if it works with Pico SDK headers and libraries.

            P 1 Reply Last reply 16 Dec 2021, 15:26
            0
            • J jenya7
              16 Dec 2021, 15:12

              @Pablo-J-Rogina
              Yeah. But today with Qt I operate WIFI and BLE modules on Raspberry Pi. It also operates GPIO (hardware pins) with a third party lib. So I wouldn't be surprised if it works with Pico SDK headers and libraries.

              P Offline
              P Offline
              Pablo J. Rogina
              wrote on 16 Dec 2021, 15:26 last edited by
              #6

              @jenya7 said in How to include pico-sdk in Qt:

              It looks like you're still missing the concept of Qt supported platforms, and processor architectures (x86, x86_64, x86, armv7, armv8, etc.)

              But today with Qt I operate WIFI and BLE modules on Raspberry Pi. It also operates GPIO (hardware pins) with a third party lib

              Yes, because the Qt framework (most of its modules) were ported to platform (Linux) and architecture (armv7, armv8)
              Please be aware that you're talking about Raspberry Pi devices here.

              So I wouldn't be surprised if it works with Pico SDK headers and libraries.

              Once again, the Pico SDK is intended for writing applications to run on RP2040 microcontrollers, please read the documentation.
              And be surprised, there's no Qt framework port for such architecture yet.

              Upvote the answer(s) that helped you solve the issue
              Use "Topic Tools" button to mark your post as Solved
              Add screenshots via postimage.org
              Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

              1 Reply Last reply
              1

              1/6

              16 Dec 2021, 10:55

              • Login

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