I'm trying to explore haptics using android via immersion sdk. (downloaded jar version= 3.6)
i have the following code (sample app provided by immersion)
protected TextView mTxtOut;
protected Launcher mLauncher;
public void onCreate(Bundle savedInstanceState) {
System.out.println("abc");
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
mTxtOut = (TextView)findViewById(R.id.txtOut);
try {
mLauncher = new Launcher(this);
} catch (Exception e) {
Log.e("My App", "Exception!: " + e.getMessage());
}
}
@Override
public void onDestroy() {
super.onDestroy();
}
public void btnPlayEffectClicked(View view) {
mTxtOut.setText("Playing built-in effect:\n. Effect: DOUBLE_STRONG_CLICK_100.");
try {
mLauncher.play(Launcher.DOUBLE_STRONG_CLICK_100);
} catch (Exception e) {
mTxtOut.append("Error: " + e.getMessage());
}
}
As soon as i launch the application, i get an error message "Unfortunately, MyFirstHapticApp has stopped".
I get the following exception "Could not find class com.immersion.uhl.Launcher referenced from method com.example.myfirsthapicapp.MyFirstHapticAppActivity.onCreate" at line mLauncher = new Launcher(this); in LogCat.
I've looked at http://www2.immersion.com/developers/index.php?option=com_kunena&func=view&catid=2&id=170&Itemid=0 but was not helpful.