Slide 1

Slide 1 text

No content

Slide 2

Slide 2 text

Feel free to share on SNS!! #linethings

Slide 3

Slide 3 text

LINE Things Overview The value LINE Things provides for users and developers How LINE Things works & How to implement LINE Things Agenda

Slide 4

Slide 4 text

LINE Things Overview

Slide 5

Slide 5 text

LINE Things LINE server LINE app Device

Slide 6

Slide 6 text

communicate with various electronic devices control them control them without involvement of an end user LINE Things enable LINE app to

Slide 7

Slide 7 text

LIFF BLE - weight scale

Slide 8

Slide 8 text

Automatic Communication

Slide 9

Slide 9 text

communicate with various electronic devices control them control them without involvement of an end user LINE Things enable LINE app to

Slide 10

Slide 10 text

The value LINE Things provides for users and developers

Slide 11

Slide 11 text

for LINE users to use IoT Services for developers to develop IoT Services LINE Things provides easy access

Slide 12

Slide 12 text

For LINE users

Slide 13

Slide 13 text

IoT products have some challenges

Slide 14

Slide 14 text

Sharing IoT devices

Slide 15

Slide 15 text

One-time use

Slide 16

Slide 16 text

Everyone Is Using LINE!

Slide 17

Slide 17 text

Creating something that feels natural and is easy to use Creating something that everyone has and is easy to share Creating something that anyone can use immediately The value LINE Things provide for users

Slide 18

Slide 18 text

LIFF BLE - thermography

Slide 19

Slide 19 text

LIFF BLE - e-ink

Slide 20

Slide 20 text

Create completely new services

Slide 21

Slide 21 text

For developers

Slide 22

Slide 22 text

How LINE Things works & How to implement LINE Things

Slide 23

Slide 23 text

LINE LINE Things Overview LINE server LINE app Device Your server Messaging API LIFF app LIFF BLE

Slide 24

Slide 24 text

LINE What does developer need to develop ? LINE server LINE app Device Your server LIFF app Messaging API LIFF BLE

Slide 25

Slide 25 text

LIFF BLE

Slide 26

Slide 26 text

LINE app How LIFF BLE works LIFF app LIFF SDK (BLE plugin) BLE native component Device

Slide 27

Slide 27 text

LIFF BLE implementation const device = await liff.bluetooth.requestDevice(); const gatt = await device.gatt.connect(); const service = await gatt.getPrimaryService( 'E625601E-9E55-4597-A598-76018A0D293D' ); const characteristic = await service.getCharacteristic( '26E2B12B-85F0-4F3F-9FDD-91D114270E6E' ); characteristic.addEventListener('characteristicvaluechanged', (e) => { console.log('value changed to:' + e.target.value); }); await characteristic.startNotifications();

Slide 28

Slide 28 text

Data Access LINE app Device Read LINE app Device Write LINE app Device Notify

Slide 29

Slide 29 text

Automatic Communication

Slide 30

Slide 30 text

No content

Slide 31

Slide 31 text

LINE How Automatic Communication works LINE server LINE app Device Your server Messaging API (webhook) Deliver execution results Register a scenario set Fetch a scenario set Execute a scenario set

Slide 32

Slide 32 text

LINE Register a scenario LINE app Device Messaging API (webhook) Deliver execution results Fetch a scenario set Execute a scenario set LINE server Your server Register a scenario set

Slide 33

Slide 33 text

Scenario Triggerɿthe starting point for an action. • IMMEDIATE
 Perform an action as soon as the device connects to LINE • BLE_NOTIFICATION
 Perform an action when receiving a notification Actionɿthe contents to execute • GATT_READ : Read data • GATT_WRITE : Write data • SLEEP : Wait for a specified period of time

Slide 34

Slide 34 text

Scenario Set • IMMEDIATE • Read data • Write data • BLE_NOTIFICATION • Read data • Write data • IMMEDIATE • Wait for 1 second • Write data

Slide 35

Slide 35 text

Create or update a scenario set

Slide 36

Slide 36 text

Trigger / Scenario (immediate) { "autoClose": true, "suppressionInterval": 3600000, "scenarios": [ { "trigger": { "type": "IMMEDIATE" }, "actions": [ { "type": “GATT_READ", "serviceUuid": "7B3D6B30-8F8C-4549-A4F5-66B1F435FA8F", "characteristicUuid": "90EC53BA-1DBE-4AE2-B762-7C1FEA00F380" },

Slide 37

Slide 37 text

Action / Scenario (immediate) "actions": [ { "type": "GATT_READ", "serviceUuid": "7B3D6B30-8F8C-4549-A4F5-66B1F435FA8F", "characteristicUuid": "90EC53BA-1DBE-4AE2-B762-7C1FEA00F380" },{ "type": "SLEEP", "sleepMillis": 5000 },{ "type": "GATT_WRITE", "serviceUuid": "7B3D6B30-8F8C-4549-A4F5-66B1F435FA8F", "characteristicUuid":"5486C1A0-0EC2-4073-9C38-755D21EFE090", "data": "6AMAAA==" }

Slide 38

Slide 38 text

Trigger + Action / Scenario (notification) { "autoClose": false, "suppressionInterval": 0, "scenarios": [ { "trigger": { "type": "BLE_NOTIFICATION", "serviceUuid": "91E4E176-D0B9-464D-9FE4-52EE3E9F1552", "characteristicUuid": "62FBD229-6EDD-4D1A-B554-5C4E1BB29169" }, "actions": [ { ... },{... },{... } ] } ] }

Slide 39

Slide 39 text

Scenario Set { "autoClose": false, "suppressionInterval": 0, "scenarios": [ { "trigger": { ... }, "actions": [ { ... },{... },{... } ] }, { "trigger": { ... }, "actions": [ { ... },{... },{... } ] } ] }

Slide 40

Slide 40 text

Configure a single scenario set for each product ID Use Scenario management APIs to register a scenario set The scenario sets only fetch by the LINE app on specific occasions About a scenario set

Slide 41

Slide 41 text

LINE Fetch a scenario set Device Your server Messaging API (webhook) Deliver execution results Register a scenario set Execute a scenario set LINE server LINE app Fetch a scenario set

Slide 42

Slide 42 text

LINE Execute a scenario set LINE server Your server Messaging API (webhook) Deliver execution results Register a scenario set Fetch a scenario set LINE app Device Execute a scenario set

Slide 43

Slide 43 text

LINE Deliver execution results Device Register a scenario set Fetch a scenario set Execute a scenario set LINE server LINE app Your server Messaging API (webhook) Deliver execution results

Slide 44

Slide 44 text

scenario execution result Trigger • When receiving a notification with the specified GATT characteristic value Action • Read data

Slide 45

Slide 45 text

Response "things": { "type": "scenarioResult", "deviceId": "tXXX", "result": { "scenarioId": "XXX", "revision": 2, "startTime": 1547817845950, "endTime": 1547817845952, "resultCode": "success", "bleNotificationPayload": "AQ==", "actionResults": [ { "type": "binary", "data": "/w=="

Slide 46

Slide 46 text

No content

Slide 47

Slide 47 text

THANK YOU