Erle Robotics C++ GitBook

C++ and Erle-Brain

You should be able to run C++ programs in erleboard:

  • Create a file with the correcte extension .cpp, you can use vim text editor.
  • Use gcc to compile it.The syntax is the following:
    gcc filename.cpp -o executablename
    g++ filename.cpp -o executablename
  • Now you have an executable file executablename. Do ./executablename to compile it.


[email protected]:~/C++# ls
[email protected]:~/C++# gcc hello.cpp -o Hello
[email protected]:~/C++# ls
Hola  hello.cpp
[email protected]:~/C++#
[email protected]:~/C++# ./Hello
Hello World!