| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 module device.usb; | 5 module device.usb; |
| 6 | 6 |
| 7 enum OpenDeviceError { | 7 enum OpenDeviceError { |
| 8 // Opening the device succeeded. | 8 // Opening the device succeeded. |
| 9 OK, | 9 OK, |
| 10 | 10 |
| 11 // The operating system denied access to the device. | 11 // The operating system denied access to the device. |
| 12 ACCESS_DENIED, | 12 ACCESS_DENIED, |
| 13 |
| 14 // The device is already open. |
| 15 ALREADY_OPEN, |
| 13 }; | 16 }; |
| 14 | 17 |
| 15 enum TransferDirection { | 18 enum TransferDirection { |
| 16 INBOUND, | 19 INBOUND, |
| 17 OUTBOUND, | 20 OUTBOUND, |
| 18 }; | 21 }; |
| 19 | 22 |
| 20 enum ControlTransferType { | 23 enum ControlTransferType { |
| 21 STANDARD, | 24 STANDARD, |
| 22 CLASS, | 25 CLASS, |
| (...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 276 // indicates no timeout: the request will remain pending indefinitely until | 279 // indicates no timeout: the request will remain pending indefinitely until |
| 277 // completed or otherwise terminated. | 280 // completed or otherwise terminated. |
| 278 | 281 |
| 279 // |packets| contains the status of each packet sent to the device, in order. | 282 // |packets| contains the status of each packet sent to the device, in order. |
| 280 IsochronousTransferOut(uint8 endpoint_number, | 283 IsochronousTransferOut(uint8 endpoint_number, |
| 281 array<uint8> data, | 284 array<uint8> data, |
| 282 array<uint32> packet_lengths, | 285 array<uint32> packet_lengths, |
| 283 uint32 timeout) | 286 uint32 timeout) |
| 284 => (array<IsochronousPacket> packets); | 287 => (array<IsochronousPacket> packets); |
| 285 }; | 288 }; |
| OLD | NEW |