[Rock-dev] Defining conditions for state-machines withing roby?
Sylvain Joyeux
bir.sylvain at gmail.com
Tue Jun 3 15:59:00 CEST 2014
Hey, two points:
- this question would better be placed on the robotics stack exchange
website (with the syskit and rock tags) as we discussed earlier on this ML
- it is generally better to ask *what* you want to do first (i.e. when my
pipeline follower reaches heading X I want to do Y), not *how* you think
you should be doing it (state machine, create roby task and so on)
Sylvain
On Tue, Jun 3, 2014 at 3:53 PM, Matthias Goldhoorn <
matthias.goldhoorn at dfki.de> wrote:
> I search for a nice way to define that transition should only be done IF
> some conditions (like data on input ports) are valid.
>
> Concrete:
>
> find_pipe_back = state target_move_def(:finish_when_reached => false ,
> :heading => 1 ...)
> pipe_detector = state pipeline_detector_def
> pipe_detector.depends_on find_pipe_back, :role => "detector"
> start(pipe_detector)
>
> script do
> somewhow_get_reader_of_orientation
> if orientation.yaw < foo and orientation.yaw > 2
> forward pipe_detector.align_auv_event, success_event
> end
> end
>
>
> I thoug to do anything like creating a Roby::Task like this:
>
> class Foo::Task << Roby::Task
> add OrientationSrv, :as => ori_p
> reader = ori_p.orientation.reader
> script do
> if ori.yaw .....
> emit :failed
> else
> emit :success
> end
> end
>
> and then fallback in the statemachine to the original state, but i
> assume this will result in a nonsense-loop. Is there a better way to do
> those things?
>
> Best,
> Matthias
>
>
>
> --
> --
> Matthias Goldhoorn
> Unterwasserrobotik
>
> Standort Bremen:
> DFKI GmbH
> Robotics Innovation Center
> Robert-Hooke-Straße 5
> 28359 Bremen, Germany
>
> Phone: +49 (0)421 218-64100
> Fax: +49 (0)421 218-64150
> E-Mail: robotik at dfki.de
>
> Weitere Informationen: http://www.dfki.de/robotik
> -----------------------------------------------------------------------
> Deutsches Forschungszentrum fuer Kuenstliche Intelligenz GmbH
> Firmensitz: Trippstadter Straße 122, D-67663 Kaiserslautern
> Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster
> (Vorsitzender) Dr. Walter Olthoff
> Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
> Amtsgericht Kaiserslautern, HRB 2313
> Sitz der Gesellschaft: Kaiserslautern (HRB 2313)
> USt-Id.Nr.: DE 148646973
> Steuernummer: 19/673/0060/3
> -----------------------------------------------------------------------
>
>
> _______________________________________________
> Rock-dev mailing list
> Rock-dev at dfki.de
> http://www.dfki.de/mailman/cgi-bin/listinfo/rock-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.dfki.de/pipermail/rock-dev/attachments/20140603/9e9b6dee/attachment.htm
More information about the Rock-dev
mailing list