aldebaran / naoqi_navigation_samples

Contains samples for NAOqi navigation and exploration features. The samples are packaged into Choregraphe applications.
BSD 3-Clause "New" or "Revised" License
36 stars 17 forks source link

Places behavior not starting #13

Closed RoelofJ closed 7 years ago

RoelofJ commented 7 years ago

Hi, I've downloaded this example to test. The explore behaviour works as expected and the map it produces looks very good.

I'm having problem with the Places behavior however, when I open the behavior in Choregraphe and attempt to run, I get the following message in the log: "Unable to reach ExplorationManager service: Cannot find service 'ExplorationManager' in index"

I'm using Choregraphe 2.5.5 and I've updated Pepper to NAOqi version 2.5.5.5.

Any chance someone can point me to what is wrong and how to fix it?

lsouchet commented 7 years ago

Hello, Places app uses the ExplorationManager service to handle the map you have explored. This service should be started when you install the application as stated in the manifest.

If you only run the behavior clicking on Choregraphe Run button, you should consider installing it cleanly instead. It basically consist in clicking on the right button in Choregraphe Robot application panel.

If it does not help, could you tell me more about what you did exactly?

Let me know if it helps, Lucas

RoelofJ commented 7 years ago

Hi, thanks for your quick response! I just tried the clean install, but I got the same response unfortunately.

What I've done so far:

After this I got the message in the log I put in the first post. At first I thought it might be a glitch, so I tried again, restarted the robot, restarted the laptop, but to no avail. I've now also tried it through a clean install, but that didn't help either unfortunately. I've also tried to manually start the service by clicking the green arrow next to the python script (in the installed programs on the robot) and starting the places behavior after that, but that also didn't work.

Thanks! Roelof

lsouchet commented 7 years ago

It does not seem normal. Just for checking when you say

Pressed the start button from Choregraphe to run the program to see what it does

Are you talking about this icon?

This is the right way of installing applications. You can then start the app using the green arrow next to the behavior name in the application list. If the start still fails, could you retrieve the logs on your robot, either using Monitor Log viewer or copying /var/log/naoqi folder from your robot? Thanks

RoelofJ commented 7 years ago

In that line I was atually talking about this icon, but on your suggestion I also tried the button you just linked to. Both give the same result.

I've attached the log folder you requested: naoqi.zip

lsouchet commented 7 years ago

I don't really understand what is going wrong. From the logs, I see that instantiation of ExplorationManager fails with this error:

Traceback (most recent call last): File "explorationManager.py", line 293, in my_service = ExplorationManager(session) File "explorationManager.py", line 75, in init self.logger.info("Start init ExplorationManager done.") AttributeError: ExplorationManager instance has no attribute 'logger'

But I cannot find the line:

self.logger.info("Start init ExplorationManager done.")

in the code. Can you check in your explorationManager.py file if you see this line?

To confirm fresh installation of places app, could you please:

Sorry for the inconvenience, Please keep me posted,

Thanks

RoelofJ commented 7 years ago

Ah, that line was my fault. I tried to run the behavior (with the play button) and when it didn't work, I added that line in the hope to get some more info, but as it still didn't work, I started this topic. After removing the line it did work when I deployed using the icon you mentioned it does work now, but it still doesn't work when trying to run the behavior from the top menu in Choregraphe. I suppose my mistake was to assume that running the behavior with the play arrow was identical to the process of first deploying the app and then playing from the robot applications menu. Do you know why it doesn't work when I hit the play button from the top menu in Choregraphe (which deploys as '.lastuploadedbehavior')?

For now it works at least when I deploy first and play from the applications menu, so thanks for your help! :)

lsouchet commented 7 years ago

It is great to hear this. I think that using the "run" button deploys the current behavior only using lastuploadedbehavior. I am not even sure the whole project is deployed, which includes ExplorationManager.py and the manifest that contains the command to automatically start ExplorationManager service on installation.

I'll update the README accordingly. I'm glad I could help, don't hesitate if you have some other troubles. Lucas