ROS/Matlab Simulink communication
Dear Ros users, I've successfully created a simulator in gazebo. Now i want to communicate to the controller via topics. I can't seem to succeed at creating a publisher/subscriber S-function. I've included all the necessary header files, but Matlab crashes during initialization(part of the crashdump included). Even though i only call upon ros::init.
I've seen some question about this, yet no definitive answers. Has there been any earlier (succesful or not) attempt at this?
Thanks,
Erik
Segment of ros code causing the crash.
int argc = 0;
char** argv = NULL;
ros::init(argc,argv,"talker");
ros::NodeHandle n;
Crashdump:
------------------------------------------------------------------------
Abort signal detected at Fri Jan 6 15:04:10 2012
------------------------------------------------------------------------
Configuration:
Crash Decoding : Disabled
Current Visual : 0x21 (class 4, depth 24)
Default Encoding: UTF-8
GNU C Library : 2.11.1 stable
MATLAB Root : /usr/local/MATLAB/R2011b
MATLAB Version : 7.13.0.564 (R2011b)
Operating System: Linux 2.6.32-37-generic-pae #81-Ubuntu SMP Fri Dec 2 22:24:22 UTC 2011 i686
Processor ID : x86 Family 6 Model 10 Stepping 5, GenuineIntel
Virtual Machine : Java 1.6.0_17-b04 with Sun Microsystems Inc. Java HotSpot(TM) Client VM mixed mode
Window System : The X.Org Foundation (10706000), display :0.0
Fault Count: 1
Abnormal termination:
Abort signal
Register State (from fault):
EAX = 00000000 EBX = 00001025
ECX = 00001059 EDX = 00000006
ESP = b03db450 EBP = b03db468
ESI = 00000400 EDI = b6be0ff4
EIP = b78d7430 EFL = 00000202
CS = 00000073 DS = 0000007b SS = 0000007b
ES = 0000007b FS = 00000000 GS = 00000033
Stack Trace (from fault):
[ 0] 0xb7761255 /usr/local/MATLAB/R2011b/bin/glnx86/libmwfl.so+00156245 _ZN2fl4diag15stacktrace_base7captureERKNS0_14thread_contextEj+000169
[ 1] 0xb7764175 /usr/local/MATLAB/R2011b/bin/glnx86/libmwfl.so+00168309
[ 2] 0xb7764569 /usr/local/MATLAB/R2011b/bin/glnx86/libmwfl.so+00169321 _ZN2fl4diag13terminate_logEPKcRKNS0_14thread_contextEb+000181
[ 3] 0xb73df93f /usr/local/MATLAB/R2011b/bin/glnx86/libmwmcr.so+00399679 _ZN2fl4diag13terminate_logEPKcPK8ucontextb+000096
[ 4] 0xb73dc996 /usr/local/MATLAB/R2011b/bin/glnx86/libmwmcr.so+00387478
[ 5] 0xb73ddd35 /usr/local/MATLAB/R2011b/bin/glnx86/libmwmcr.so+00392501
[ 6] 0xb73deab6 /usr/local/MATLAB/R2011b/bin/glnx86/libmwmcr.so+00395958
[ 7] 0xb78d7410 __kernel_rt_sigreturn+000000
[ 8] 0xb78d7430 __kernel_vsyscall+000016
[ 9] 0xb6ab5651 /lib/tls/i686/cmov/libc.so.6+00173649 gsignal+000081
[ 10] 0xb6ab8a82 /lib/tls/i686/cmov/libc.so.6+00187010 abort+000386