com.dalsemi.comm
Class DebugOutputStream
java.lang.Object
|
+--java.io.OutputStream
|
+--com.dalsemi.comm.DebugOutputStream
- public class DebugOutputStream
- extends OutputStream
This class sends data to the debug port. This port is shared with the internal
1-Wire port. The methods in this class only call methods in the
com.dalsemi.system.Debug
class, but this class allows the
debug port to be accessed as an OutputStream
. Special hardware
is required to access the debug port. See
http://www.ibutton.com/TINI/developers/socket72revC.pdf for details on
board pinout for TINI and the components required to use
the debug port.
The debug port has 3 pins. Pin-1 is ground,
pin-2 is for transmit data from the terminal (PC) and pin-3 is the
data out from TINI.
- See Also:
Debug
Method Summary |
void |
write(byte[] barr,
int offset,
int length)
Writes the specified array to the debug port. |
void |
write(int b)
Writes the specified byte to the debug port. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
DebugOutputStream
public DebugOutputStream()
write
public void write(int b)
throws IOException
- Writes the specified byte to the debug port. This method calls
the
com.dalsemi.system.Debug.debugDump(int)
method.
- Overrides:
- write in class OutputStream
- Parameters:
b
- data to be written- Throws:
- IOException - if an error occurs while writing to the debug port
- See Also:
Debug.debugDump(int)
write
public void write(byte[] barr,
int offset,
int length)
throws IOException
- Writes the specified array to the debug port. This method calls
the
com.dalsemi.system.Debug.debugDump(byte[],int)
method
if the argument offset
is zero, but otherwise makes
length
calls to the write(int)
method.
For best performance, call with an offset
of zero.
- Overrides:
- write in class OutputStream
- Parameters:
barr
- array containing data to be writtenoffset
- offset into arraylength
- number of bytes to be written- Throws:
- IOException - if an error occurs while writing to the debug port
- See Also:
write(int)
,
Debug.debugDump(byte[],int)