-
Notifications
You must be signed in to change notification settings - Fork 112
How can i reconnect with RosMaster #72
Comments
Hi @tomliu77, The easy workaround is what you say: close the app and reopen it. |
@jubeira, thanks for your answer,I use nodeMainExecutorService.shutdownNodeMain() to shutdown all my nodes and use nodeMainExecutor.execute() to launch them again. But the question is , I see the callback onShutdownComplete() is called quieckly but the node looks like not shutdown competely, Because the number of thread haven't reduce . When I try to restart my nodes ,app chrashed with OOM |
@jubeira, by the way ,I have 18 nodes and I find 400+ thread in Android studio profiling , when i shutdown my nodes ,the number of thread will reduce to 60+ after 1min. Also, should i call an new NodeMainExecutorService when wifi has been reconnected? |
@jubeira, thanks for your answer again |
@tomliu77 I'm not 100% sure about this, but I think you should code |
@jubeira,Thanks for your advice. When I code
It's seems like I can not use this way ,so I delete |
Hmm there's no standard way to do that that I know of... You could also lower the timeouts. If you go to rosjava_core, you will see timeouts here and there (search for keywords like "timeout" and "5000" or "10000"; most of them last 5 seconds). You can modify that, recompile rosjava_core, and use your custom version with low timeouts. In any case, that's just another hack.
from your activity in |
The real clean way would be to shut down all the nodes before turning off Wi Fi (that won't take long, because all the nodes will just unregister in the standard way without timeouts), but you may not have control over that. |
@jubeira,Thank you. It's seems like |
if i turn off wifi, and then i turing on ,app can't reconnect with my robot,show i close server and start it again or threre is some simple way?
The text was updated successfully, but these errors were encountered: