[Rock-dev] Fullfill several conrol-loops with one controller?

Matthias Goldhoorn matthias.goldhoorn at dfki.de
Tue Jul 2 13:59:15 CEST 2013


Just had the case that an joystick provides several "controller" modes.
How can i get the mapping within syskit:


   6         Base::ControlLoop.declare 'RawCommand', 'controldev/RawCommand'
   7         Base::ControlLoop.declare 'FourWheel', 
'controldev/FourWheelCommand'
   8
   9         device_type 'Joystick' do
  10             provides Base::Motion2DControllerSrv
  11             provides Base::RawCommandControllerSrv
  12         end
  13         device_type 'CANJoystick' do
  14             provides Base::Motion2DControllerSrv
  15             provides Base::RawCommandControllerSrv
  16         end

error:
13:53:20.972 (Roby) 
/home/goldhoorn/dev-avalon/tools/syskit/lib/syskit/models/data_service.rb:160:in 
`block in provides': invalid port mapping command_out => command_out in 
#<Syskit::Models::DeviceModel:0x00000005dc35c0>.provides(Base::RawCommandControllerSrv): 
port command_out on #<Syskit::Models::DeviceModel:0x00000005dc35c0> is 
of type /controldev/RawCommand and command_out on 
Base::RawCommandControllerSrv is of type /base/MotionCommand2D 
(Syskit::SpecError)


the normal way
provides Base::Motion2DControllerSrv, "four_wheel_command" => "command_out"
provides Base::RawCommandControllerSrv, "raw_command" => "command_out"
make's (of course) no sense because it's not specialized here?!

Matthias

-- 
  Dipl.-Inf. Matthias Goldhoorn
  Space and Underwater Robotic

  Universität Bremen
  FB 3 - Mathematik und Informatik
  AG Robotik
  Robert-Hooke-Straße 5
  28359 Bremen, Germany

  Tel.:     +49 421 178 45-4193
  Zentrale: +49 421 178 45-6550
  Fax:      +49 421 178 45-4150
  E-Mail:   matthias.goldhoorn at uni-bremen.de

  Weitere Informationen: http://www.informatik.uni-bremen.de/robotik



More information about the Rock-dev mailing list