getting_started:write_app:use_on_bbb
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| getting_started:write_app:use_on_bbb [2021/03/31 10:12] – [Writing EEROS Applications for Beaglebone Blue Board] ursgraf | getting_started:write_app:use_on_bbb [2024/11/07 12:25] (current) – [Say Hello with EEROS] ursgraf | ||
|---|---|---|---|
| Line 4: | Line 4: | ||
| You will use C++ to develop your EEROS applications. For this you need at least some knowledge of the basic language features. A good starting point might be [[https:// | You will use C++ to develop your EEROS applications. For this you need at least some knowledge of the basic language features. A good starting point might be [[https:// | ||
| + | All the necessary libraries are already on our images, notably eeros, librobotcontrol and bbblue-eeros. | ||
| What do you want to do next? | What do you want to do next? | ||
| Line 11: | Line 12: | ||
| ===== Say Hello with EEROS ===== | ===== Say Hello with EEROS ===== | ||
| - | - Fetch the [[https:// | ||
| - | $ git clone https:// | ||
| - | $ cd eeros-project | ||
| - | $ git checkout sdk_bbb | ||
| - | </ | ||
| - | - Edit the file '' | ||
| - | custom_application=hello | ||
| - | </ | ||
| - Create a project directory and change into it with < | - Create a project directory and change into it with < | ||
| $ mkdir hello | $ mkdir hello | ||
| Line 40: | Line 33: | ||
| </ | </ | ||
| - Create a text file " | - Create a text file " | ||
| - | cmake_minimum_required(VERSION 3.5.1) | + | cmake_minimum_required(VERSION 3.10) |
| project(helloworld) | project(helloworld) | ||
| set(CMAKE_CXX_STANDARD 14) | set(CMAKE_CXX_STANDARD 14) | ||
| - | |||
| find_package(EEROS REQUIRED) | find_package(EEROS REQUIRED) | ||
| - | include_directories(${EEROS_INCLUDE_DIR}) | ||
| - | link_directories(${EEROS_LIB_DIR}) | ||
| add_executable(helloworld main.cpp) | add_executable(helloworld main.cpp) | ||
| - | target_link_libraries(helloworld eeros ucl ${CMAKE_DL_LIBS}) | + | target_link_libraries(helloworld |
| </ | </ | ||
| - | - Change back into your parent | + | - Create a build directory and change into it with < |
| - | $ cd .. | + | $ mkdir build-armhf |
| - | $ ./make.sh | + | $ cd build-armhf |
| + | </ | ||
| + | - Source | ||
| + | $ . ~/ | ||
| + | </ | ||
| + | - Build the project with < | ||
| + | $ cmake .. | ||
| + | $ make | ||
| </ | </ | ||
| - Make changes to " | - Make changes to " | ||
| - | $ ./make.sh | + | $ make |
| </ | </ | ||
| Line 64: | Line 61: | ||
| ===== Use Existing Project ===== | ===== Use Existing Project ===== | ||
| As an example we use the [[getting_started: | As an example we use the [[getting_started: | ||
| - | - Edit the file '' | + | - Clone the code for the project, change into the directory and checkout a stable version with< |
| - | custom_application=simple-motor-control | + | $ git clone https:// |
| + | $ cd simple-motor-control | ||
| + | $ git checkout v1.0.0 | ||
| </ | </ | ||
| - | - Fetch the code of the application | + | - Create a build directory and change into it with < |
| - | $ ./clone.sh | + | $ mkdir build-armhf |
| + | $ cd build-armhf | ||
| </ | </ | ||
| - | - Build the project with < | + | |
| - | $ ./make.sh | + | $ . ~/ |
| + | </ | ||
| + | $ cmake -DUSE_BBBLUE=TRUE | ||
| + | $ make | ||
| </ | </ | ||
| Continue with [[getting_started: | Continue with [[getting_started: | ||
getting_started/write_app/use_on_bbb.1617178359.txt.gz · Last modified: 2021/03/31 10:12 by ursgraf