Controller example: [ ERROR ][TypeInfoName] Can not compose unknown_t.

Hello Everyone,

I am trying to build the controller example from Orocos and I have RTT
version 2.5 installed. I am also sending my source code as an attachment to
reproduce the errors. Following is the screen output:

aviator@aviator-laptop:~/orocos_test/Controller$ rosrun ocl
deployer-gnulinux -s example1.cpf
0.049 [ Warning][DeploymentComponent::import] The ROS package 'ocl' in
'/opt/ros/electric/stacks/orocos_toolchain/ocl' nor its dependencies
contained a lib/orocos directory. I'll look in the RTT_COMPONENT_PATH next.
0.087 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
already added for type /std/string
0.087 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
already added for type /std/vector<double>
0.112 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
already added for type /std/vector<double>
Plugin of Controller loaded in process.
0.126 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
already added for type /std/string
0.126 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
already added for type /std/vector<double>
0.139 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
already added for type /std/string
0.139 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
already added for type /std/vector<double>
0.139 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
already added for type /std/string
0.140 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
already added for type /std/string
0.140 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
already added for type /std/vector<double>
0.140 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
already added for type /std/vector<double>
0.141 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
already added for type /std/string
0.141 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
already added for type /std/vector<double>
Plugin of Plant loaded in process.
0.145 [ Warning][DeploymentComponent::loadComponents] Lowering scheduler
type to SCHED_OTHER for non-privileged users..
0.145 [ Warning][DeploymentComponent::loadComponents] Forcing priority (99)
of thread with SCHED_OTHER policy to 0.
0.146 [ Warning][Thread] Lowering scheduler type to SCHED_OTHER for
non-privileged users..
0.146 [ Warning][Activity] Lowering scheduler type to SCHED_OTHER for
non-privileged users..
0.148 [ ERROR ][ReportingComponent] Can not report InputPort SensorValues
of Component Controller_Component
0.148 [ ERROR ][ReportingComponent] Can not report InputPort SetPoints of
Component Plant_Component
0.148 [ ERROR ][TypeInfoName] Can not compose unknown_t.
0.148 [ ERROR ][refreshProperties] refreshProperties: Could not update,
nor convert Property unknown_t Gain: type mismatch, can not update with
double Gain
0.148 [ ERROR ][DeploymentComponent::configureComponents] Failed to
configure properties for component Controller_Component
0.149 [ ERROR ][Logger] Failed to configure a component: aborting
kick-start.
Switched to : Deployer

This console reader allows you to browse and manipulate TaskContexts.
You can type in an operation, expression, create or change variables.
(type 'help' for instructions and 'ls' for context info)

TAB completion and HISTORY is available ('bash' like)

Use 'Ctrl-D' or type 'quit' to exit this program.

Deployer [S]>

There are a lot of Errors that I am unable to rectify. Also I am able to
start my reporting and Plant components via TaskBrowser, However the
Controller components fails to start as the Properties file is not loaded
due to "Unknown_t " error. Also I am unable to load the program script into
the Controller Component because of the same error. These unknown types are
doubles which I think are inherently handled by RTT. Can someone tell me
what is the problem? I also reviewed the mailing list archives but did not
find a suitable thread.

Best Wishes
Shashank

AttachmentSize
Plant.zip2.73 KB
controller_app.zip5.89 KB

Controller example: [ ERROR ][TypeInfoName] Can not compose unkn

Hello everyone,

Thank you Ruben for the suggestion!

Br
Shashank

On Sat, Jan 14, 2012 at 12:00 PM, <
orocos-users-request [..] ...> wrote:

