/cts/apps/CtsVerifier/src/com/android/cts/verifier/usb/accessory/ |
AccessoryAttachmentHandler.java | 17 package com.android.cts.verifier.usb.accessory; 29 * Utility to receive callbacks when an USB accessory is attached. 35 * Register an observer to be called when an USB accessory connects. 37 * @param observer The observer that should be called when an USB accessory connects. 60 UsbAccessory accessory = getIntent().getParcelableExtra(UsbManager.EXTRA_ACCESSORY); local 67 observer.onAttached(accessory); 75 * Callback when an accessory is attached 78 void onAttached(UsbAccessory accessory);
|
UsbAccessoryTestActivity.java | 17 package com.android.cts.verifier.usb.accessory; 54 * Guide the user to run test for the USB accessory interface. 83 public void onAttached(UsbAccessory accessory) { 95 assertEquals("Android CTS", accessory.getManufacturer()); 96 assertEquals("Android CTS test companion device", accessory.getModel()); 97 assertEquals("Android device running CTS verifier", accessory.getDescription()); 98 assertEquals("2", accessory.getVersion()); 100 accessory.getUri()); 101 assertEquals("0", accessory.getSerial()); 103 assertTrue(Arrays.asList(usbManager.getAccessoryList()).contains(accessory)); [all...] |
/cts/apps/CtsVerifierUSBCompanion/src/com/android/cts/verifierusbcompanion/ |
AccessoryAttachmentHandler.java | 29 * Utility to receive callbacks when an USB accessory is attached. 35 * Register an observer to be called when an USB accessory connects. 37 * @param observer The observer that should be called when an USB accessory connects. 60 UsbAccessory accessory = getIntent().getParcelableExtra(UsbManager.EXTRA_ACCESSORY); local 67 observer.onAttached(accessory); 75 * Callback when an accessory is attached 78 void onAttached(UsbAccessory accessory);
|
DeviceTestCompanion.java | 144 * figure out how the accessory driver is implemented on this side. 157 UsbAccessory accessory; local 175 accessory = accessoryReceiver[0]; 178 updateStatus("Connecting to " + accessory.getDescription()); 180 ParcelFileDescriptor fd = usbManager.openAccessory(accessory);
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/usb/ |
UsbDisconnectedReceiver.java | 29 // if their device/accessory is disconnected while the dialog is still open 43 public UsbDisconnectedReceiver(Activity activity, UsbAccessory accessory) { 45 mAccessory = accessory; 60 UsbAccessory accessory = local 62 if (accessory != null && accessory.equals(mAccessory)) {
|
/frameworks/base/libs/usb/src/com/android/future/usb/ |
UsbAccessory.java | 20 * A class representing a USB accessory. 31 /* package */ UsbAccessory(android.hardware.usb.UsbAccessory accessory) { 32 mManufacturer = accessory.getManufacturer(); 33 mModel = accessory.getModel(); 34 mDescription = accessory.getDescription(); 35 mVersion = accessory.getVersion(); 36 mUri = accessory.getUri(); 37 mSerial = accessory.getSerial(); 41 * Returns the manufacturer of the accessory. 43 * @return the accessory manufacture 106 UsbAccessory accessory = (UsbAccessory)obj; local [all...] |
UsbManager.java | 40 * Broadcast Action: A broadcast for USB accessory attached event. 42 * This intent is sent when a USB accessory is attached. 44 * {@link com.google.android.usb.UsbAccessory} for the attached accessory. 50 * Broadcast Action: A broadcast for USB accessory detached event. 52 * This intent is sent when a USB accessory is detached. 54 * {@link com.google.android.usb.UsbAccessory} for the attached accessory that was detached. 88 * broadcast Intent. This can also be used to retrieve the accessory from the result 94 android.hardware.usb.UsbAccessory accessory = local 96 if (accessory == null) { 99 return new UsbAccessory(accessory); 111 android.hardware.usb.UsbAccessory accessory = mService.getCurrentAccessory(); local [all...] |
/frameworks/base/core/java/android/hardware/usb/ |
AccessoryFilter.java | 32 * This class is used to describe a USB accessory. 40 // USB accessory manufacturer (or null for unspecified) 42 // USB accessory model (or null for unspecified) 44 // USB accessory version (or null for unspecified) 53 public AccessoryFilter(UsbAccessory accessory) { 54 mManufacturer = accessory.getManufacturer(); 55 mModel = accessory.getModel(); 56 mVersion = accessory.getVersion(); 82 serializer.startTag(null, "usb-accessory"); 92 serializer.endTag(null, "usb-accessory"); 129 UsbAccessory accessory = (UsbAccessory)obj; local [all...] |
UsbAccessory.java | 26 * A class representing a USB accessory, which is an external hardware component 28 * The accessory is the USB host and android the device side of the USB connection. 30 * <p>When the accessory connects, it reports its manufacturer and model names, 31 * the version of the accessory, and a user visible description of the accessory to the device. 33 * an appropriate application for the accessory. 34 * The accessory may optionally provide a unique serial number 35 * and a URL to for the accessory's website to the device as well. 40 * for reading and writing data to and from the accessory. 97 * Returns the manufacturer name of the accessory 162 UsbAccessory accessory = (UsbAccessory)obj; local [all...] |
UsbManager.java | 79 * accessory function is enabled 136 * Activity intent sent when user attaches a USB accessory. 140 * for the attached accessory 148 * Broadcast Action: A broadcast for USB accessory detached event. 150 * This intent is sent when a USB accessory is detached. 153 * for the attached accessory that was detached 251 * Name of the Accessory USB function. 256 public static final String USB_FUNCTION_ACCESSORY = "accessory"; 285 * containing the {@link UsbAccessory} object for the accessory. 287 public static final String EXTRA_ACCESSORY = "accessory"; 435 UsbAccessory accessory = mService.getCurrentAccessory(); local [all...] |
/device/google/marlin/usb/ |
Usb.cpp | 248 Status getAccessoryConnected(const std::string &portName, std::string *accessory) { 252 if (readFile(filename, accessory)) { 265 std::string accessory; local 285 if (getAccessoryConnected(portName, &accessory) != Status::SUCCESS) { 288 if (accessory == "analog_audio") { 291 } else if (accessory == "debug") {
|
/frameworks/base/libs/usb/tests/AccessoryChat/src/com/android/accessorychat/ |
AccessoryChat.java | 67 UsbAccessory accessory = (UsbAccessory) intent.getParcelableExtra(UsbManager.EXTRA_ACCESSORY); 69 if (accessory != null) { 70 openAccessory(accessory); 73 Log.d(TAG, "permission denied for accessory " + accessory); 103 UsbAccessory accessory = (accessories == null ? null : accessories[0]); local 104 if (accessory != null) { 105 if (mUsbManager.hasPermission(accessory)) { 106 openAccessory(accessory); 110 mUsbManager.requestPermission(accessory, mPermissionIntent) [all...] |
/frameworks/base/tests/UsbHostExternalManagmentTest/AoapTestDevice/src/com/android/hardware/usb/aoapdevicetest/ |
UsbAoapDeviceTestActivity.java | 65 UsbAccessory accessory = local 67 if (accessory != null) { 68 onAccessoryAttached(accessory); 70 throw new RuntimeException("USB accessory is null."); 94 private void onAccessoryAttached(UsbAccessory accessory) { 95 Log.i(TAG, "Starting AOAP discovery protocol, accessory attached: " + accessory); 96 // Check whether we have permission to access the accessory. 97 if (!mUsbManager.hasPermission(accessory)) { 98 Log.i(TAG, "Prompting the user for access to the accessory.") 162 UsbAccessory accessory = intent.getParcelableExtra(UsbManager.EXTRA_ACCESSORY); local [all...] |
/device/google/wahoo/usb/ |
Usb.cpp | 297 Status getAccessoryConnected(const std::string &portName, std::string *accessory) { 301 if (readFile(filename, accessory)) { 314 std::string accessory; local 334 if (getAccessoryConnected(portName, &accessory) != Status::SUCCESS) { 337 if (accessory == "analog_audio") { 340 } else if (accessory == "debug") {
|
/frameworks/base/tests/AccessoryDisplay/source/src/com/android/accessorydisplay/source/ |
SourceActivity.java | 44 private static final String MODEL = "Accessory Display"; 71 mLogger.log("Waiting for accessory display sink to be attached to USB..."); 82 UsbAccessory accessory = local 84 if (accessory != null) { 85 onAccessoryAttached(accessory); 90 for (UsbAccessory accessory : accessories) { 91 onAccessoryAttached(accessory); 116 private void onAccessoryAttached(UsbAccessory accessory) { 117 mLogger.log("USB accessory attached: " + accessory); 216 UsbAccessory accessory = intent.<UsbAccessory>getParcelableExtra( local [all...] |
/packages/services/Car/tests/usb/AoapPhoneCompanionApp/src/com/google/android/car/usb/aoap/companion/ |
AoapPhoneCompanionActivity.java | 73 UsbAccessory accessory = local 75 if (accessory != null) { 76 onAccessoryAttached(accessory); 78 throw new RuntimeException("USB accessory is null."); 119 private void onAccessoryAttached(UsbAccessory accessory) { 120 Log.i(TAG, "Starting AOAP discovery protocol, accessory attached: " + accessory); 121 // Check whether we have permission to access the accessory. 122 if (!mUsbManager.hasPermission(accessory)) { 123 Log.i(TAG, "Prompting the user for access to the accessory.") 212 UsbAccessory accessory = intent.getParcelableExtra(UsbManager.EXTRA_ACCESSORY); local [all...] |
/device/google/accessory/demokit/app/src/com/google/android/DemoKit/ |
DemoKitActivity.java | 128 UsbAccessory accessory = UsbManager.getAccessory(intent); 131 openAccessory(accessory); 133 Log.d(TAG, "permission denied for accessory " 134 + accessory); 139 UsbAccessory accessory = UsbManager.getAccessory(intent); 140 if (accessory != null && accessory.equals(mAccessory)) { 188 UsbAccessory accessory = (accessories == null ? null : accessories[0]); local 189 if (accessory != null) { 190 if (mUsbManager.hasPermission(accessory)) { [all...] |
/frameworks/base/services/usb/java/com/android/server/usb/ |
UsbDeviceManager.java | 224 String accessory = event.get("ACCESSORY"); local 227 } else if ("START".equals(accessory)) { 228 if (DEBUG) Slog.d(TAG, "got accessory start"); 308 if (DEBUG) Slog.d(TAG, "accessory attached at boot"); 415 // don't start accessory mode if our mandatory strings have not been set 652 // We are entering accessory mode if we have received a request from the host 657 // successfully entered accessory mode 661 Slog.d(TAG, "entering USB accessory mode: " + mCurrentAccessory); 673 Slog.v(TAG, "Debouncing accessory mode exit") [all...] |
/prebuilts/misc/common/robolectric/android-all/ |
android-all-8.0.0_r4-robolectric-0.jar | |
android-all-o-preview-4-robolectric-0.jar | |
/prebuilts/misc/common/robolectric/3.5.1/lib/ |
shadows-framework-3.5.1.jar | |
/prebuilts/misc/common/robolectric/3.6.1/lib/ |
shadows-framework-3.6.1.jar | |
/external/robolectric/v1/lib/main/ |
android.jar | |
/prebuilts/sdk/12/ |
android.jar | |
/prebuilts/sdk/13/ |
android.jar | |