Logtta_Accel management class Logtta_Accelを管理するクラス

Only support in beacon mode

ビーコンモードのときのみ動作します

Hierarchy

Constructors

Properties

address: string
batteryService?: BleBatteryService
beaconData: null | number[]
beaconDataInScanResponse: null | number[]
genericAccess?: BleGenericAccess
onNotify?: ((data) => void)

Type declaration

    • (data): void
    • Parameters

      • data: unknown

      Returns void

ondisconnect?: ((reason) => void | Promise<void>)

Type declaration

    • (reason): void | Promise<void>
    • onDisconnect callback function.

      切断された時に呼ばれるコールバック関数

      Parameters

      • reason: unknown

        Reason for being disconnected 切断された理由

      Returns void | Promise<void>

serviceData: null | number[]
Address?: ObnizPartsBleCompareWithNonNull<RegExp> = undefined

Used as a condition of isDevice() by default.

標準でisDevice()の条件として使用

AvailableBleMode: "Beacon" = 'Beacon'
BeaconDataLength: {
    Beacon: number;
    Connectable: undefined;
} = ...

Used as a condition of isDevice() by default.

標準でisDevice()の条件として使用

Type declaration

  • Beacon: number
  • Connectable: undefined
BeaconDataLength_ScanResponse: {
    Beacon: number;
    Connectable: undefined;
} = ...

Overall length of manufacturer-specific data. Used as a condition of isDevice() by default.

製造者固有データ全体の長さ 標準でisDevice()の条件として使用

Type declaration

  • Beacon: number
  • Connectable: undefined

Used as a condition of isDevice() by default. Compare with data after Company ID.

標準でisDevice()の条件として使用 CompanyID以降のデータと比較

CompanyID: {
    Beacon: number[];
    Connectable: undefined;
} = ...

Used as a condition of isDevice() by default.

標準でisDevice()の条件として使用

Type declaration

  • Beacon: number[]
  • Connectable: undefined
CompanyID_ScanResponse: {
    Beacon: number[];
    Connectable: undefined;
} = ...

Used as a condition of isDevice() by default.

標準でisDevice()の条件として使用

Type declaration

  • Beacon: number[]
  • Connectable: undefined
LocalName: {
    Beacon: RegExp;
    Connectable: undefined;
} = ...

Used as a condition of isDevice() by default.

標準でisDevice()の条件として使用

Type declaration

  • Beacon: RegExp
  • Connectable: undefined
PartsName: "Logtta_Accel" = 'Logtta_Accel'
ServiceDataLength?: ObnizPartsBleCompare<number> = undefined

Used as a condition of isDevice() by default.

標準でisDevice()の条件として使用

ServiceDataStruct?: ObnizPartsBleCompare<ObnizBleBeaconStruct<unknown>>

Used as a condition of isDevice() by default. Compare with data after Service UUID.

標準でisDevice()の条件として使用 ServiceUUID以降のデータと比較

ServiceDataUUID?: ObnizPartsBleCompare<number[]> = undefined

Used as a condition of isDevice() by default.

標準でisDevice()の条件として使用

ServiceUuids: {
    Beacon: null;
    Connectable: string;
} = ...

Used as a condition of isDevice() by default.

標準でisDevice()の条件として使用

Type declaration

  • Beacon: null
  • Connectable: string

Accessors

Methods

  • Authorize PIN code

    ピンコードを認証

    Parameters

    • code: string | number

      PIN code ピンコード

    Returns Promise<boolean>

    Whether authentication was/is passed 認証が通った/通っているかどうか

  • Connect to the services of a device

    デバイスのサービスに接続

    Parameters

    • Optional keys: string

      Key acquired when pairing previously 以前にペアリングしたときに取得されたキー

    Returns Promise<void>

  • Notify when the data have got from the device with connected state

    接続状態でデータを取得したとき通知

    Parameters

    • callback: ((data) => void)

      callback function コールバック関数

        • (data): void
        • Parameters

          • data: unknown

          Returns void

    Returns Promise<void>

  • Parameters

    • peripheral: BleRemotePeripheral

      instance of BleRemotePeripheral BleRemotePeripheralのインスタンス

    Returns null | Logtta_Accel_AccelData

    acceleration data from Logtta_Accel

    Logtta_Accelから受け取った加速度データ

    Deprecated

    Get a acceleration data from the Logtta_Accel

    Note: work only in beacon mode

    Logtta_Accelから加速度データを取得

    注: ビーコンモードのときのみ動作

  • Available BLE modes (Beacon | Connectable | Pairing)

    利用可能なBLEのモード (Beacon | Connectable | Pairing)

    Returns ("Beacon" | "Connectable" | "Pairing")[]

  • Get Peripheral Mode.

    ペリフェラルのモードを取得

    Parameters

    Returns null | "Beacon" | "Connectable" | "Pairing"

    If the corresponding device is that mode, it must be null if not applicable 該当するデバイスならばそのモード、該当しなければnull

  • Parameters

    • peripheral: BleRemotePeripheral

      instance of BleRemotePeripheral BleRemotePeripheralのインスタンス

    Returns null | Logtta_Accel_ScanData

    scan data from Logtta_Accel

    Logtta_Accelから受け取ったスキャンデータ

    Deprecated

    Get a scan data from the Logtta_Accel

    Note: work only in beacon mode

    Logtta_Accelからスキャンデータを取得

    注: ビーコンモードのときのみ動作

  • Check if peripherals and modes match the library.

    ペリフェラルとモードがライブラリと合致するかチェック

    Parameters

    • peripheral: BleRemotePeripheral

      BleRemotePeripheral

    • mode: "Beacon" | "Connectable" | "Pairing"

      Beacon | Connectable | Pairing

    Returns boolean

    Whether to match 合致するかどうか

Generated using TypeDoc