Details
- Tested with l_cembd_p_2018.0.050
- Linux* host build
- Requires CMake on the host
Purpose
Build a project from Arduino Create* in Intel® System Studio (with CMake Makefile generation).
- Export a project from Arduino Create*
- Extract the provided zip file
- Generate the Eclipse* Makefile/.cproject/.project files
- Import the build directory into Intel® System Studio
- Build/debug
Note: For libraries that are dynamically linked in Arduino Create, these libraries must be installed in the docker container in Intel System Studio for this to work.
Exporting a Project from Arduino Create*
The following sample was used: https://github.com/intel-iot-devkit/up-squared-grove-IoTdev-kit-arduino-create/tree/master/examples/Blink using the provided Export flow, save off a CMake-based project archived to a zip file (in this case: arduino_create-cmake.zip).
Generate the Eclipse* CDT Project for Intel® System Studio
- First, extract the CMake zip
unzip arduino_create-cmake.zip -d iss_example_Blink
- Run CMake to generate the CDT Project
cmake -G "Eclipse CDT4 - Unix Makefiles" -DCMAKE_BUILD_TYPE=Debug -Biss_example_Blink/build -Hiss_example_Blink/_cmake
Import the project into Intel® System Studio
Build and Debug
- Set a breakpoint in the sketch.
- Build the project. Make sure to save prior to building! A successful build will place a debug binary in the Project Explorer (below as examples_Blink -[x86_64]).
- Debug the project - examples_Blink (1)
- Hit Resume (F8) one time to continue from main.cpp to the sketch breakpoint.