NetworkConnector

NetworkConnector

new NetworkConnector(remoteAddropt, remotePortopt, optsopt)

Source:
Manages connecting to remote device via IP networking, handshaking and MessageChannel creation.
Example
const connector = new NetworkConnector('192.168.53.1', 44444, { debug: true })
connector.connect()
  .then(ch => { ... })
  .catch(error => { ... })
Parameters:
Name Type Attributes Default Description
remoteAddr string <optional>
'192.168.53.1' IP address of target network device
remotePort uint16 <optional>
44444 ARSDK TCP discovery port
opts Object <optional>
Properties
Name Type Attributes Default Description
debug boolean <optional>
false Enable debugging output

Methods

connect(controller_typeopt, controller_nameopt) → {MessageChannel}

Source:
Initiate connection to remote network end-point. Resolves on successful connection.
Parameters:
Name Type Attributes Default Description
controller_type string <optional>
'js-arsdk'
controller_name string <optional>
HOSTNAME
Returns:
Type
MessageChannel