## Set up Qt 4.8.x on Pi

I really love Qt, so one of the first things I wanted to do is to get my Qt application running on raspberry Pi.
The QtOnPi didn't work for me, because it is using Qt5, but my apps require good old Qt 4 desktop widgets. But what I understand it is possible to port it to Qt5

However, QtonPi has a massive advantage, you can set up a virtual enviorement on your linux PC, compile your Qt5 app on it, and it will automatically upload and run it on your Pi. As I said, I needed Qt 4, so I will just be leaving here notes for my self about Qt 4.

To install Qt it's pretty straight forward:

pacman -S qt

To compile your Qt app first make a makefile

qmake -o YourProFileHere.Pro

And then just run make, it will take a while and might crash several times, so you will have to do some small tweaking in your code.

For me two problems I encountered was in class header file I had defined every function with it's namespace in front of it, for x86 system it didn't bother, and in QCustomGraph library he is sending to qMax two diferent types of data varialables one is float and the other one double. Just wrap them bout in double() or float(). And you Sir have compiled your Qt app on arm architecture.

To run your app just write ./NameOfYourApp

### Related Articles

• #### Implementing pulse oximeter using MAX30100

Mar 8, 2017 | by Raivis Strogonovs
• #### nRF51 Makefile with Qt Creator

Jun 4, 2016 | by Raivis Strogonovs
• #### USART, FreeRTOS and C++ on nRF51

Dec 14, 2015 | by Raivis Strogonovs
• #### Starting with nRF51 BLE and Qt Creator

Dec 12, 2015 | by Raivis Strogonovs
• #### Touch gesture recognition using body capacitance

Nov 29, 2014 | by Raivis Strogonovs
• #### Introduction to data encryption

Oct 4, 2014 | by Raivis Strogonovs
• #### MEMS (Part 2) – Guide to using gyroscope L3G4200D

Jun 17, 2014 | by Raivis Strogonovs
• #### Harold Burton in LXDE on Raspberry PI Arch Linux

Never watched this video, I predicted Super Mario World at #1! And LITERALLY just as I was typing this, Super Mario World was #2? I'm actually surprised by WatchMojo this time! After that though I knew a Zelda game was #1 and I'm not surprised by that at all! Also no Kirby...

#### Harold Burton in LXDE on Raspberry PI Arch Linux

Never watched this video, I predicted Super Mario World at #1! And LITERALLY just as I was typing this, Super Mario World was #2? I'm actually surprised by WatchMojo this time! After that though I knew a Zelda game was #1 and I'm not surprised by that at all! Also no Kirby...

#### Small Cardboard Boxes in Starting with nRF51 BLE and Qt Creator

Custom Packaging Boxes carries a large variety of printed cardboard boxes, including paper, plastic and small cardboard boxes for shipping, storage, and more! Our selection of <a...

#### Caique Lima in Implementing pulse oximeter using MAX30100

Hello, Bogdan. did you have any success with that?

#### Caique Lima in Implementing pulse oximeter using MAX30100

Hello, Raivis. Thanks for the tutorial. Could you post the code .ino which results the figure 14?

#### Caique Lima in Implementing pulse oximeter using MAX30100

Hello, Raivis. Thanks for the tutorial. Could you post the code .ino which results the figure 14?

#### Caique Lima in Implementing pulse oximeter using MAX30100

Hello, Raivis. Thanks for the tutorial. Could you post the code .ino which results the figure 14?