logo logo
Inicio arrow Foros...
Saturday, 22 de November de 2008
 
 
English English  Español Español  
Próximos Eventos
10.Jun. 2009

IWANN 2009
Salamanca, Spain
International Work-Conference on Artificial Neural Networks
11.Jun. 2009

Toward a Science of Consciousness
Hong Kong, China
15.Jun. 2009

International Workshop on Machine Consciousness
Hong Kong, China
15.Jun. 2009

The 8th IEEE International Conference on Cognitive Informatics
Hong Kong, China
22.Jun. 2009

IWINAC 2009
Santiago de Compostela, Spain
Work-Conference in the Interplay between Natural and Artificial Computation
Etiquetas
Análisis Artificial Associations Científicos Conciencia Consciencia Consciencia Artificial Conscientes Consciousness Howto Investigación Investigadores Microsoft Máquinas Publicaciones Researchers Reviews Robot Robotics Robots Servicios Studio artificial conciencia
Destacados
Titulares RSS
 Conscious Robots RSS FeedFuente RSS de Conscious Robots
Conscious-Robots.com Forum  


carlcs
Usuarios

Expert Boarder
Mensajes: 20
graphgraph
Karma: 1  
how do i "pass" data to other services? - 2008/10/08 16:37 hi.

i managed to find a sonar and 2d pose and orientation log file of a pioneer robot that was making a map of the 1st floor of the CSIS building in the University of Limerick, Ireland.

what i'm attempting to do is make a service that reads in the log and breaks each line into the 2dpose and orientation array and the sonar range data array and then signal another service that is listening for sonar updates and, since I'm still working on it, pose updates.

how will i do this, especially the signaling part because I'm getting confused. hahaha
  El administrador ha deshabilitado la escritura de mensajes a los usuarios no registrados.
Raúl
Moderador

Moderador
Mensajes: 427
graph
Karma: 6  
Re:how do i "pass" data to other services? - 2008/10/08 17:53 Hi carlcs, hey I know that building.. I used to work close to there (in the Foundation building) like six years ago!

For the signaling part, I would use the standard MSRS service subscription model. Also, I would write two separate services: one serving sonar reading and other serving pose paramenters (although both of them take the date from the same log file). The reason is that probably you want your control code, let's call it control service, to be written just once independently of whether you read data from a real sonar or from the logged-sonar reader service.

So you could write a, say LoggedSonar service, which will implement the generic contract for Sonar. Thus, your control code doesn't need to know about special cases, like using a real sonar, or a simulated one, or in your case a logged sonar reader. You can have a look to my simulated sonar service to check how the generic sonar contract can be implemented, and also you can check how state updates are notified to subscribers. You could implement a timer (like in MSRS service tutorials incrementTick) and send a new sonar reading everytime the timer tick handler is executed. Does this makes sense for you? Is this what you want to do?

Cheers,
Raúl.
Raúl Arrabales Moreno. conscious-robots.com/raul
  El administrador ha deshabilitado la escritura de mensajes a los usuarios no registrados.
carlcs
Usuarios

Expert Boarder
Mensajes: 20
graphgraph
Karma: 1  
Re:how do i "pass" data to other services? - 2008/10/09 14:45 yeah!!! that's exactly what i want to do. the mapping service i want to run using the real-world data already runs in simulation. yeah. that's what I'm trying to make. i don't want to change the mapping service so it will be generic.

one other problem is that the mapping service uses the simulated differential drive to estimate pose and orientation. but since there is already pose and orientation data, do i have to make some sort of "special" listener for it?
  El administrador ha deshabilitado la escritura de mensajes a los usuarios no registrados.
Raúl
Moderador

Moderador
Mensajes: 427
graph
Karma: 6  
Re:how do i "pass" data to other services? - 2008/10/09 20:48 Yes, your control service will have to subscribe to a pose estimation service in order to retrieve localization data. Actually, the way you are corrently getting the pose is a trick that can only be done in the simulator, and doesn't scale to the real world (I am doing the same trick by the way ).

Normally, in a real world environment you would apply any SLAM algorithm (Simultaneous Localization and Mapping) taking as input data from the wheel encoders. However, in your case you will replace the SLAM algorithm by a source of already calculated data, which is your log file. Again, this way of organizing the services allow you to write a generic control service independently of the source of your localization data: it could be either the localization log reader or a real pose estimation service. You could even define a new generic service for a SLAM service following an analogous strategy as you followed with the Sonar stuff...
Raúl Arrabales Moreno. conscious-robots.com/raul
  El administrador ha deshabilitado la escritura de mensajes a los usuarios no registrados.
carlcs
Usuarios

Expert Boarder
Mensajes: 20
graphgraph
Karma: 1  
Re:how do i "pass" data to other services? - 2008/10/10 05:12 hello again. i was reading your simulated sonar service and i got lost. so, if i were to make something similar to this, i;m guessing i don't need the SonarEntity class. But when i remove it, there are a lot of things dependent on it. Also, i noticed that most of the code involves listening to lrf updates so i'm guessing i don't need that too. i still couldn't find the part where it generates a sonar reading update so that other services will get its data. may i ask what part it is in?
  El administrador ha deshabilitado la escritura de mensajes a los usuarios no registrados.
Raúl
Moderador

Moderador
Mensajes: 427
graph
Karma: 6  
Re:how do i "pass" data to other services? - 2008/10/10 18:17 Hi, you don't need the SonarEntity class because it is what represent the simulation entity in the MSRS simulation environment. In your case, instead of interfacing with the simulation you interface with a log file, so there is no need of simulation entities.

LRF updates as you say are the raytracing done in the simulator in order to calculate sonar readings. Again, as you just read from a log, you don't need to calculate anythig, just read the sonar measurements from the file.

If you look into the SimulatedSonar.cs file, the following method is the one issuing the notification to the subscribers of the service:

Code:

 [ServiceHandler(ServiceHandlerBehavior.Exclusive)] public IEnumerator<ITaskReplaceHandler(pxsonar.Replace replace) {      _state replace.Body;      if (replace.ResponsePort != null)          replace.ResponsePort.Post(dssp.DefaultReplaceResponseType.Instance);      // issue notification      _subMgrPort.Post(new submgr.Submit(_statedssp.DsspActions.ReplaceRequest));      yield break; }



Take a look to the MSRS service tutorials about subscription to understand how this works. Basically this services accepts subscriptions, and sends its updated state (in this case the sonar readings) using the Subscription Manager port.

The ReplaceHandler method is called because I post a replace message to myself when I have a new sonar reading...
Raúl Arrabales Moreno. conscious-robots.com/raul
  El administrador ha deshabilitado la escritura de mensajes a los usuarios no registrados.
carlcs
Usuarios

Expert Boarder
Mensajes: 20
graphgraph
Karma: 1  
Re:how do i "pass" data to other services? - 2008/10/11 09:09 thank you. so... you send an update notification to yourself an the other subscribers...

okay. thank you. i will check that out.
  El administrador ha deshabilitado la escritura de mensajes a los usuarios no registrados.
 
Top!
Advertising links: Rent Games - Cheap Gas - Loans - Phoenix Pools
Top!