Back

CreateUSBSerial

Returns a USBSerial object.

  usb = app.CreateUSBSerial( baudRate, dataBits, stopBits, parity, device ) → app object - USBSerial

The following methods are available on the USBSerial object:

  GetType() → string: "USBSerial"
  IsConnected() → boolean
  Method( name, types, p1, p2, p3, p4 )
  SetDTR( onOff )
  SetRTS( onOff )
  SetTimeout( ms )
  Start()
  Stop()

unknown
Returns the control class name.
returns whether a USB serial device was connected
string
string: comma separated: "boolean", "char", "byte", "short", "int", "long", "float", "double"
Allows access to other functions defined on the object in Java via reflection.
boolean
?
?
number: integer
define how many bytes you want to receive maximum
define how many bytes you want to send maximum
function(?)
called when received data via USB
?
?
number: milliseconds
Start USB serial
Stop USB serial
string: "UTF-8" or "US-ASCII"
send data to USB serial device