I have worked with galileo gen2 using node.js as well as C.But when I power it off and on immediately, the node.js program automatically runs but the C program doesn't.
Also another problem I have encountered with eclipse IDE is that when I disconnect a particular galileo from the IDE, the program also stops running.
Any reason why this happens?
The reason why the script (uploaded with Eclipse) stops working is because it is stored in a temporary directory, called /tmp. Every time the board boots this directory is cleaned.
Check /message/358383# 358383 this thread, in there I explain how to create a C or C++ script that runs every time on boot by using a system service. Let me know if you are able to create one for your project.
Hey peter, what about when I just disconnect from the galileo(in Eclipse) instead of powering it off would this method still be working there?
Because it stops as and when i disconnect
If you use the method I described above you won't need to use Eclipse. That way you will be able to run your scripts directly from Linux. They shouldn't be affected if you disconnect the board from the PC. As long as your board is powered the script should run.
I personally like to work directly from Linux better. I usually use an IDE (Arduino, XDK, Eclipse...) when prototyping a script but when it is ready, I believe the best option is to work with them directly from Linux since you have more control over the process that way.