obniz Parts Library

tm530

GitHub
tm530
Usable Devices :
obniz_board
m5stickc
Found at :

TM530

BLE enabled acceleration sensor.

isDevice(BleRemotePeripheral)

Returns true if a device was found.

// Javascript Example
const TM530 = Obniz.getPartsClass('TM530');
await obniz.ble.initWait();
obniz.ble.scan.onfind = (p) => {
    if (TM530.isDevice(p)) {
        const data = TM530.getData(p);
        console.log(data);
    }
};
await obniz.ble.scan.startWait(null, { duplicate: true, duration: null });

getData(BleRemotePeripheral)

Reading a acceleration data from BLE advertisement

  • battery Battery Level
  • temperature: Temperature
  • humidity: Humidity
// Javascript Example
const TM530 = Obniz.getPartsClass('TM530');
await obniz.ble.initWait();
obniz.ble.scan.onfind = (p) => {
    if (TM530.isDevice(p)) {
        const data = TM530.getData(p);
        console.log(data);
    }
};
await obniz.ble.scan.startWait(null, { duplicate: true, duration: null });

Supported from: obniz.js 3.5.0

You will Get in Few Days

Circuit for Starter “obniz Board” is available on Amazon and other online stores.
You can get it at below

Our products and resellers

Forum

Visit our developer’s forum to discuss and discover technologies.

Forum

Contact

Feel free to contact out support and technical team.

Contact us