Getting "Cannot resolve symbol RobotActivity" with QiSDK

Viewed 666

I am trying to get my pepper robot to perform some simple speech tasks. I can follow the tutorial all the way up to "Creating a robot application". It seems like step 2 where you "robotify" the application is not working correctly. It creates a file called robotsdk.xml in the assets/robot directory but did not do any other modifications as mentioned in the tutorial. When I copy the example code at the bottom of the tutorial into MainActivity.java I get the error in the title.

here's a link to the tutorial.

https://qisdk.softbankrobotics.com/sdk/doc/pepper-sdk/ch1_gettingstarted/starting_project.html

I have tried following the tutorial on a Windows 10 machine and a Linux machine and I get the same problem.

I am able to connect to the robot and slightly move the limbs around using the "Connect" button in the Pepper SDK in Android Studio.

2 Answers

The class RobotAcitivity is part of the QiSDK dependency. You have to ensure that your build.gradle file contains the line (should happen automatically in step 2)

implementation 'com.aldebaran:qisdk:1.6.7'

Also make sure that gradle downloaded all dependencies successfully before running the application.

In the built.gradle, please add

allprojects {
repositories {
    google()
    jcenter()
    maven {
        url 'http://android.aldebaran.com/sdk/maven'
    }
}

}

Related