# Unable to run code from my Processing window on my Android device

**URL:** https://discourse.processing.org/t/unable-to-run-code-from-my-processing-window-on-my-android-device/38643
**Category:** Processing for Android
**Created:** [September 4, 2022, 5:01pm UTC](https://discourse.processing.org/t/unable-to-run-code-from-my-processing-window-on-my-android-device/38643 "2022-09-04T17:01:39Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![TobiS137](https://avatars.discourse-cdn.com/v4/letter/t/82dd89/32.png) [@TobiS137](https://discourse.processing.org/u/TobiS137)
#### Post date: [September 4, 2022, 5:01pm UTC](https://discourse.processing.org/t/unable-to-run-code-from-my-processing-window-on-my-android-device/38643/1 "2022-09-04T17:01:39Z")

</div>

Hello!

I am very new to Processing for Android, and I am actually having problems even running my first test sketch on my Physical device. Just to clear some things up, I am using a OnePlus 9 Pro device, with USB debugging turned on in developer settings. The device is showing up in the Android → Devices tab in processing, and my device has registered the computer (A surface laptop 4 running windows 11) attempting to use the USB debugging. I have allowed it to do so on the phone.

I have installed the Android mode for Processing version 3.5.4, and let processing auto-install the android SDK when it asked if it was allowed to. This was done successfully.

The Error I am getting happens when I attempt to run code from the editor on the phone. I get a little error with the text “Build Failed.” and a whole load of red errors in the output. The first lines of the error look as follows:

"FAILURE: Build failed with an exception.

- What went wrong:  
Could not determine the dependencies of task ‘:app:compileDebugJavaWithJavac’.

> Failed to install the following SDK components:  
> build-tools;29.0.2 Android SDK Build-Tools 29.0.2  
> Install the missing components using the SDK manager in Android Studio."

Looking at the error I attempted to do what it told me to (Installing Build Tools 29.0.2 in android Studio using the SDK manager.) and after a system restart, I still seem to get the same error.

Any help here would be greatly appreciated. As mentioned earlier I am very new at both processing and android app-related topics, but I will try my best to give any info I may be asked about.

---

<div class="post-metadata">

### Author: ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)
#### Post date: [September 4, 2022, 6:54pm UTC](https://discourse.processing.org/t/unable-to-run-code-from-my-processing-window-on-my-android-device/38643/2 "2022-09-04T18:54:51Z")

</div>

You might want to try Processing version 4.0.1 to see if you have the same problem. On a Mac the Build Tools are in Library/Android/sdk/build-tools folder. Others will know more about Windows operating system.

---

<div class="post-metadata">

### Author: ![Rupesh\_Kumar](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/rupesh_kumar/32/12638_2.png) [@Rupesh\_Kumar](https://discourse.processing.org/u/Rupesh_Kumar)
#### Post date: [September 24, 2022, 9:10pm UTC](https://discourse.processing.org/t/unable-to-run-code-from-my-processing-window-on-my-android-device/38643/3 "2022-09-24T21:10:24Z")

</div>

You might be missing the SDK at the location which is being used by the sketch, to confirm the SDK location being used, you can export the sketch from `File-> Export Android Project` and then check the local.properties file in the exported project location.  
I would recommend using the newer versions of Processing 4 and Android Mode.

Thanks,  
Rupesh

---

<div class="post-metadata">

### Author: ![Mukka](https://avatars.discourse-cdn.com/v4/letter/m/e68b1a/32.png) [@Mukka](https://discourse.processing.org/u/Mukka)
#### Post date: [September 28, 2022, 12:38pm UTC](https://discourse.processing.org/t/unable-to-run-code-from-my-processing-window-on-my-android-device/38643/4 "2022-09-28T12:38:43Z")

</div>

Hello! TobiS137,  
I am also starting to processing for android but recently my PC got crashed. Now i need a laptop for doing this. can you suggest me a laptop for me? I want to buy the HP Victus Gaming laptop this variant [https://computermania.com.bd/product/hp-victus-15-price-in-bd/](https://computermania.com.bd/product/hp-victus-15-price-in-bd/)  
is this variant could make the work? can you help me please?

---

<div class="post-metadata">

### Author: ![jafal](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/jafal/32/19112_2.png) [@jafal](https://discourse.processing.org/u/jafal)
#### Post date: [September 28, 2022, 3:29pm UTC](https://discourse.processing.org/t/unable-to-run-code-from-my-processing-window-on-my-android-device/38643/5 "2022-09-28T15:29:30Z")

</div>

> [@Mukka](#):
>
> is this variant could make the work? can you help me please?

Hi  
The laptop you provide at the link very suitable for processing android