> Send Orocos-Users mailing list submissions to
> orocos-users [..] ...
>
> To subscribe or unsubscribe via the World Wide Web, visit
> http://lists.mech.kuleuven.be/mailman/listinfo/orocos-users
> or, via email, send a message with subject or body 'help' to
> orocos-users-request [..] ...
>
> You can reach the person managing the list at
> orocos-users-owner [..] ...
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Orocos-Users digest..."
>
>
> Today's Topics:
>
> 1. Re: Two-headed activities (S Roderick)
> 2. Re: Controller example: [ ERROR ][TypeInfoName] Can not
> compose unknown_t. (Ruben Smits)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Fri, 13 Jan 2012 15:19:51 -0500
> From: S Roderick <kiwi [dot] net [..] ...>
> Subject: Re: [Orocos-users] Two-headed activities
> To: "orocos-users [..] ... Users"
> <orocos-users [..] ...>
> Message-ID: <109BBFDB-9881-4DB8-B9A4-D7D241B45305 [..] ...>
> Content-Type: text/plain; CHARSET=US-ASCII
>
> On Jan 13, 2012, at 10:35 , Stephen Roderick wrote:
>
> > On Jan 7, 2012, at 04:15 , Markus Klotzbuecher wrote:
> >
> >> On Fri, Jan 06, 2012 at 07:38:19PM +0100, Stephen Roderick wrote:
> >>> On Jan 6, 2012, at 09:08 , Markus Klotzbuecher wrote:
> >>>
> >>>> On Fri, Jan 06, 2012 at 01:42:38PM +0100, S Roderick wrote:
> >>>>> We have a need to synchronize a suite of components, controlled by a
> >>>>> single Coordination component, to a hardware signal. But that signal
> >>>>> isn't available during initialization and shutdown (which takes many
> >>>>> seconds), and may block or dissappear at certain times. During these
> >>>>> periods, we still want the Coordinator to be able to run
> >>>>> periodically. So I think we need a custom Activity that is periodic
> >>>>> by default, but otherwise synchronized to the hardware signal when
> >>>>> available. Obviously the Coordinator component and/or the activity
> >>>>> will have to deal appropriately with the timeout on the hardware
> >>>>> signal.
> >>>>>
> >>>>> Has anyone done anything like this before? Does anyone have any
> >>>>
> >>>> Not exactly, but similar.
> >>>>
> >>>>> alternative suggestions?
> >>>>
> >>>> The event driven scenario: Have a periodic TimerComponent trigger your
> >>>> event driven Coordinator at your desired "base" frequency. Then simply
> >>>> connect your event generating hardware component (or any other!).
> >>>>
> >>>> I like this one somewhat better, because it doesn't require a new
> >>>> primitive (the custom Activity). One the other hand for ultra-low
> >>>> latencies the latter might do slightly better; YMMV.
> >>>
> >>> Your idea does have merit, however, you hit the nail on the head as
> >>> we need very low latency. But out of curiosity, how do you imagine
> >>
> >> Ok. But note that RTT is indeed quite efficient at communicating event
> >> messages. On my machine using C++ components the wakeup latency with
> >> this approach was few tens of microseconds ([1], Section 4.2).
> >>
> >>> connecting the "event generating hardware component"? Particularly
> >>> as that item isn't an Orocos component.
> >>
> >> You will have a software (driver) component too, no? That one defines
> >> a port to which it writes a data-sample according to the hardware
> >> signal. Then you only need to connect that output port to an event
> >> port of your coordinator.
> >>
> >> Markus
> >
> > We have ended up doing this a little differently, but I wanted to
> communicate the result, along with a few interesting things learned along
> the way.
> >
> > Our hardware driver is in a non-Orocos controlled thread, and writes to
> a pipe when the hardware updates. This is the signal we want to sync on.
> This signal is not available until the hardware is fully initialized (takes
> several seconds), and is not available if certain hardware faults occur.
> >
> > Our coordinator is simply a state machine, now run by a
> FileDescriptorActivity (FDA). The FDA timeout capability is used to drive
> this component when the hardware signal is not available. We had to add a
> method call to the run() blocks for each state of interest, to process the
> FDA results (error, timeout, isUpdated, etc) and react accordingly.
> >
> > Interesting observations (these pertain to RTT v1)
> >
> > - emitting an event to the coordinator causes additional step()
> executions to occur (i.e update hook executions, and state machine cycles).
> This can overload CPUs ... which is what happened to us (we went from the
> intended 500 Hz, to almost 4 kHz). This will also occur for commands
> (search for trigger() in EventProcessor and CommandProcessor
> implementations). The user implemention must deal with this.
> >
> > - it might be possible that the work fd set in FDA can be used when not
> initialized, if an isUpdated() call occurs before loop(). This would not be
> the typical call sequence, but ...
> >
> > - I believe that there is a possible race condition in the FDA
> implementation, that can theoretically cause fd activity to be missed. The
> timing for this to occur is very fine though. You have to watch() a new fd
> exactly when an existing fd activity occurs. The loop within a loop in
> loop() that processes the trigger-update-sets command can set do_trigger to
> false, causing the fd activity of that cycle to be ignored.
>
> And one thing I missed
>
> - for cases such as ours, where the file descriptor being watched is
> periodic in nature, I think we should allow the FDA to be configured with
> an _intended_ period. This allows the component, or components called via
> slave activities, to use the intended period (e.g. getPeriod() ) in
> computations. So a Computational component used within a Periodic activity
> in one deployment, or with a FD activity that is based on a periodic signal
> in a different deployemtn, requires no additional configuration or changes.
>
>
>
>
>
> ------------------------------
>
> Message: 2
> Date: Fri, 13 Jan 2012 20:34:39 +0100
> From: Ruben Smits <ruben [..] ...>
> Subject: Re: [Orocos-users] Controller example: [ ERROR
> ][TypeInfoName] Can not compose unknown_t.
> To: shashank sharma <sonicboomshanky [..] ...>
> Cc: orocos-users [..] ...
> Message-ID:
> <CAN8PhbmLRCr63HPvL8SvJE2SxfVG5Roamq65a=avbgQFZGKZwQ [..] ...
> >
> Content-Type: text/plain; charset="iso-8859-1"
>
> On Fri, Jan 13, 2012 at 5:02 PM, shashank sharma
> <sonicboomshanky [..] ...>wrote:
>
> > Hello Everyone,
> >
> > I am trying to build the controller example from Orocos and I have RTT
> > version 2.5 installed. I am also sending my source code as an attachment
> to
> > reproduce the errors. Following is the screen output:
> >
> > aviator@aviator-laptop:~/orocos_test/Controller$ rosrun ocl
> > deployer-gnulinux -s example1.cpf
> > 0.049 [ Warning][DeploymentComponent::import] The ROS package 'ocl' in
> > '/opt/ros/electric/stacks/orocos_toolchain/ocl' nor its dependencies
> > contained a lib/orocos directory. I'll look in the RTT_COMPONENT_PATH
> next.
> > 0.087 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
> > already added for type /std/string
> > 0.087 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
> > already added for type /std/vector<double>
> > 0.112 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> > already added for type /std/vector<double>
> > Plugin of Controller loaded in process.
> > 0.126 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
> > already added for type /std/string
> > 0.126 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
> > already added for type /std/vector<double>
> > 0.139 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> > already added for type /std/string
> > 0.139 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> > already added for type /std/vector<double>
> > 0.139 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
> > already added for type /std/string
> > 0.140 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> > already added for type /std/string
> > 0.140 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
> > already added for type /std/vector<double>
> > 0.140 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> > already added for type /std/vector<double>
> > 0.141 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
> > already added for type /std/string
> > 0.141 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
> > already added for type /std/vector<double>
> > Plugin of Plant loaded in process.
> > 0.145 [ Warning][DeploymentComponent::loadComponents] Lowering scheduler
> > type to SCHED_OTHER for non-privileged users..
> > 0.145 [ Warning][DeploymentComponent::loadComponents] Forcing priority
> > (99) of thread with SCHED_OTHER policy to 0.
> > 0.146 [ Warning][Thread] Lowering scheduler type to SCHED_OTHER for
> > non-privileged users..
> > 0.146 [ Warning][Activity] Lowering scheduler type to SCHED_OTHER for
> > non-privileged users..
> > 0.148 [ ERROR ][ReportingComponent] Can not report InputPort
> SensorValues
> > of Component Controller_Component
> > 0.148 [ ERROR ][ReportingComponent] Can not report InputPort SetPoints
> of
> > Component Plant_Component
> > 0.148 [ ERROR ][TypeInfoName] Can not compose unknown_t.
> > 0.148 [ ERROR ][refreshProperties] refreshProperties: Could not update,
> > nor convert Property unknown_t Gain: type mismatch, can not update with
> > double Gain
> > 0.148 [ ERROR ][DeploymentComponent::configureComponents] Failed to
> > configure properties for component Controller_Component
> > 0.149 [ ERROR ][Logger] Failed to configure a component: aborting
> > kick-start.
> > Switched to : Deployer
> >
> > This console reader allows you to browse and manipulate TaskContexts.
> > You can type in an operation, expression, create or change variables.
> > (type 'help' for instructions and 'ls' for context info)
> >
> > TAB completion and HISTORY is available ('bash' like)
> >
> > Use 'Ctrl-D' or type 'quit' to exit this program.
> >
> > Deployer [S]>
> >
> >
> > There are a lot of Errors that I am unable to rectify. Also I am able to
> > start my reporting and Plant components via TaskBrowser, However the
> > Controller components fails to start as the Properties file is not loaded
> > due to "Unknown_t " error. Also I am unable to load the program script
> into
> > the Controller Component because of the same error. These unknown types
> are
> > doubles which I think are inherently handled by RTT. Can someone tell me
> > what is the problem? I also reviewed the mailing list archives but did
> not
> > find a suitable thread.
> >
> >
> I think that the error comes from the property Gain which is of type
> double. I assume that the addProperty faulty adds this as a
> Property<double> instead of double which causes the unknown_t. This has
> been reported before and can be resolved by,
>
> * changing the type of gain to double instead of Property<double>
> * change the addProperty statement to addProperty(&gain)
>
> Ruben
>
>
> > Best Wishes
> > Shashank
> >
> > --
> > Orocos-Users mailing list
> > Orocos-Users [..] ...
> > http://lists.mech.kuleuven.be/mailman/listinfo/orocos-users
> >
> >
> --
> Ruben Smits, Phd
> Chief Technology Officer
> Intermodalics BVBA
> +32479511786
> www.intermodalics.eu
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://lists.mech.kuleuven.be/pipermail/orocos-users/attachments/2012011...
>
> ------------------------------
>
> _______________________________________________
> Orocos-Users mailing list
> Orocos-Users [..] ...
> http://lists.mech.kuleuven.be/mailman/listinfo/orocos-users
>
>
> End of Orocos-Users Digest, Vol 56, Issue 9
> *******************************************
>

