Intel® Makers
Intel® Edison, Intel® Joule™, Intel® Curie™, Intel® Galileo
Announcements
Welcome - This is a Peer-to-Peer Forum only. Intel has discontinued these products but you may find support from other customers on this Forum
9881 Discussions

Ubilinux run ROS launch file on startup

CLIU37
Beginner
1,069 Views

Hi

I met problems in setting my "edison+ubilinux" to launch a ROS launch file on startup.

I write a "startup.sh" script as follow,

. /home/tmac/.bashrc

. /home/tmac/.profile

export ROS_IP=192.168.98.33

source ~/pixfcu_ws/devel/setup.bash

roslaunch pixfcu fcu.launch

echo "fcu.sh CHECK!" >> ~/test.sh

If I run it via,

. ~/startup.sh

It working totally fine and my ROS nodes are launched.

Then, I tried to launch this file via "/etc/rc.local" or "/etc/init.d/". The last command,

echo "fcu.sh CHECK!" >> ~/test.sh

it is executed. But, all other commands are not executed at all.

Either I put the startup.sh in "rc.local" or "/etc/init.d/", none of them are executed.

I just want to auto-run my ROS script at startup.

Any advice appreciated !

Chuhao

1 Reply
idata
Community Manager
189 Views

Hello chuhao,

 

 

I believe what you are trying to do is a system service. If you were using Yocto, you could learn how to create one by following the guide found in https://communities.intel.com/docs/DOC-111103 https://communities.intel.com/docs/DOC-111103.

 

 

Since Ubilinux uses init.d, I'd suggest you to read http://www.tldp.org/HOWTO/HighQuality-Apps-HOWTO/boot.html. And if you still have issues, I'd suggest you to contact Emutex ( http://www.emutex.com/contact) for more help in Ubilinux.

 

 

-Peter.
Reply