Back to project page smartcar.
The source code is released under:
GNU General Public License
If you think the Android project smartcar listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
/** * Opens a socket to the desired ip and port and sends the inputted string through it. * @author Team Pegasus (dimi)//ww w . j a v a2s . c o m */ import java.io.PrintWriter; import java.net.Socket; public class ClientOutput { Socket socket; PrintWriter out; public ClientOutput(){ try { //192.168.1.100 socket = new Socket("127.0.0.1", 8787); out = new PrintWriter(socket.getOutputStream(), true); } catch (Exception ex) { } } public void send2pi (String GUIinput){ out.println(GUIinput); } public void send2pi (int[] GUIinput){ out.println(GUIinput); } public void close(){ out.close(); } }