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. QT GUI (C++, C, QML) How to get file to work on raspberri pi 3
Forum Updated to NodeBB v4.3 + New Features

QT GUI (C++, C, QML) How to get file to work on raspberri pi 3

Scheduled Pinned Locked Moved Unsolved General and Desktop
8 Posts 4 Posters 1.1k Views 3 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.
  • S Offline
    S Offline
    slama10
    wrote on 18 Oct 2018, 20:38 last edited by
    #1

    Hi,

    I'm pretty new at this but I have developed a decent code using QT and I want to run it using raspberry pi 3 on a touch screen display.

    I'm using raspbian and am really new to this. Is there just an easy way to save the file on the raspberry memory card or call it from github and just have the code run?

    Any help is appreciated.

    Thank you

    1 Reply Last reply
    0
    • S Offline
      S Offline
      SGaist
      Lifetime Qt Champion
      wrote on 18 Oct 2018, 21:15 last edited by
      #2

      Hi and welcome to devnet,

      The most straightforward is to build your application directly on the Rpi3 using the Qt version provided by Raspbian.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      S 1 Reply Last reply 18 Oct 2018, 21:27
      3
      • S SGaist
        18 Oct 2018, 21:15

        Hi and welcome to devnet,

        The most straightforward is to build your application directly on the Rpi3 using the Qt version provided by Raspbian.

        S Offline
        S Offline
        slama10
        wrote on 18 Oct 2018, 21:27 last edited by
        #3

        @SGaist Thank you for your reply.

        Is it possible to transfer the file from my computer to the raspberry pi memory card then open it using QT version provided by raspbian? Because I already built the application.

        Thanks

        A J 2 Replies Last reply 19 Oct 2018, 03:41
        0
        • S slama10
          18 Oct 2018, 21:27

          @SGaist Thank you for your reply.

          Is it possible to transfer the file from my computer to the raspberry pi memory card then open it using QT version provided by raspbian? Because I already built the application.

          Thanks

          A Offline
          A Offline
          ambershark
          wrote on 19 Oct 2018, 03:41 last edited by
          #4

          @slama10 Did you build it for the Pi? It requires a cross compile since the architecture will be different than whatever you used on your desktop.

          You can transfer the files in a number of ways, personally I would use scp. Remember that if you built them with your normal desktop compiler, the binaries will not work on the Pi anyway.

          My L-GPL'd C++ Logger github.com/ambershark-mike/sharklog

          S 1 Reply Last reply 19 Oct 2018, 04:12
          3
          • A ambershark
            19 Oct 2018, 03:41

            @slama10 Did you build it for the Pi? It requires a cross compile since the architecture will be different than whatever you used on your desktop.

            You can transfer the files in a number of ways, personally I would use scp. Remember that if you built them with your normal desktop compiler, the binaries will not work on the Pi anyway.

            S Offline
            S Offline
            slama10
            wrote on 19 Oct 2018, 04:12 last edited by
            #5

            @ambershark I was able to do what @SGaist suggested and got QT creator on my raspberry pi. can I just email myself the code, download it on the raspberry, open it using qtcreator and run it? Will that work?

            Thanks for your help!

            A 1 Reply Last reply 19 Oct 2018, 04:13
            1
            • S slama10
              19 Oct 2018, 04:12

              @ambershark I was able to do what @SGaist suggested and got QT creator on my raspberry pi. can I just email myself the code, download it on the raspberry, open it using qtcreator and run it? Will that work?

              Thanks for your help!

              A Offline
              A Offline
              ambershark
              wrote on 19 Oct 2018, 04:13 last edited by
              #6

              @slama10 Sure, you just need to get the code on the Pi. You can use scp or any other method, email is fine too if you can access your email on the Pi. That's a lot of work just to copy some files though. ;)

              Once the code is on there you can build it in the Qt Creator on the Pi and run it there.

              My L-GPL'd C++ Logger github.com/ambershark-mike/sharklog

              1 Reply Last reply
              1
              • S slama10
                18 Oct 2018, 21:27

                @SGaist Thank you for your reply.

                Is it possible to transfer the file from my computer to the raspberry pi memory card then open it using QT version provided by raspbian? Because I already built the application.

                Thanks

                J Offline
                J Offline
                jsulm
                Lifetime Qt Champion
                wrote on 19 Oct 2018, 04:15 last edited by
                #7

                @slama10 said in QT GUI (C++, C, QML) How to get file to work on raspberri pi 3:

                Is it possible to transfer the file from my computer to the raspberry pi memory card then open it using QT version provided by raspbian?

                It's not that easy. Your PC has a x86_64 CPU, Raspberry Pi has an ARM CPU. You can't execute binaries for x86_64 on an ARM CPU. That means you need to build your app on your x86_64 PC but for ARM - this is called cross compilation (as @ambershark mentioned). For that take a look at https://wiki.qt.io/Raspberry_Pi_Beginners_Guide

                @SGaist suggested to build your app directly on your Pi. This is way easier than cross compilation, because you don't need to set up a cross compilation environment and cross compile Qt. Install compiler and Qt on your Pi, copy your source code to it and build.

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

                1 Reply Last reply
                3
                • S Offline
                  S Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on 19 Oct 2018, 18:56 last edited by
                  #8

                  As for copying your code, you have several solutions between rsync, scp, git, USB drive, etc.

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  1

                  1/8

                  18 Oct 2018, 20:38

                  • Login

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