-
Notifications
You must be signed in to change notification settings - Fork 5
Vibration
Takayuki Hoshi edited this page May 31, 2019
·
4 revisions
バイブレーション操作機能を提供するプロファイル。
| API | 概要 |
|---|---|
| PUT /gotapi/vibration/vibrate | スマートデバイスに対してバイブレーションリクエストを送る。 |
| DELETE /gotapi/vibration/vibrate | スマートデバイスに対してバイブレーション停止リクエストを送る。 |
one-shot
スマートデバイスに対してバイブレーションリクエストを送る。
バイブレーションの鳴動パターンは、できるだけDeviceConnectの仕様にあわせるようにする。
| 物理名 | データ型 | 必須 | 説明 |
|---|---|---|---|
| serviceId | string | Yes | サービスID。取得対象デバイス |
| pattern | array(long) | No | バイブレーションのパターン。 カンマ区切りで、震える、止まるを繰り返しバイブレーションする。 カンマ区切りされていない場合は、そのms分バイブレーションする。 省略された場合は、デバイス毎のMax値分バイブレーションする。 デバイス毎にMax値が設定されていない場合は、500ms分バイブレーションする。 例) 100, 100, 100, 100 |
| 論理名 | 物理名 | データ型 | 必須 | 説明 |
|---|---|---|---|---|
| 処理結果 | result | integer | Yes | 0: 正常応答 0以外: 異常応答 |
| システム名 | product | string | Yes | DeviceConnectシステムの名前。 |
| システムバージョン | version | string | Yes | DeviceConnectシステムのバージョン名。 |
| 署名 | hmac | string | No | レスポンスに対する署名。 アプリケーション側から事前にHMACキーを共有されていた場合は必須。 |
{
"result" : 0,
"product" : "Example System",
"version" : "1.0.0"
}
one-shot
スマートデバイスに対してバイブレーション停止リクエストを送る。
バイブレーションの鳴動パターンは、できるだけDeviceConnectの仕様にあわせるようにする。
| 物理名 | データ型 | 必須 | 説明 |
|---|---|---|---|
| serviceId | string | Yes | サービスID。取得対象デバイス |
| 論理名 | 物理名 | データ型 | 必須 | 説明 |
|---|---|---|---|---|
| 処理結果 | result | integer | Yes | 0: 正常応答 0以外: 異常応答 |
| システム名 | product | string | Yes | DeviceConnectシステムの名前。 |
| システムバージョン | version | string | Yes | DeviceConnectシステムのバージョン名。 |
| 署名 | hmac | string | No | レスポンスに対する署名。 アプリケーション側から事前にHMACキーを共有されていた場合は必須。 |
{
"result" : 0,
"product" : "Example System",
"version" : "1.0.0"
}
- Swagger 定義
-
Device Connect API リファレンス
- AirConditioner
- AtmosphericPressure
- Authorization
- Availability
- Battery
- Camera
- Canvas
- Connection
- Device
- DeviceOrientation
- DriveController
- Ecg
- EchonetLite
- File
- FileDescriptor
- Geolocation
- Gpio
- Health
- HumanDetection
- Humidity
- Illuminance
- KeyEvent
- Light
- MediaPlayer
- MediaStreamRecording
- MessageHook
- Notification
- OmnidirectionalImage
- Phone
- PoseEstimation
- Power
- PowerMeter
- Proximity
- RemoteController
- ServiceDiscovery
- ServiceInformation
- Setting
- Sphero
- StressEstimation
- System
- Temperature
- Touch
- Tv
- Vibration
- VideoChat
- WalkState