Use this guide to get started with your embARC OSP development.
Checking Out the embARC OSP source code¶
The embARC OSP source code is hosted in a GitHub repository that supports cloning via git. There are scripts and such in this repo that you’ll need to set up your development environment, and we’ll be using Git to get this repo. If you don’t have Git installed, please refer to the beginning of the host OS-specific getting started instructions below for help.
We’ll begin by using Git to clone the repository anonymously.
# On Windows cd %userprofile% # On Linux cd ~ git clone https://github.com/foss-for-synopsys-dwc-arc-processors/embarc_osp.git embarc_osp
You have successfully checked out a copy of the source code to your local machine.
If you are not familiar with git or git doesn’t work, you can also download the embARC OSP code through http. The latest release of embARC OSP is here.
Setting Up the Development Environment¶
The embARC OSP platform supports, but not limited to, the following development machine operating systems:
Microsoft Windows 10 / Windows 7
Use the following procedure to create a new development environment
The embARC OSP uses make/gmake as a build tool and these are provided as part of the ARC development tools.
Building a Sample Application¶
blinky example, the following steps, which contains the commands
used for the ARC GNU toolchain in a Windows environment, will describe how
to build an embARC OSP application. Please use the
appropriate commands for your OS.
Make sure the ARC GNU toolchain is installed in your environment, see Software Requirement.
Navigate to Blinky example located at embARC OSP directory.
Build the Blinky example for the EMSK 2.3 board and ARC EM11D.
make TOOLCHAIN=gnu BOARD=emsk BD_VER=23 CUR_CORE=arcem11d
make for ARC GNU toolchain, gmake for MetaWare toolkit. For more details of commands, see Makefile Manual
Use the following procedures to prepare your ARC board to run/debug the embARC applications.
See the following procedures to check peripherals and board settings. The peripherals are not required for all the embARC OSP examples.
Running a Sample Application¶
Follow these steps to run the sample application.
Make sure the blinky example has been built successfully in Building a Sample Application. Get the .elf file
Follow to steps in Programming and Debugging to set and connect EMSK 2.3 with EM11D to your local machine.
Navigate to the embARC OSP directory and run Blinky example.
cd embarc_osp\example\baremetal\blinky make TOOLCHAIN=gnu BOARD=emsk BD_VER=23 CUR_CORE=arcem11d run
No peripheral modules are required to run the
blinky example. If there are LEDs on boards, these LED will be used to blink; If there are no LEDs on boards, a blink message will be output in the UART.
See the following manual for information on make/gmake command and embARC makefile system.