Hello!
I hope that my question didn't take much of your time. Also i hope that this topic will help someone.
Yesterday i was reading "Orocos Components Manual". At the chapter 3 was written about creation of your own component. AS you understand.. i recieved errors again. That's the list of my actions:
mostly it was an improvisation wich was connected with not full understanding...
1. i had created a pkg MyTask (the same like HelloWorld with absolute identical content)
2. i inserted code wich was written below to MyTask-component.cpp
#include <rtt/TaskContext.hpp> #include <rtt/Component.hpp> // we assume this is done in all the following code listings : using namespace RTT; class MyTask : public TaskContext { public: ATask(const std::string& name) : public TaskContext(name) {} }; // from Component.hpp: OCL_CREATE_COMPONENT( MyTask );3. i was trying to run MyTask.import (with Hello[S]> state)
If it is possible, please write right actions wich i must do for creation a component and import to another component (like a HelloWorld)
Please do not judge strictly my actions, I had no much time to deal with this.
Chapter 3 basic component creation
On Thu, 1 Dec 2011, aivanov [dot] mcu [..] ... wrote:
> Hello!
>
>
> I hope that my question didn't take much of your time. Also i hope that this
> topic will help someone.
>
> Yesterday i was reading "Orocos Components Manual". At the chapter 3 was
> written about creation of your own component. AS you understand.. i recieved
> errors again. That's the list of my actions:
>
> mostly it was an improvisation wich was connected with not full
> understanding...
>
> 1. i had created a pkg MyTask (the same like HelloWorld with absolute
> identical content)
>
> 2. i inserted code wich was written below to MyTask-component.cpp
>
> #include
> #include
>
> // we assume this is done in all the following code listings :
> using namespace RTT;
>
> class MyTask : public TaskContext
> {
> public:
> ATask(const std::string& name) : public TaskContext(name) {}
> };
>
> // from Component.hpp:
> OCL_CREATE_COMPONENT( MyTask );
>
> 3. i was trying to run MyTask.import (with Hello[S]> state)
>
> If it is possible, please write right actions wich i must do for creation a
> component and import to another component (like a HelloWorld)
>
> Please do not judge strictly my actions, I had no much time to deal with
> this.
A sidenote that might help you from becoming disappointed...
I think you should be aware of the fact that people in open source projects
like to help each other, but only when they are convinced that "the other
side" has done all possible efforts to solve their problems on their own
first. In other words, it is considered not too good practice to let others
think for you, with the excuse that you did not have time to think for
yourself...
Don't consider this remark as an effort to drive you away, but, on the
contrary, as ean effort to teach you some "mailing list attitude" from
which you will be able to profit tremendously.
Herman
Chapter 3 basic component creation
On Thursday 01 December 2011 07:16:36 aivanov [dot] mcu [..] ... wrote:
> Hello!
>
>
> I hope that my question didn't take much of your time. Also i hope that
> this topic will help someone.
>
> Yesterday i was reading "Orocos Components Manual". At the chapter 3 was
> written about creation of your own component. AS you understand.. i
> recieved errors again. That's the list of my actions:
>
> mostly it was an improvisation wich was connected with not full
> understanding...
>
> 1. i had created a pkg MyTask (the same like HelloWorld with absolute
> identical content)
>
> 2. i inserted code wich was written below to MyTask-component.cpp
>
> #include
> #include
>
> // we assume this is done in all the following code listings :
> using namespace RTT;
>
> class MyTask : public TaskContext
> {
> public:
> ATask(const std::string& name) : public TaskContext(name) {}
> };
>
> // from Component.hpp:
> OCL_CREATE_COMPONENT( MyTask );
>
> 3. i was trying to run MyTask.import (with Hello[S]> state)
>
> If it is possible, please write right actions wich i must do for creation a
> component and import to another component (like a HelloWorld)
>
> Please do not judge strictly my actions, I had no much time to deal with
> this.
Just run the deployer-gnulinux application and then enter these 3 commands:
$deployer-gnulinux
Deployer [S]> import("mytask") // 'mytask' is a directory name to import
Deployer [S]> displayComponentTypes() // lists 'MyTask' among others
...
MyTask
...
Deployer [S]> loadComponent("the_task", "MyTask")
Then you can browse to it:
Deployer [S]> ls the_task
Deployer [S]> cd the_task
etc. Consult the DeploymentComponent manual and TaskBrowser manuals for more
instructions.
Peter
Help
Thank you!
I will try all what you say.
With best regards!
Chapter 3 basic component creation
It is not "the excuse that you did not have time to think"!
I just want reach results rapidly. I'm not a student and i really work with orocos only after my job. Sure i know that all of you are really advanced users. I am asking questions only becouse i want to work at home and not waste my time trying all the combinations(really i was reading the content carefully). But really maybe you are right... i'm trying to run through the beginning rapidly.
If i don't want to think i wouldn't be with you)...
Chapter 3 basic component creation
On Thu, 1 Dec 2011, aivanov [dot] mcu [..] ... wrote:
> It is not "the excuse that you did not have time to think"!
>
> I just want reach results rapidly. I'm not a student and i really work with
> orocos only after my job. Sure i know that all of you are really advanced
> users. I am asking questions only becouse i want to work at home and not
> waste my time trying all the combinations(really i was reading the content
> carefully). But really maybe you are right... i'm trying to run through the
> beginning rapidly.
And learning why and how to best apply a component based framework _is_
difficult, so, take your time and don't rush :-)
> If i don't want to think i wouldn't be with you)...
Good! :-)
Herman