Preparing search index...

    Interface BLEGattConnection

    Raw GATT connection for dynamic interaction. Use subscribeGATT with a descriptor whenever possible — this is the escape hatch for sensors that require truly dynamic GATT sequences.

    interface BLEGattConnection {
        connected: boolean;
        disconnect(): Promise<void>;
        discoverServices(): Promise<BLEGattService[]>;
        onDisconnect(callback: () => void): void;
        read(
            serviceUuid: string,
            charUuid: string,
        ): Promise<Buffer<ArrayBufferLike>>;
        startNotifications(
            serviceUuid: string,
            charUuid: string,
            callback: (data: Buffer) => void,
        ): Promise<void>;
        stopNotifications(serviceUuid: string, charUuid: string): Promise<void>;
        write(
            serviceUuid: string,
            charUuid: string,
            data: Buffer,
            withResponse?: boolean,
        ): Promise<void>;
    }
    Index
    connected: boolean
    • Parameters

      • serviceUuid: string
      • charUuid: string
      • callback: (data: Buffer) => void

      Returns Promise<void>

    • Parameters

      • serviceUuid: string
      • charUuid: string
      • data: Buffer
      • OptionalwithResponse: boolean

      Returns Promise<void>