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
Arduino
  • Products
  • More
Arduino
Arduino Forum Arduino and USB
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Arduino to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • Replies 14 replies
  • Subscribers 393 subscribers
  • Views 1301 views
  • Users 0 members are here
  • usb
  • arduino
Related

Arduino and USB

Former Member
Former Member over 10 years ago

Hello,

I have a 3D printer that connect to my PC and that creates a virtual COM port via USB.

I want to be able to plug it to an arduino and communicate with it.

I saw that it exist an USB Host for Arduino but I didn't find a library to do what I want.

Do you have any idea ?

Thanks in advance,

Best regards

  • Sign in to reply
  • Cancel

Top Replies

  • Robert Peter Oakes
    Robert Peter Oakes over 10 years ago +1
    I agree with the others, the USB library running on an UNO will leave no room for other apps anyway so there will certainly not be enough space to drive a 3D printer The U16 chip that does the USB for…
  • Former Member
    Former Member over 10 years ago in reply to Workshopshed +1
    Thanks for all those information. My printer (M3D) is not compatible with Octoprint but I'll check the other links.
  • balearicdynamics
    balearicdynamics over 10 years ago

    Hi Victor,

     

    take a look to this link: https://www.circuitsathome.com/products-page/arduino-shields/usb-host-shield-2-0-for-arduino I got some inspiration from it while doing some Arduino projects where the board was controlling the device (in my case a camera) just as you need with the 3D printer. It is a good example as there is the downloadable software, circuit specification, schematics and Eagle files. The cost is reasonable (25$) but to be honest, if you need this for your specific need almost 80% of the stuff that is on this shield is useless for you so at least to make experiments maybe the case to try the software part and analyse how the USB Host library works. There are also application examples in the library.

     

    Enrico

     

    P.S. In cases like this, it is better if you place a question instead of a discussion, more people see it and try to give you support and answer.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Former Member
    Former Member over 10 years ago in reply to balearicdynamics

    Hello Enrico,

     

    Thanks for your answer but I know that you can communicate with Android.

    What I'm looking for is to communicate with a device that might have a RS232 to USB converter chip inside but not an Android device.

    It is detected as a COM USB device by Windows.

    I think that the ADB library will not work with my printer.

     

    So my question is : How could I make the communication possible ?

    The reason why I suggest things like the USB Shield, is to show that I have already made some unsuccessful research.

     

    If you have any other idea, I'm in.

     

    Thanks in advance,

     

    Victor

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • bobalexander
    bobalexander over 10 years ago

    What are you trying to get your Arduino to do with your 3D printer?

     

    Also, re-post as a question - you will get more hits.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Former Member
    Former Member over 10 years ago in reply to bobalexander

    I'm trying to send GCode that I get in a file on a SD Card because my printer don't have SD Card slot and it requires my PC to work.

    So I cannot print at home when I'm working with my PC at work.

    I already find out what was the protocol and I can send command to it via a C# program.

    I just have to make a C++ Arduino program but I need the COM layer.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • bobalexander
    bobalexander over 10 years ago in reply to Former Member

    You would probably be better off just hooking it up to a Raspberry Pi then...

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Former Member
    Former Member over 10 years ago in reply to bobalexander

    I thought about this possibility but it is more expensive.

    8.69 for the USB Host Shield + 3.64 Arduino UNO + 4.20 touchscreen with microSD slot = 16.53 USD (including shipping fee from China) is cheaper than a Rapsberry Pi (35USD without shipping fee) + tactile screen.

    In addition, I already bought Arduino + USB Host Shield + touchscreen with microSD slot.

    That's why I'm trying to make it work with the Arduino.

    The second reason is that an Arduino is instant ready while a Rapsberry Pi is not.

    I also have a Raspberry Pi B+ for another project but I feel it no so reliable.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • bobalexander
    bobalexander over 10 years ago in reply to Former Member

    Could you directly interface with the 3D printer over  RS-232RS-232

    Writing the USB-serial drivers in Arduino seems like a daunting task...

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Former Member
    Former Member over 10 years ago in reply to bobalexander

    Unfortunately I don't think so.

    I don't want to loose my warranty.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Robert Peter Oakes
    Robert Peter Oakes over 10 years ago

    I agree with the others, the USB library running on an UNO will leave no room for other apps anyway so there will certainly not be enough space to drive a 3D printer

     

    The U16 chip that does the USB for the UNO is absolutly full in itself and it has the hardware built in!!

     

    The Arduino USB Host Sheild should have come with links to drivers, you simply need to follow them, once you have that all working, then you will need to write a virtual com driver for the UNO (Normally provided on the PC but not an UNO). I suspect by the time this is all dont you will be out of program space (This is pure speculation but based on experiance). I am pretty sure you will need a much more powerfull (More RAM, FLASH and Processing Power) to get this project up and running

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • balearicdynamics
    balearicdynamics over 10 years ago in reply to Robert Peter Oakes

    Peter in past I have developed a G-Code like small interpreter for the Arduino with my first experiment with a mill machine. The core of the engine was on the Arduino (UNO version) board but then to manage all the needed memory, predefined strings, G-code etc. I was using a stream to save storage and a e-eprom bank to add memory with a simple database engine.

     

    victorc you wrote

     

    8.69 for the USB Host Shield + 3.64 Arduino UNO + 4.20 touchscreen with microSD slot = 16.53 USD

     

    It's sad to admit but I think that this is the reason that you are almost at the limits of the possibilities of your board. I think that avoiding the raspberry PI (that remain the better solution IMHO as has suggested Bob) you should at least orient your choice to a PIC microcontroller running 80MHz with 128 Kb in the hope that you can reach the results.

     

    Enrico

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
>
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