some help required while working on java and cigwin together .
Posted
by Hippo
on Stack Overflow
See other posts from Stack Overflow
or by Hippo
Published on 2010-03-26T06:23:25Z
Indexed on
2010/03/26
6:53 UTC
Read the original article
Hit count: 401
Hello ..
I am new to java and also cygwin . I do not have in detailed knowledge of both .
I need some help..
I simple steps i will try to explain my problem.
1) I am working on tinyOS . its open source OS , used for wireless sensor networks. It provides java libraries to work on communication (PC to sensor)
2) I am working on windows xp environment through cigwin.
3) I am developing an application . THis application requires one java interface called "Serial Forwarder" , which is readily available in libraries provided. Previously i used to start this interface manually (by entering command *"java net.tinyos.sf.SerialForwarder ")*and then my application which uses this interface. But now i want to make my application independent . User need know about this background cygwin commands .
4) So in my java application i used
"Runtime.getRuntime().exec( "java net.tinyos.sf.SerialForwarder)" .
5) This i neither giving any error nor starting the interface.
Am I going on right way ?
When i am using runtime execute command , how can i make sure that this command is called through cigwin interface ?
Also .. if i want to write .bat file .. i which i can give commands which will be executed .. how can i make sure that those commands are given through cigwin .. and not through cmd.exe .. Please help . me .
© Stack Overflow or respective owner