cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
peterjohn
Adventurer
Adventurer
353 Views
Registered: ‎10-18-2019

How to access USB flash drive on ZedBoard

Jump to solution

Hi, 

I am working on a ZedBoard project in which I need to store the processed data on the USB flash drive connected to ZedBoard. I am looking for what is the default mode of the USB OTG. How to configure the ZYNQ as USB Host. Can anyone share the PetaLinux commands to read/write data to USB flash drive connected to ZedBoard ?  

0 Kudos
1 Solution

Accepted Solutions
rfs613
Scholar
Scholar
320 Views
Registered: ‎05-28-2013

USB host mode typically works out-of-the-box. All you need to do is mount the flash drive. An example might be:

mount /dev/sda1 /mnt

The exact device name (sda) and partition number (1) may differ for you. To find out, plug the USB flash drive in, and watch the serial console. Some messages should appear, indicating a new drive was found, and its partitions (if any).

The mount process can also happen automatically, whenever a USB drive is connected. To check if this is the case, run the command "mount" to show all active mounts, check if the USB drive is listed there.

Once you know where it is mounted, eg "/mnt" in my example above, you can just copy files to/from this directory (and subdirectories of course).

View solution in original post

1 Reply
rfs613
Scholar
Scholar
321 Views
Registered: ‎05-28-2013

USB host mode typically works out-of-the-box. All you need to do is mount the flash drive. An example might be:

mount /dev/sda1 /mnt

The exact device name (sda) and partition number (1) may differ for you. To find out, plug the USB flash drive in, and watch the serial console. Some messages should appear, indicating a new drive was found, and its partitions (if any).

The mount process can also happen automatically, whenever a USB drive is connected. To check if this is the case, run the command "mount" to show all active mounts, check if the USB drive is listed there.

Once you know where it is mounted, eg "/mnt" in my example above, you can just copy files to/from this directory (and subdirectories of course).

View solution in original post