Read from a device connected through serial port
Fabian Lopez Coloma <faloco-r6bP6fM/4OjA/jP0kzA/[email protected]>
| Newsgroups | gmane.comp.hardware.microcontrollers.tini |
|---|---|
| Message-ID | <[email protected]> |
Hi, I have a motor conected to Tini through serial port. I send bytes to the motor using: public OutputStream sout; sout=sp.getOutputStream(); sout.write(b); The motor sends as a response a String to Tini and I would like to read this answer and print it out. How can I do this? sin.read(...) only returns an integer, but not the data that motor sends me. public InputStream sin; sin=sp.getInputStream(); Thanks a lot! -- _______________________________________________ TINI mailing list TINI-6tN4nzCoH/[email protected] To UNSUBSCRIBE, edit your profile, or see list archives: http://lists.dalsemi.com/mailman/listinfo/tini