element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Avnet Boards Forums
  • Products
  • Dev Tools
  • Avnet Boards Community
  • Avnet Boards Forums
  • More
  • Cancel
Avnet Boards Forums
Software Application Development Bare metal USB device code
  • Forum
  • Documents
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Avnet Boards Forums to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Not Answered
  • Replies 5 replies
  • Subscribers 329 subscribers
  • Views 648 views
  • Users 0 members are here
Related

Bare metal USB device code

Former Member
Former Member over 12 years ago

as subject, anybody done or aware of code that implement any minimal work usb device mode stack on zynq?

sure its ARM and EHCI so some generic code is available, but I wonder if there is any code that has actually been verified to work on zynq-zedboard?

Antti

  • Sign in to reply
  • Cancel
Parents
  • Former Member
    0 Former Member over 12 years ago

    I am curious about this as well. There is a sample project available in the xilinx SDK documentation which is supposed to act like a USB mass storage device. I have tried it and I can get it to compile and run, but I can't get my host PC to detect anything when I connect it. Also, no interupts fire on my device either.

    If it will help you, the example code is installed on your machine here for 14.3 "Xilinx_install_dir/14.3/ISE_DS/EDK/sw/XilinxProcessorIPLib/drivers/usbps_v1_03_a/examples/". Similar examples are available in similar locations for 14.2 and 14.1 as well.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • Former Member
    0 Former Member over 12 years ago in reply to Former Member

    This code does work. I got some code from a local Avnet technical marketing guy which helped me get it working for my ZC702 board. The USB PHY needed to be reset before it would work. So this code snippet placed at the beginning of main() did the trick:

        // The following code is required for ZC702 (Rev C tested) to place USB PHY out of reset.
        // this block of code needed is not needed for the ZedBoard (Rev B tested)
        Xil_Out32(0xe000a204, 0x80);
        Xil_Out32(0xe000a208, 0x80);
        Xil_Out32(0xe000a040, 0x80);
        Xil_Out32(0xe000a040, 0x00);
        Xil_Out32(0xe000a040, 0x80);

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • Former Member
    0 Former Member over 8 years ago in reply to Former Member

    You find the key, and now my project works well. Thanks.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • 100alfi
    0 100alfi over 8 years ago in reply to Former Member

    Hello Dangmug .

    i am trying to establish a connection between zynq7000 and usb2.0 Phy IC , I Need a source code for windows side for host device .i tried to google but i did not find a right code .your feedback will be greatly appreciated .

    Thank you 

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Reply
  • 100alfi
    0 100alfi over 8 years ago in reply to Former Member

    Hello Dangmug .

    i am trying to establish a connection between zynq7000 and usb2.0 Phy IC , I Need a source code for windows side for host device .i tried to google but i did not find a right code .your feedback will be greatly appreciated .

    Thank you 

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Children
No Data
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube