Classes | Public Member Functions | Static Public Member Functions | Static Protected Member Functions | Package Attributes | Static Package Attributes | Static Private Member Functions
edu.tum.cs.ias.knowrob.CopROSClient Class Reference

List of all members.

Classes

class  CopModelDBListenerThread
class  CopObjListenerThread
class  UpdateKnowRobModelDBThread
class  UpdateKnowRobObjectsThread

Public Member Functions

 CopROSClient (String node_name) throws InterruptedException, RosException, ExecutionException
void startCopModelDBListener (String cop_topic, String cop_service)
void startCopObjDetectionsListener (String cop_topic)

Static Public Member Functions

static String[] copModelTypeSemClassForID (long id)
static cop_answer copOneResult (cop_call.Request cop_req, String output_topic)
static HashMap< String, Vector
< Object > > 
executeQuery (String query)
static partial_lo loQuery (String command, String objName, int objID, int refFrame) throws RosException

Static Protected Member Functions

static String doubleArrayToPlList (double[] a)
static void initRos (String node_name)
static String objectArrayToPlList (Object[] a)

Package Attributes

Thread listenToCopDB
Thread listenToCopObjDetections
Thread updateKnowRobModelDB
Thread updateKnowRobObjDetections

Static Package Attributes

static
Subscriber.QueueingCallback
< cop_answer > 
copModelDBCallback
static
Subscriber.QueueingCallback
< cop_answer > 
copObjectDetectionsCallback
static NodeHandle n
static Ros ros
static Boolean rosInitialized = false

Static Private Member Functions

static String copToKnowrob (String copIdentifier)

Detailed Description

Definition at line 43 of file CopROSClient.java.


Constructor & Destructor Documentation

edu.tum.cs.ias.knowrob.CopROSClient.CopROSClient ( String  node_name) throws InterruptedException, RosException, ExecutionException [inline]

Client library for listening to CoP messages and asserting the object detections in KnowRob

Author:
tenorth@cs.tum.edu

Definition at line 65 of file CopROSClient.java.


Member Function Documentation

static String [] edu.tum.cs.ias.knowrob.CopROSClient.copModelTypeSemClassForID ( long  id) [inline, static]

encapsulate the CoP interaction (triggering an action by calling a service and listening on a topic for the results

Parameters:
idThe CoP ID to be queried for
Returns:
Array{modelType, semClass} for this CoP ID

Definition at line 475 of file CopROSClient.java.

static cop_answer edu.tum.cs.ias.knowrob.CopROSClient.copOneResult ( cop_call.Request  cop_req,
String  output_topic 
) [inline, static]

call CoP and return the first result published on the given response topic

Parameters:
cop_req
output_topic
Returns:

Definition at line 522 of file CopROSClient.java.

static String edu.tum.cs.ias.knowrob.CopROSClient.copToKnowrob ( String  copIdentifier) [inline, static, private]

Translate a CoP identifier into the corresponding KnowRob string. Uses the mapping defined in comp_cop.pl

Parameters:
copIdentifierThe name of something in CoP
Returns:
The name of the same thing in KnowRob

Definition at line 369 of file CopROSClient.java.

static String edu.tum.cs.ias.knowrob.CopROSClient.doubleArrayToPlList ( double[]  a) [inline, static, protected]

Definition at line 350 of file CopROSClient.java.

static HashMap<String, Vector<Object> > edu.tum.cs.ias.knowrob.CopROSClient.executeQuery ( String  query) [inline, static]

Wrapper around the JPL Prolog interface

Parameters:
queryA query string in common SWI Prolog syntax
Returns:
A HashMap<VariableName, ResultsVector>

Definition at line 425 of file CopROSClient.java.

static void edu.tum.cs.ias.knowrob.CopROSClient.initRos ( String  node_name) [inline, static, protected]

Thread-safe ROS initialization

Definition at line 100 of file CopROSClient.java.

static partial_lo edu.tum.cs.ias.knowrob.CopROSClient.loQuery ( String  command,
String  objName,
int  objID,
int  refFrame 
) throws RosException [inline, static]

Interface to the jlo service for coordinate transformations. Send a query to jlo to retrieve the transformation for a point in a given coordinate frame.

Parameters:
commandjlo query type: 'namequery' or 'framequery'
objNameif namequery: the name of the object to query for
objIDif framequery: the loID of the object to query for
refFrameif framequery: the loID of the desired parent frame the result should be returned in
Returns:
partial_lo with the coordinates of the desired lo object in the frame given by refFrame
Exceptions:
RosException

Definition at line 397 of file CopROSClient.java.

static String edu.tum.cs.ias.knowrob.CopROSClient.objectArrayToPlList ( Object[]  a) [inline, static, protected]

Convert a Java array into a Prolog list to be used in the string-based query interface

Parameters:
aThe array to be converted
Returns:
A Prolog list of the form ['a0', 'a1']

Definition at line 335 of file CopROSClient.java.

void edu.tum.cs.ias.knowrob.CopROSClient.startCopModelDBListener ( String  cop_topic,
String  cop_service 
) [inline]

Definition at line 75 of file CopROSClient.java.

Definition at line 85 of file CopROSClient.java.


Member Data Documentation

Subscriber.QueueingCallback<cop_answer> edu.tum.cs.ias.knowrob.CopROSClient.copModelDBCallback [static, package]

Definition at line 51 of file CopROSClient.java.

Subscriber.QueueingCallback<cop_answer> edu.tum.cs.ias.knowrob.CopROSClient.copObjectDetectionsCallback [static, package]

Definition at line 50 of file CopROSClient.java.

Definition at line 53 of file CopROSClient.java.

Definition at line 55 of file CopROSClient.java.

NodeHandle edu.tum.cs.ias.knowrob.CopROSClient.n [static, package]

Definition at line 47 of file CopROSClient.java.

Definition at line 46 of file CopROSClient.java.

Boolean edu.tum.cs.ias.knowrob.CopROSClient.rosInitialized = false [static, package]

Definition at line 45 of file CopROSClient.java.

Definition at line 54 of file CopROSClient.java.

Definition at line 56 of file CopROSClient.java.


The documentation for this class was generated from the following file:


comp_cop
Author(s): Moritz Tenorth
autogenerated on Mon Oct 6 2014 01:30:19