Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Droid

Client for controlling your droid.

Hierarchy

  • Droid

Index

Constructors

Properties

notifications?: W3CBluetoothRemoteGATTCharacteristic

Channel to listen for notifications on.

writer?: W3CBluetoothRemoteGATTCharacteristic

Channel to write messages on.

Accessors

  • get initialized(): boolean
  • Whether this droid has been connected to or not.

    Returns boolean

Methods

  • connect(): Promise<Droid>
  • Pair with the droid over Bluetooth. You will hear a confirmation sound from the droid if this is successful.

    Returns Promise<Droid>

  • initialize(): Promise<Droid>
  • send(command: string): Promise<Droid>
  • Send a command to the droid over Bluetooth.

    Parameters

    • command: string

    Returns Promise<Droid>

  • stop(): Promise<void>
  • Turn left by moving the first and third motors forward.

    Parameters

    Returns Promise<void>

  • Turn right by moving the second and third motors forward.

    Parameters

    Returns Promise<void>

  • connect(): Promise<Droid>

Generated using TypeDoc