Showing posts with label Remote Development. Show all posts
Showing posts with label Remote Development. Show all posts

Friday, February 26, 2016

Install Qt5/Qt Creator for Raspberry Pi 2/Raspbian Jessie


For Raspbian Jessie, qt5-default (Qt 5 development defaults package) is included in default repository. Here show how to install Qt5 and Qt Creator on Raspberry Pi 2 running frash new Raspbian Jessie, release 2016-02-09.

As my usual practice, update apt repository and firmware:
$ sudo apt-get update
$ sudo apt-get upgrade
$ sudo rpi-update

Then reboot if need.

Install xrdp, such than I can control Raspberry Pi remotely from Windows, and capture screen action.
$ sudo apt-get install xrdp

install qt5-default and qtcreator:
$ sudo apt-get install qt5-default
$ sudo apt-get install qtcreator


Once installed, you can run Qt Creator from desktop menu:
Menu > Programming > Qt Creator

or, enter the command in LXTerminal:
$ qtcreator

In my test, Qt Creator CANNOT run remotely from Windows using Microsoft Remote Desktop:


It can run locally:


And can run remotely from Windows using Putty/Xming:


As show in the videos, the code cannot be compiled with default setting caused by:
"Qt Creator needs a compiler set up to build. Configure a compiler in the kit options"

To fix it, refer to the above videos.

But, in my test, the compiler option cannot be saved, and I have to correct it every-time running Qt Creator.

Related:
- Same steps to Install Qt5/Qt Creator for Raspberry Pi 3/Raspbian Jessie


Saturday, October 17, 2015

Remote develop C/C++ program from Windows 10, run on Raspberry Pi, using NetBeans IDE

This post show how to develop C/C++ program on Netbeans IDE run on Windows 10, set up remote host on raspberry Pi. Such that you can run the program on Raspberry Pi remotely.




Local client host (the PC you used to develop):
Windows 10
Netbeans IDE 8.0.2 with C/C++ plugins (https://netbeans.org/community/releases/80/cpp-setup-instructions.html#downloading)
C/C++ compiler: 32-bit MinGW(https://netbeans.org/community/releases/80/cpp-setup-instructions.html#mingw)

Remote host (The target remote platform to run the program):
Raspberry Pi 2
Raspbian Jessie (2015-09-24)

Follow the steps in the video:



Test code, C++:
#include <iostream>

using namespace std;

int main(int argc, char** argv) {

    std::cout << "Hello World!\n";
    
#ifdef __linux__
    std::cout << "__linux__\n";
#elif defined(__unix__)
    std::cout << "__unix__\n";
#elif defined(_WIN64)
    std::cout << "Windows 64\n";
#elif defined(_WIN32)
    std::cout << "Windows 32\n";
#endif

#if __WORDSIZE == 64
    std::cout << "64 bit\n";
#else
    std::cout << "32 bit\n";
#endif

    return 0;
}

Reference:
https://netbeans.org/kb/docs/cnd/remote-modes.html
https://netbeans.org/kb/docs/cnd/remotedev-tutorial.html#setup

Related:
Remote run JavaFX on Raspbian Jessie, from Netbeans/Windows 10


Saturday, October 3, 2015