Skip to content

Latest commit

 

History

History
25 lines (18 loc) · 685 Bytes

README.md

File metadata and controls

25 lines (18 loc) · 685 Bytes

Aqara

Get Xiaomi Smart Home device status of gateway and sub-devices. Supports magic cube, water leak sensor, door/window sensor, motion sensor and mini switch.

This package was inspired by the node package https://github.com/marvinroger/node-lumi-aqara

Example

$aqara = new Aqara();

$aqara->on('gateway', function ($gateway) {
    $gateway->on('subdevice', function ($device) {
        $device->on('update', function () use ($device) {
            echo var_export($device, true) . chr(10);
        });
    });
});

$aqara->run();

License

This project is licensed under the GNU AFFERO GENERAL PUBLIC LICENSE - see the LICENSE.md file for details.