ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Building ROS Android applications [closed]

asked 2012-03-04 12:51:20 -0500

updated 2014-01-28 17:11:34 -0500

ngrennan gravatar image

I'm trying to learn to build an Android application using ROS. I've followed the instructions to create an app from: http://ros.org/wiki/ApplicationsPlatform/Clients/Android

I can build the application, but cannot run it. I have also tried building android_teleop and the other sample applications but cannot run them either. Rosmake seems to only generate jar files, not an apk package. How do I compile the result into an Android application?

I have also tried loading the resulting project in Eclipse and selecting Run as Android Application. This causes Eclipse to freeze and have to be force killed. I'm new to this and feel like I'm missing something pretty basic, but any suggestions would be appreciated.

EDIT: I tracked the main problem down to the fact that the jvm was running out of memory. Starting Eclipse with: 'eclipse -vmargs -Xmx512m' seems to fix the problem. Should starting an empty rosjava app require that much memory?

The app tries to start now but crashes with a java.lang.RuntimeException:

03-05 18:36:03.567: E/AndroidRuntime(347): java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{ros.android.is4s_ocu/ros.android.activity.AppChooserRedirectActivity}: java.lang.ClassNotFoundException: ros.android.activity.AppChooserRedirectActivity in loader dalvik.system.PathClassLoader[/data/app/ros.android.is4s_ocu-1.apk]

EDIT 2: I get a similar error running android_teleop.

03-05 18:54:13.827: E/AndroidRuntime(431): java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{ros.android.teleop/ros.android.teleop.Teleop}: java.lang.ClassNotFoundException: ros.android.teleop.Teleop in loader dalvik.system.PathClassLoader[/data/app/ros.android.teleop-2.apk]

I assume there is something not set correctly in my path, but do not know what. I have sourced setup.bash on the appmanandroid package and the Android SDK's are in my system path. Any suggestions?

Thanks,

David

edit retag flag offensive reopen merge delete

Closed for the following reason question is not relevant or outdated by tfoote
close date 2013-09-09 14:59:24

Comments

Hi, David! If you want I can upload image my virtual machine (VMware 8) in which all android sample projects are compiled. Size of VM is about 16 GB

Alexandr Buyval gravatar image Alexandr Buyval  ( 2012-03-04 18:04:44 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2012-03-14 21:06:01 -0500

Hi, I am also interested in building Android applications using ROS. I followed the instructions from http://answers.ros.org/question/2178/rosjavajar-missing-certain-packages#3713 But not able to build ROS android. Could you pls provide a step by step instructions to setup a working environment to develop ROS Android application?

Thanks in advance.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2012-03-04 12:51:20 -0500

Seen: 881 times

Last updated: Mar 14 '12