I am working on a MPG (Manual Pulse Generator) for use with GRBL CNC control software on a Arduino UNO. Currently I am using a Arduino MEGA connected to my computer via USB, UGS Software on computer to send the G-code instructions. Then forward the serial communications from the Serial port of the MEGA out the Serial1 port connected to the TX, RX pins on the UNO. This works but I want a cleaner more easily integrated solution. I am hoping to add a USB Host 2.0 Shield on the mega to do the same function just through the USB port on the UNO. Anyone have any experience using the Host Shield? I have done some google searching and looking for examples but all I can really find is a keyboard and mouse example and the code behind them is way above my pay grade....Any thoughts or experiences would be great.
I think it's possible to implement CDC-ACM using a USB Host shield, but Mega's processing can get bit busy.
Isn't it worth buying a USB host to UART module that uses an IC like the FT312D?
Why don't you want to use other immediately available communication channels like SPI or I2C?
DrD, I have 2 separate boards I am trying to interface with. The one is no problem accessing the Arduino rx/tx pins. The other is a custom board on a "3018 CNC". It uses the 328p chip it just doesn't have an easy way to connect to the rx/tx pins. ** I run into the same issues with lots of these CNC boards (ex. Ramps 1.4 for Mega, CNC Shield for UNO) They don't allow access for a "rigid" connection. So what I was looking to do is just connect to the USB port. I have everything working by sending serial commands through RX/TX pins from the software side just want a "easy" way to connect to any board.
You mentioned those other communications channels. Is there some way to use them through USB?
There isn't much going on in the program just some serial port forwarding and checking some IO. I only went with it to have access to a second high speed serial port. The uno I am trying to interface with is built into a custom board that doesn't allow easy access to the rx/tx pins or any other pins for that matter. 3018 CNC control board. If I could implement a usb host solution I could have access through the usb port. Unfortunately I have no idea how USB protocols work....