> For the complete documentation index, see [llms.txt](https://sdk.twelite.info/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://sdk.twelite.info/en/twelite-sdk-howto/komandoraindenobirudo.md).

# How to build from the command line

## How to build by command line

{% hint style="info" %}
When using VSCode, the command line is called from within VSCode, so you do not need to be aware of the following steps.
{% endhint %}

### preparation in advance

Make sure you have the command line make utility ready to run.

{% hint style="warning" %}
The following explanation assumes that the bash command line is used.
{% endhint %}

#### Windows

Use the BASH (by msys) attached to the SDK.

Run the BASH.CMD located in {MWSDK installation folder} from Explorer, and you will see the bash command line with the Wks\_TWELITE workspace as the current folder. Set the PATH to the toolchain for the TWELITE SDK.

```bash
user1@MACHINE_NAME   /c/MWSDK/Wks_TWELITE
$ pwd
/c/MWSDK/Wks_TWELITE

$ ls
App_IO  App_Tag  Samp_PER  Samp_Wayback
App_Melody  
...
```

#### macOS

If an error occurs when executing make on the command line (bash), install XCode.

```c
$ xcode-select --install
```

After installation is complete, type "make" and the following message should appear.

```c
$ make
make: *** No targets specified and no makefile found.  Stop.
```

### Build

Let's build Samp\_PingPong as an example.

First, go to the build folder of the build project Samp\_PingPong.

```bash
$ pwd
/c/MWSDK/Wks_TWELITE
$ cd Samp_PingPong/PingPong/Build/
$ pwd
/c/MWSDK/Wks_TWELITE/Samp_PingPong/PingPong/Build/
```

The next step is to run clean. Here is an example of running clean on a TWELITE BLUE build.

```
$ make TWELITE=BLUE clean
../../../../MkFiles/chipsel.mk:36: "WARNING: TWELITE BLUE"
```

{% hint style="info" %}
When running make, you must specify either TWELITE=BLUE or TWELITE=RED, and you will get a WARNING to indicate that this is a TWELITE BLUE build, not a problem. To clean the Build folder without running make, delete the .bin file and objs\_\* folder in the Build folder.
{% endhint %}

Once clean is done, run the build.

```bash
$ make TWELITE=BLUE
rm -f objs_BLUE/PingPong.o
mkdir -p objs_BLUE
Compiling /c/MWSDK/Wks_TWELITE/Samp_PingPong/Pi..
...
/c/MWSDK/ChipLib/SW4063V1416/../../Tools/ba-elf-ba2-r..
y -S -O binary objs_BLUE/Samp_PingPong_PingPong_BLUE_..
Samp_PingPong_PingPong_BLUE_L1200_V0-1-4.bin

$ ls *.bin
Samp_PingPong_PingPong_BLUE_L1200_V0-1-4.bin
```

{% hint style="info" %}
If the [`.bin`](/en/twelite-sdk-howto/birudonitsuite/binfuiru.md) file is created after the build is executed, it is successful. If the build does not succeed, you will get some error messages.

The intermediate files are stored in the `objs_{ARCH}` folder.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://sdk.twelite.info/en/twelite-sdk-howto/komandoraindenobirudo.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
