## 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
• #### DJXIA in Implementing pulse oximeter using MAX30100

same problem here

#### Fabian Rios in Implementing pulse oximeter using MAX30100

I Sorry, when I click on "Submit Comment" say me error, and I try again, try again... I sorry for the replies

#### Fabian Rios in Implementing pulse oximeter using MAX30100

Hi Raivis or some person, I download all inside the folder with the .ino ok but de led of my board no go on, the monitor put all the time 19:58:20.999 ->  2debug=true...

#### Fabian Rios in Implementing pulse oximeter using MAX30100

Hi Raivis or some person, I download all inside the folder with the .ino ok but de led of my board no go on, the monitor put all the time 19:58:20.999 ->  2debug=true...

#### Fabian Rios in Implementing pulse oximeter using MAX30100

Hi Raivis or some person, I download all inside the folder with the .ino ok but de led of my board no go on, the monitor put all the time 19:58:20.999 ->  2debug=true...

#### Fabian Rios in Implementing pulse oximeter using MAX30100

Hi Raivis, or some person, I download all inside the folder with the .ino ok but de led of my board no go on, the monitor put all the...

#### Epson printer error code 0xf1 in nRF51 Makefile with Qt Creator

This is a very good post which I really enjoy reading. It is not every day that I have the possibility to see something like this. Epson printer error code...