Ask Your Question

Does it make sense to use ros_control in my case and related questions.

asked 2015-11-11 16:39:21 -0500

I am currently writing a node for the EV3 which should automatically detect a motor on the port of the EV3 and setup the right control for it (I have a node which currently works for the sensors which does that). The EV3 features 4 motor ports, which can but do not have to be connected. I would start 4 nodes, one for each port and let them wait for the motors to appear and then create the interfaces. I plan to limit the interaction with the user and the brick so that the user can develop his program on the computer and doesn't have to upload anything to the brick and just needs to plug the sensors and motors and will automatically get the interfaces over network. The only thing needed to set then, would be the rosmaster and the network (SSID / PW - if wireless).

Does it make sense to use ros_control in this case?

If yes: I checked also checked out the JointStateHandle class. It features the functions getposition, getspeed and geteffort. Would it make sense that I create a class based on JointStateHandle, which directly calls the port driver to obtain these values from the drivers file in /sys, or do I need to do it in the realtime loop and set the values of this class?

Currently I do not have a real time kernel on the EV3, does ros_control also run without an realtime kernel?

I am also currently searching for a simple example for ros_control. I tried the tutorial but, well some parts of the example are missing. I also checked out the PR2 code. I found the controller class header, but I did not find the real code which actually is controlling the motors.

A very very simple example would be really nice. It does not need to be a full robot at all, just a joint which prints something on the console like "speed set to X" or "position set to Y" would do the job I think. Just something to copy which works so that one can have an smooth start. Is there something like this somewhere? Or did I miss it somewhere?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2015-11-12 17:26:00 -0500

updated 2015-11-12 17:27:11 -0500

Well I found some more stuff for it now and I made a little working example, well sharing is caring, here you go:

(Only thing not working is somehow the covariance matrix for the Imu sensor, It just takes one value for me in the message.)

I read the code there but it actually should work, wonder why it does not ...

My other questions: Yep it seems to run without realtime kernel. I think now, after I completely saw the setup and everything, it is suitable for my purpose.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools



Asked: 2015-11-11 16:39:21 -0500

Seen: 208 times

Last updated: Nov 12 '15