LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer
User Name
Password
Linux - Embedded & Single-board computer This forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.

Notices

Reply
 
LinkBack Search this Thread
Old 08-22-2009, 04:23 AM   #1
rclemente
LQ Newbie
 
Registered: Aug 2009
Posts: 4

Rep: Reputation: 0
Question MSC (UMS) instead MTP on linux embedded device. Linux-USB Gadget / GadgetFS


Hi All:

First of all, thanks to all for your work. I'm a newbie on Linux embedded and a basic user on linux. I have deep knowledge on windows because of my work, but i really love open source concept (when it's well applied, not only to reuse code and reduce project costs to create private code)

My case is the following, i got a set-top-box based on a linux kernel which almost use open source for several parts of the code (published) and other parts are propietary (not published). The full source code is not available, so i think that this can be a problem, but we have now telnet access to device (not provided by default).

My question is the following, this device when plugged to the laptop/pc through USB it present's itself as a MTP device... but i donīt like it at all, maybe because implementation, when listing a directory, for example, it drops other operations. For example, when i copy a file, i just canīt list a folder because current copy operation aborts... It's very annoying thing.

The case is that i was wondering if there's some way to change the behaviour of the device when plugged into the USB. I want to use it as a Mass Storage Class (UMS) device, just like a external disk not using MTP !

The concept is very simple, but i donīt know where to start doing my job. I've seen on logs that it's using (i'm just guessing, not pretty sure) gadgetfs-mtp. I've been doing some google search but i'm completely lost, maybe because i'm not a experienced linux user or maybe because is not day-to-day task for everybody.

I reached to http://www.linux-usb.org/gadget/ but i canīt find how to change the behaviour from MTP to MSC/UMS.

The line found at log isnīt pretty much descriptive (for me):

gadgetfs-mtp: USB Gadget filesystem, MTP version, version 2007 July 23
[...]
gadgetfs-mtp: bound to net2272 driver

Can anybody help me? Have anybody experience publishing MTP or MSC/UMS Devices?

Thanks in advance to everybody for reply and help!!!
 
Old 08-27-2009, 03:12 PM   #2
schneidz
Senior Member
 
Registered: May 2005
Location: boston, usa
Distribution: fc-15/ fc-19-live-usb/ aix
Posts: 3,552

Rep: Reputation: 514Reputation: 514Reputation: 514Reputation: 514Reputation: 514Reputation: 514
yay, my 1000th post.

i think the mtpfs program is what you want. it emulates the mtp functionality of an mtp device to make it seem more like a usb harddrive.

it works like:
Code:
mkdir temp; mtpfs temp
it basically mounts the unit under temp so that the filesystem is browsable like a ums device.

it depends on libusb/ libmtp.
http://www.linuxquestions.org/questi...ighlight=mtpfs

Last edited by schneidz; 08-27-2009 at 03:15 PM.
 
Old 08-28-2009, 03:34 AM   #3
rclemente
LQ Newbie
 
Registered: Aug 2009
Posts: 4

Original Poster
Rep: Reputation: 0
Hi:

First of all, thanks for the reply!

I will take a deeper view to it, and let you know. The objective is plug a laptop (windows or linux) to the set-top-box (linux) and the set-top-box should present itself like a HDD (not like a mtp device) but i don't know if this will help me, as maybe this is to set a computer to act as mtp device, which is not the objective.... By the way, i will take a look.

Thanks again!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Mount userspace directory as "/dev" block device for USB Gadget API? Robert_A Programming 5 02-17-2011 02:26 AM
MTP gadget driver Robert_A Programming 7 01-14-2010 02:51 PM
Creative Zen V Plus/MTP/UMS/linux support xdevnull Linux - Hardware 6 04-08-2009 03:57 PM
USB gadget API framework with gadgetfs lqrk Programming 0 10-31-2008 05:51 AM
LXer: $100 Linux gadget becomes student testing device LXer Syndicated Linux News 0 06-03-2007 06:01 PM


All times are GMT -5. The time now is 11:40 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration