Hi,
I'm using RTT-1.8.4 and OCL-1.8.1 with Linux/RTAI to build a robot control system.
I'm using the deployer to make the system startup. When I use a control period of 10 ms, the system works perfectly, but when I reduce the period to 2 ms, sometimes, the deployer aborts with this error:
0.125 [ Info ][DeploymentComponent::startComponents] Startup successful.
0.125 [ Info ][deployer-lxrt::main()] Successfully loaded, configured and started components from xml/startup.xml
Switched to : Deployer
terminate called after throwing an instance of 'St9bad_alloc'
what(): std::bad_alloc
Aborted
First, I was thinking that the system loses its deadline, but I measured the computed time (in one time that the error didn't occur) and it is about 600us.
Second, I reduce the system components until the error doesn't occur, then I start to increase it. When I connect a ReadDataPort with a Event in a WriteDataPort that is periodically updated, the error start to occur, even though the callback of this port don't do nothing.
ReadDataPort< std::vector
this->ports()->addEventPort(&sensor_port,boost::bind(&Bridge::sensor_now, this));
void Bridge::sensor_now()
{
}
I was wondering if someone had this problem before.
Thanks.
Deployer aborts at system startup
On Tue, Jul 28, 2009 at 15:26, <diegos [..] ...> wrote:
> Hi,
>
> I'm using RTT-1.8.4 and OCL-1.8.1 with Linux/RTAI to build a robot control system.
>
> I'm using the deployer to make the system startup. When I use a control period of 10 ms, the system works perfectly, but when I reduce the period to 2 ms, sometimes, the deployer aborts with this error:
>
> 0.125 [ Info ][DeploymentComponent::startComponents] Startup successful.
> 0.125 [ Info ][deployer-lxrt::main()] Successfully loaded, configured and started components from xml/startup.xml
> Switched to : Deployer
> terminate called after throwing an instance of 'St9bad_alloc'
> what(): std::bad_alloc
> Aborted
>
>
> First, I was thinking that the system loses its deadline, but I measured the computed time (in one time that the error didn't occur) and it is about 600us.
> Second, I reduce the system components until the error doesn't occur, then I start to increase it. When I connect a ReadDataPort with a Event in a WriteDataPort that is periodically updated, the error start to occur, even though the callback of this port don't do nothing.
>
> ReadDataPort< std::vector<double> > nAxesDP_port;
> this->ports()->addEventPort(&sensor_port,boost::bind(&Bridge::sensor_now, this));
> void Bridge::sensor_now()
> {
> }
>
> I was wondering if someone had this problem before.
It's a bug. Any chance in running your application with valgrind ?
'valgrind my-app-name'
The std::bad_alloc is thrown by the vector<double>, but I need to know
where this happend, valgrind will show this, but compile your
application/components with '-g'.
Peter
Deployer aborts at system startup
I've never seen this before, maybe we can figure out what happened if
you send some more information:
* run your deployer with the -ldebug flag
* compile RTT/your app with debug information (CMAKE_BUILD_TYPE=Debug)
and run it with gdb post the backtrace.
Ruben
On Tue, Jul 28, 2009 at 3:26 PM, diegos [..] ...<diegos [..] ...> wrote:
> Hi,
>
> I'm using RTT-1.8.4 and OCL-1.8.1 with Linux/RTAI to build a robot control system.
>
> I'm using the deployer to make the system startup. When I use a control period of 10 ms, the system works perfectly, but when I reduce the period to 2 ms, sometimes, the deployer aborts with this error:
>
> 0.125 [ Info ][DeploymentComponent::startComponents] Startup successful.
> 0.125 [ Info ][deployer-lxrt::main()] Successfully loaded, configured and started components from xml/startup.xml
> Switched to : Deployer
> terminate called after throwing an instance of 'St9bad_alloc'
> what(): std::bad_alloc
> Aborted
>
>
> First, I was thinking that the system loses its deadline, but I measured the computed time (in one time that the error didn't occur) and it is about 600us.
> Second, I reduce the system components until the error doesn't occur, then I start to increase it. When I connect a ReadDataPort with a Event in a WriteDataPort that is periodically updated, the error start to occur, even though the callback of this port don't do nothing.
>
> ReadDataPort< std::vector<double> > nAxesDP_port;
> this->ports()->addEventPort(&sensor_port,boost::bind(&Bridge::sensor_now, this));
> void Bridge::sensor_now()
> {
> }
>
> I was wondering if someone had this problem before.
> Thanks.
>
> --
> Orocos-Users mailing list
> Orocos-Users [..] ...
> http://lists.mech.kuleuven.be/mailman/listinfo/orocos-users
>