0

I'm facing the following problem while developing to Tango and not sure whether I'm on the right track for solution or not.

What I'm trying to do(in short): serializing a point cloud(TangoPointCloudData object) and pose(TangoPoseData object) into a file for later use. Doing some magic processing behind the scene in order to calc some object's coordinates(x and y), Then - reconnect the tango and show a 3d object at x,y.

I'm initializing the Tango object by frame pair SOS and FD(frame device).

The exception occurs when I'm invoking this line with the latest TangoPointCloudData + TangoPoseData on the new Tango session:

TangoSupport.calculateRelativePose(
                0.0,
                TangoPoseData.COORDINATE_FRAME_CAMERA_COLOR, pointCloud.timestamp,
                TangoPoseData.COORDINATE_FRAME_CAMERA_DEPTH);

The very non informative log I'm getting is:

com.google.atap.tangoservice.TangoErrorExceptioncom.google.atap.tangoservice.Tago.throwTangoExceptionIfNeeded(Tango.java:958)
com.projecttango.tangosupport.TangoSupport.calculateRelativePose(TangoSupport.java:231)

Thats all.

Tango core version I'm developing on is 1.44.2016.09.19-wasat-release.

My intuition is that the problem might occur because I didn't save the data correctly or it got ruined somewhere in the code, didn't init Tango correctly or trying to use an old xyzIj object on a new Tango session. I rechecked every thing(except the last which might be the problem(?)) and couldn't find something wrong so trying to address my thread to the great StackOverflow community.

Nativ
  • 3,092
  • 6
  • 38
  • 69

1 Answers1

1

The second timestamp (targetTimestamp) you pass to the method TangoSupport.calculateRelativePose needs to be a valid time stamp in the current Tango session. If I understand correctly, the timestamp xyzIj.timestamp is from a previous Tango session (?).

More general, the Tango device by default does not store any area knowledge gained in previous sessions. To insert result from a previous Tango session into the current session, either the device needs to automatically relocate itself by loading a area learned (area learning), or the user needs to manually align the result with the new Tango reference frame.