Controller example: [ ERROR ][TypeInfoName] Can not compose unkn

On Fri, Jan 13, 2012 at 5:02 PM, shashank sharma
<sonicboomshanky [..] ...>wrote:

> Hello Everyone,
>
> I am trying to build the controller example from Orocos and I have RTT
> version 2.5 installed. I am also sending my source code as an attachment to
> reproduce the errors. Following is the screen output:
>
> aviator@aviator-laptop:~/orocos_test/Controller$ rosrun ocl
> deployer-gnulinux -s example1.cpf
> 0.049 [ Warning][DeploymentComponent::import] The ROS package 'ocl' in
> '/opt/ros/electric/stacks/orocos_toolchain/ocl' nor its dependencies
> contained a lib/orocos directory. I'll look in the RTT_COMPONENT_PATH next.
> 0.087 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
> already added for type /std/string
> 0.087 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
> already added for type /std/vector<double>
> 0.112 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> already added for type /std/vector<double>
> Plugin of Controller loaded in process.
> 0.126 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
> already added for type /std/string
> 0.126 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
> already added for type /std/vector<double>
> 0.139 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> already added for type /std/string
> 0.139 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> already added for type /std/vector<double>
> 0.139 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
> already added for type /std/string
> 0.140 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> already added for type /std/string
> 0.140 [ ERROR ][TypekitRepository::Import] A protocol with id 42 was
> already added for type /std/vector<double>
> 0.140 [ ERROR ][TypekitRepository::Import] A protocol with id 2 was
> already added for type /std/vector<double>
> 0.141 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
> already added for type /std/string
> 0.141 [ ERROR ][TypekitRepository::Import] A protocol with id 1 was
> already added for type /std/vector<double>
> Plugin of Plant loaded in process.
> 0.145 [ Warning][DeploymentComponent::loadComponents] Lowering scheduler
> type to SCHED_OTHER for non-privileged users..
> 0.145 [ Warning][DeploymentComponent::loadComponents] Forcing priority
> (99) of thread with SCHED_OTHER policy to 0.
> 0.146 [ Warning][Thread] Lowering scheduler type to SCHED_OTHER for
> non-privileged users..
> 0.146 [ Warning][Activity] Lowering scheduler type to SCHED_OTHER for
> non-privileged users..
> 0.148 [ ERROR ][ReportingComponent] Can not report InputPort SensorValues
> of Component Controller_Component
> 0.148 [ ERROR ][ReportingComponent] Can not report InputPort SetPoints of
> Component Plant_Component
> 0.148 [ ERROR ][TypeInfoName] Can not compose unknown_t.
> 0.148 [ ERROR ][refreshProperties] refreshProperties: Could not update,
> nor convert Property unknown_t Gain: type mismatch, can not update with
> double Gain
> 0.148 [ ERROR ][DeploymentComponent::configureComponents] Failed to
> configure properties for component Controller_Component
> 0.149 [ ERROR ][Logger] Failed to configure a component: aborting
> kick-start.
> Switched to : Deployer
>
> This console reader allows you to browse and manipulate TaskContexts.
> You can type in an operation, expression, create or change variables.
> (type 'help' for instructions and 'ls' for context info)
>
> TAB completion and HISTORY is available ('bash' like)
>
> Use 'Ctrl-D' or type 'quit' to exit this program.
>
> Deployer [S]>
>
>
> There are a lot of Errors that I am unable to rectify. Also I am able to
> start my reporting and Plant components via TaskBrowser, However the
> Controller components fails to start as the Properties file is not loaded
> due to "Unknown_t " error. Also I am unable to load the program script into
> the Controller Component because of the same error. These unknown types are
> doubles which I think are inherently handled by RTT. Can someone tell me
> what is the problem? I also reviewed the mailing list archives but did not
> find a suitable thread.
>
>
I think that the error comes from the property Gain which is of type
double. I assume that the addProperty faulty adds this as a
Property<double> instead of double which causes the unknown_t. This has
been reported before and can be resolved by,

* changing the type of gain to double instead of Property<double>
* change the addProperty statement to addProperty(&gain)

Ruben

> Best Wishes
> Shashank
>
> --
> Orocos-Users mailing list
> Orocos-Users [..] ...
> http://lists.mech.kuleuven.be/mailman/listinfo/orocos-users
>
>